Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp1786728imm; Tue, 22 May 2018 09:17:22 -0700 (PDT) X-Google-Smtp-Source: AB8JxZqcyIE7mHHGhYz1EDj7AX3tx+jQNS4rRDKuZ1pxoNxal6LIuHfYXDUwIm+EauCVVhk/RcBI X-Received: by 2002:a62:ae13:: with SMTP id q19-v6mr24795394pff.155.1527005842407; Tue, 22 May 2018 09:17:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527005842; cv=none; d=google.com; s=arc-20160816; b=elnQn1N0+MsfK/UWnw7Nx8NNW1uCpxplaa4OeDkKM6BYnix6zYAaV1K7UBaLHma/oy qzFy++QZdMkJ+o/iQ8biLFi6FADvqcoF3rU5BhbOvVoHpVwcwPo4rnRdvXa0O6DqG0Fx LtCgo9A2bLi6i8yIIt6jRkEY0BFLJNQ2LlftekAmNHm3KAHwL1rI+vkIWQkCCIRLTv2u WgRzOSQ2nX/Th8IKatYOliPQAdIk4XRU1xYpIGlvN/31+yN11fBGKcuTNABq9FPodOdc KrxkSYDGgvOd/3mbtIA/ScR7GD2s2V0fpBfs7NZPqWN3Pr/HMLc/NfdsNwMzbCalkeRp iKHg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=tiJ5eRdVpFl6qvEdTNzn3eNYOVI9freFqOm3GHIkClI=; b=mEvo8b6SBsGDzVYMo3fWQbWg8MeGHRRJf1UztODVnGiD4o/PvOI0ZjJbZ1R03+S2f2 kXIMp18M9FZlGzBFbqDIyUnLeEBavDx7/rQ4my34dIPR5CKjxSfCiUi6U5/MXXwsH6nL ozb6tTDAKNdan9tGSsF/vFnkYhv936WUB0IB5VFYmKrvIJHfhOqy54XTGFPo161pwsE3 AXUT+g4S5ANr7dGYoiUDmH11C/hgTOuN6hSx2l6v+OqCUzif6XLEaeLY5KJTTzhoxtNO LJ2oUqYANERrVzatsDOwK2cqu83KQAWLMd87eQD4hI85VnaUzioTSD4NLp3Vm2Z/hLWQ jLaQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i8CHY+q8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y34-v6si16785914plb.17.2018.05.22.09.17.07; Tue, 22 May 2018 09:17:22 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=i8CHY+q8; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751553AbeEVQQ0 (ORCPT + 99 others); Tue, 22 May 2018 12:16:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:48576 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751268AbeEVQQZ (ORCPT ); Tue, 22 May 2018 12:16:25 -0400 Received: from mail.kernel.org (dyndsl-091-096-014-052.ewe-ip-backbone.de [91.96.14.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 92BFF2075C; Tue, 22 May 2018 16:16:24 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1527005785; bh=tiJ5eRdVpFl6qvEdTNzn3eNYOVI9freFqOm3GHIkClI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=i8CHY+q8/jvCzjHzXPCW4N7HdW51sE9FppCaT4lV+YPBuvSGXTQmvX9Mv1KQ7wzHR 8Lc2tmJHvbmeiIWWKCfEzBkmRrrn229FbgLsjYp9lnK6P6oTLEp3Qxj20hoxqiJ0yx FFaQPrVof+L0xYv4FIHbJpPMrNOc46/9kcENxTCM= Date: Tue, 22 May 2018 18:16:22 +0200 From: Sebastian Reichel To: Andy Shevchenko Cc: Yisheng Xie , Linux Kernel Mailing List , Linux PM Subject: Re: [PATCH 18/33] power: supply: use match_string() helper Message-ID: <20180522161622.iwfo4ppcqpthxkum@earth.universe> References: <1526903890-35761-1-git-send-email-xieyisheng1@huawei.com> <1526903890-35761-19-git-send-email-xieyisheng1@huawei.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="zgfopwpbzziugpzd" Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20180323 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --zgfopwpbzziugpzd Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi Andy, On Tue, May 22, 2018 at 12:58:14AM +0300, Andy Shevchenko wrote: > On Mon, May 21, 2018 at 2:57 PM, Yisheng Xie wro= te: > > match_string() returns the index of an array for a matching string, > > which can be used intead of open coded variant. > > >=20 > This doesn't make code looks better anyhow. I even think it makes it > worse to read. That's why I dropped my version of the change (and yes, > I missed the type conversion which looks here just ugly). >=20 > Sebastian, if my opinion makes any difference here, I would say > NAK to this one. I agree. -- Sebastian --zgfopwpbzziugpzd Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEE72YNB0Y/i3JqeVQT2O7X88g7+poFAlsEQlYACgkQ2O7X88g7 +pqGJg//SQU/lRqfRD0aUmCRA10EE3J0EWHgyGDMRu2IthzfQ6HGRt6QAecltrqd hPyfv/9WX9G9tAI4tcYdlPu76bxmoq4rm8ZfTO0MAGc0pYum5hhQ/S6iARBN1Giy miutTMYI6h1B5p4ZERk9oEPNZxaPfizO1pDsoH67vnid7jQmkhHTc3bVxN6sX/Hi eig6S4jeoJFFDLQZZ5aeHBLKYhhC0L8cPyUbLpGb5J2QKhx49uw1bdbwCX2BYGlW N8K6b8AluV8g9wGGR5KVSltjXWMVpjV5At1Sh3dm9zQXUNVwX8L3XmgExkdBWXKN fae3Sw3wmF7sZdM4HtkEv+GHEbJUoSDlpEAgj2Zuss+WSehBODA5U2LpU0cNh2LS zlqvoS3Ik4FEcfpt9Uay3uxTFGFz5T3zhGPelCrA3dZJNd7yZbXDdPvfC+CChtFH yFke68PKXqw+ymI4gvtrK8hcfghqBHfi7SfPW94gAwvkLTBkQ0/uUsdEFrDwx06F ujZ4/WL7gPoPq/oSBfDrrtpTEuAgk+7NOh7LJouYkvMjxtgWGElWxAFv5Mulj/0Z F6sTZ+002HQHrkGGMpO4EpVGefXYxy8dvVHUuee0z+fNPubusjnUnNFWx6H2Jn00 oJF8zB2D7A3JJtja1ffqbzz/80MH2wkYggr3n1qLAwK/vYygqTQ= =hudn -----END PGP SIGNATURE----- --zgfopwpbzziugpzd--