Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp1164455ybi; Sat, 8 Jun 2019 04:01:20 -0700 (PDT) X-Google-Smtp-Source: APXvYqzpNs1ZjKGvGibPXy0hdI+JdGiH5+YoCl0kN2tUJ5A7fEcnxIGCoxU6jtkaNe2y/t9jDmGq X-Received: by 2002:a65:624f:: with SMTP id q15mr7006510pgv.436.1559991680725; Sat, 08 Jun 2019 04:01:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1559991680; cv=none; d=google.com; s=arc-20160816; b=uU1nvhAJdDAtOqE/CFZIuAxh9nCe+uBg54n3FunNbRHUKP1YD4wX0SxcYFr+lXlumG /U0u/WetrDNpZnzoGsXMkx4eIZI6Lwmi5acQkZQdJHE4Yg1QqQeRGEKmRDZw9GrSUAY+ 9arGiAF8gtzmsCrg3w+G3QPyH4fe8jwLxoqRNiwLoaiElhe80JYDYuWiHaQkTIDf8Zx6 ZdGsoC3xuk9vZnoS7UL+gXo10xSlNugwqHGOuRzEqi63PIolw8eMOzfuyUEA2dVt8dTQ NYEIoolKNgLUjQU6Jy16RSPoP+tx5pwOhFLvmSpV7IWNNonRI9i0hq4EgxJSblGCdHyI y7Tw== 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=XfFDcgeBmQoc4lcLdMXV0M6ttUsGZDSfQqnSJ1qdZjo=; b=gfElPpKQRyJBmu/8FDHoS20CcJwUpJ9euG1+HAaixRhjZdjgjknPXt1o793cdMYOap x051oJP2Q8sNKhQSD95/uuFCGAphqE4wnAzKci/mZ5Bt+FiyXufvERjzR/m5C1BWCzOQ JD1AJjm+IwVQPvw7e0jXjjclHy495tYraEC8HYR0+l1J351CCGZszyYmYL435vsPqEkJ HEq+lEfLBKQzKlDpfJLrSi2nnFHHr6eM5j/fl9+3vSqjyg2T/em0rDhnLVtIUCPS/TX+ 5AoVZ2AFqcOigTp6Ki1+j6d9J5M9pQFFWi4SuBDQVHap/6/qUjQX8PLIyQGK+Am7ausn 8OzQ== 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 m191si4480768pga.17.2019.06.08.04.01.05; Sat, 08 Jun 2019 04:01:20 -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 S1727093AbfFHK4x (ORCPT + 99 others); Sat, 8 Jun 2019 06:56:53 -0400 Received: from sauhun.de ([88.99.104.3]:51878 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726824AbfFHK4q (ORCPT ); Sat, 8 Jun 2019 06:56:46 -0400 Received: from localhost (p5486CBCC.dip0.t-ipconnect.de [84.134.203.204]) by pokefinder.org (Postfix) with ESMTPSA id 26C653E4789; Sat, 8 Jun 2019 12:56:45 +0200 (CEST) From: Wolfram Sang To: linux-i2c@vger.kernel.org Cc: Wolfram Sang , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 08/34] media: i2c: mt9m111: simplify getting the adapter of a client Date: Sat, 8 Jun 2019 12:55:47 +0200 Message-Id: <20190608105619.593-9-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/media/i2c/mt9m111.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/i2c/mt9m111.c b/drivers/media/i2c/mt9m111.c index 5168bb5880c4..a9da43316504 100644 --- a/drivers/media/i2c/mt9m111.c +++ b/drivers/media/i2c/mt9m111.c @@ -1235,7 +1235,7 @@ static int mt9m111_probe(struct i2c_client *client, const struct i2c_device_id *did) { struct mt9m111 *mt9m111; - struct i2c_adapter *adapter = to_i2c_adapter(client->dev.parent); + struct i2c_adapter *adapter = client->adapter; int ret; if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_WORD_DATA)) { -- 2.19.1