Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp1210252ybi; Sat, 8 Jun 2019 05:01:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqyZeLOBMODJh8Agjtl+8vBvGBq7UaWDb3No9SAmJCkt2CCQNKeT4wKAtZYvoKnHJdYmiWXC X-Received: by 2002:a63:ed09:: with SMTP id d9mr7365650pgi.419.1559995313781; Sat, 08 Jun 2019 05:01:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559995313; cv=none; d=google.com; s=arc-20160816; b=PaT9HIU18LvzGLmwFth76uE0u5L8qv6mdeSUFlW2SAfk8IbdcL2iBEtq0R18ZeozRO RLEjyUMa8wzxdVzKSwQfe9h3l4UsNUwhK9koXwL/P5tr1quqpv50HzCVkl1nTnqVvKNJ 8SZB01RMkUFQ/NKh8yOTFBcFldpaKrU59ZI/KxxTqaJGCMm6CjGLMsj2gyNx0BdxADEe cqPq1CIkZthfGiqy624j8+urtcPlVNAMZdp2AtKkyM7eZcrwsIinGbkj3yeI+f1Dndxx 3h2L+tO+acsHVEEd8BgPk2AD/uO4omHSNUWuEp8kuIrIjbGXUKTMSr6Dlv3uVVbb5daA /nxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=fS1G6xfARdkIXMEih2kunJ6l9I8mPJNdiDvYkNmX8dc=; b=tq0kOHRglEECyu13SEqhFSRTOBCBeaeRxml+fZWG+IcaESJXS44DiLZQmk8VJyXb4C NXHq3x69swG1TxlCmlRIGEfxdbydiCicN56bg53WFEZ5AxdHZQff3BtQUAsBqafSwo8T ZrfhyinOCnAUYKatqz6Lf1/AsrehqDxy8dNquo6enPy1rcYJHEePQXD3hl6oCDZhFaDA TqSLRUCatuaxY5lVZ29MwkPsC9KqP/qXv0NeQAKpEvv8WUkkzc44I7/4oRysxr3d3HGi WkvTSY40lhSK3ktVIfdI2SxHEKmLf+8QTTCLf4nISvp0IAhy5Rn9P9iGarPkURybrX/A geIA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=pQTRSkU4; 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 d126si4436719pgc.46.2019.06.08.05.01.36; Sat, 08 Jun 2019 05:01:53 -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=pQTRSkU4; 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 S1727076AbfFHLju (ORCPT + 99 others); Sat, 8 Jun 2019 07:39:50 -0400 Received: from mail.kernel.org ([198.145.29.99]:56784 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726935AbfFHLju (ORCPT ); Sat, 8 Jun 2019 07:39:50 -0400 Received: from archlinux (cpc149474-cmbg20-2-0-cust94.5-4.cable.virginm.net [82.4.196.95]) (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 338E9208C0; Sat, 8 Jun 2019 11:39:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1559993989; bh=xfk2wRGEM4iv26ktKy2rXmXoYgltCUoUo9eEQWOVnKk=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=pQTRSkU4qclN1APUcAgyy15vvD+kWn8KddareEMCj0Tz3uURVBr/E1blj8GecqzcF ytzNymxwMaQLjhnd2RWVB+RUQ5m3j8yLq1P8etg6TPFubbflq8erKCTA+7ywJTH9QU rbo9ZcrQGZ5w6fQpqlMpk6s2aasGxd4ejYauI+qE= Date: Sat, 8 Jun 2019 12:39:45 +0100 From: Jonathan Cameron To: Wolfram Sang Cc: linux-i2c@vger.kernel.org, Hartmut Knaack , Lars-Peter Clausen , Peter Meerwald-Stadler , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 03/34] iio: light: bh1780: simplify getting the adapter of a client Message-ID: <20190608123945.4bef51e0@archlinux> In-Reply-To: <20190608105619.593-4-wsa+renesas@sang-engineering.com> References: <20190608105619.593-1-wsa+renesas@sang-engineering.com> <20190608105619.593-4-wsa+renesas@sang-engineering.com> X-Mailer: Claws Mail 3.17.3 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 8 Jun 2019 12:55:42 +0200 Wolfram Sang wrote: > We have a dedicated pointer for that, so use it. Much easier to read and > less computation involved. > > Signed-off-by: Wolfram Sang Applied to the togreg branch of iio.git and pushed out as testing for the autobuilders to play with it. Thanks, Jonathan > --- > > Please apply to your subsystem tree. > > drivers/iio/light/bh1780.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/iio/light/bh1780.c b/drivers/iio/light/bh1780.c > index 340d64d0ac59..a8361006dcd9 100644 > --- a/drivers/iio/light/bh1780.c > +++ b/drivers/iio/light/bh1780.c > @@ -146,7 +146,7 @@ static int bh1780_probe(struct i2c_client *client, > { > int ret; > struct bh1780_data *bh1780; > - struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent); > + struct i2c_adapter *adapter = client->adapter; > struct iio_dev *indio_dev; > > if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_BYTE))