Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp1164268ybi; Sat, 8 Jun 2019 04:01:09 -0700 (PDT) X-Google-Smtp-Source: APXvYqwyxqwZeTxOG+XDwJGcxC7dtkAUbiPfIOie1FOzTrxft0WG2yptG3e1heVQyTMryyf8iRIn X-Received: by 2002:a17:902:2ac8:: with SMTP id j66mr20146583plb.273.1559991669140; Sat, 08 Jun 2019 04:01:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559991669; cv=none; d=google.com; s=arc-20160816; b=wBX/zbtOVGtFPWJDxbi0t7BpAOEPvoGpDO+ms5PBzXcfzYe0jhYVhb85y0mRTJT90N QoiVI4UQ8yL3DqwAkI3meVVxw1/3JGu3b2z7wMQKTUn6FcK+AXhhamoQ3w3eTQSugLoN hZ15hCN7wKwitS8A1LV4+Ha8XCywSvlur7DK4epZ/EGKQYS2Xzbq+iXGzLR6oHGceoh0 fGFV1hGx+KvOz0Y4ZW83axcAZHj2Ig+Mk3crmTA2xMASDXA/M7OE9OMmwPkRunmTkw+7 oo/A/6gw33OppL/5EkUf6Vj8oA9L8LybcLgvRHtbklb3j9HB3+x7dC/p9xAibkNjWJWr cB4w== 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:date:subject:cc:to:from; bh=Prn19eA1OKBiLFlhc8Dnl9VmSv5JLoi1XYC780C5TSg=; b=kSUsEZxIiNa0wtnx2OSPP26GhQcXXVQ6J7d4nIZsT+IW2zF2pofAZtpbSy/EsYuzWS kBSXeN2u4gys7kPuosUEwdl3wXP3abOKPv1YMVySwATwe5p2DpMuLALqnZ9rnyoL6gFc r+gqLb34kQA6JdYPIZH6aTO0eJZKnaqdhITrwL2o9HVIuWh0bofHzAtgS+cGg0BtujIS vu/bgGWQfTrfUcfaRK8Rim48E4FzufEjDTelcSFhn6wCZeCpZf1HhCEtnOLXWMlI7BgO t1C7qcVhWItW0i2rvygtkNYmITbL8+FQvTHDB7IK1OEb2D8zs78UTEtyDNlJa4V6WbXW 4chA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w4si522430pgr.150.2019.06.08.04.00.53; Sat, 08 Jun 2019 04:01:09 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727665AbfFHK7G (ORCPT + 99 others); Sat, 8 Jun 2019 06:59:06 -0400 Received: from sauhun.de ([88.99.104.3]:51910 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726841AbfFHK4u (ORCPT ); Sat, 8 Jun 2019 06:56:50 -0400 Received: from localhost (p5486CBCC.dip0.t-ipconnect.de [84.134.203.204]) by pokefinder.org (Postfix) with ESMTPSA id DD4733E4789; Sat, 8 Jun 2019 12:56:48 +0200 (CEST) From: Wolfram Sang To: linux-i2c@vger.kernel.org Cc: Wolfram Sang , David Woodhouse , Brian Norris , Marek Vasut , Miquel Raynal , Richard Weinberger , Vignesh Raghavendra , linux-mtd@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH 15/34] mtd: maps: pismo: simplify getting the adapter of a client Date: Sat, 8 Jun 2019 12:55:54 +0200 Message-Id: <20190608105619.593-16-wsa+renesas@sang-engineering.com> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20190608105619.593-1-wsa+renesas@sang-engineering.com> References: <20190608105619.593-1-wsa+renesas@sang-engineering.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We have a dedicated pointer for that, so use it. Much easier to read and less computation involved. Signed-off-by: Wolfram Sang --- Please apply to your subsystem tree. drivers/mtd/maps/pismo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mtd/maps/pismo.c b/drivers/mtd/maps/pismo.c index 788d4996e2c1..7fcae3af435c 100644 --- a/drivers/mtd/maps/pismo.c +++ b/drivers/mtd/maps/pismo.c @@ -211,7 +211,7 @@ static int pismo_remove(struct i2c_client *client) static int pismo_probe(struct i2c_client *client, const struct i2c_device_id *id) { - struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent); + struct i2c_adapter *adapter = client->adapter; struct pismo_pdata *pdata = client->dev.platform_data; struct pismo_eeprom eeprom; struct pismo_data *pismo; -- 2.19.1