From patchwork Fri Nov 18 22:41:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= X-Patchwork-Id: 22868 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp472091wrr; Fri, 18 Nov 2022 15:59:20 -0800 (PST) X-Google-Smtp-Source: AA0mqf4RDpCXM/P0XbwozBRS8028+q3MPL/Zr1YplFf56CS+PaYdE6bfhfzbc/QSiaJOrSDhSi+q X-Received: by 2002:a17:906:950a:b0:7ab:2559:8bc4 with SMTP id u10-20020a170906950a00b007ab25598bc4mr7484384ejx.682.1668815960686; Fri, 18 Nov 2022 15:59:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668815960; cv=none; d=google.com; s=arc-20160816; b=qBI/txGbHrGnRtg8f9QOuA87G7dPAsp4+Jr/jJBQICKKPAzMCS6CAyBs7ULlsMBoPT 3nfZDo1XxG+XsNjdfL6l8djCLdY7CxmwpHflQe5bHBXCs/w4d6qPU0BX7CJhsIDCxiBO VY6f2vQ3VauZp00+SOT6eqdJ0+37d4+bj93j6KQnxEwX2yiWyC/3y+0iVI5t4SJvlwwf 2VwHmyJ68hBgzhQGcAkJ75s+l4I3/+PiHHzcTwT81er7rn/7+kHhITqXorK7CbnkDQjD e35t0MUiTRBajEm1H1jD2aNQCwrEz+Oq+V3UfitTFdwuUKZSy6zEl4MM/m+VJH/ZmW5B puYQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=+NdwJvRtVlm+6SvRgCUJ3AAW7aYnEoYDAShgIKdDK94=; b=H4dFSsIHUmChN3uus4rff4jBFb9nfFqA05TUwVOLZBnQ/oFxi2nJTvcrfk2+lhpaMN nMJ53yMUwO3XYA9OdJB1QsWuQughQBkqnUZONxV7yH3rEYWvMKBGW6o1XVWnrQjgWuQO iSQN3NnUVLUYPXKysQjQdWlFQ4682/SKJYvg0hbgU+0tQjJBQhpJUf8PZfiat56mA0/B hMKv12iUJi6RIjRjyTqmlAHqt0yAZ/f5u0jifXVKDWEdpRTqT4iDNrSukBCawWR94KB9 uB9wRf1K4Z5lBNS40jy4hL9+15J7048UwrHikfOr5yjxlpDihDLi/c8cntuwMcCe8ue6 DGkQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m11-20020a170906258b00b0078adad5930esi3130708ejb.255.2022.11.18.15.58.56; Fri, 18 Nov 2022 15:59:20 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232201AbiKRXna (ORCPT + 99 others); Fri, 18 Nov 2022 18:43:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35776 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237102AbiKRXmi (ORCPT ); Fri, 18 Nov 2022 18:42:38 -0500 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2947A43ACF for ; Fri, 18 Nov 2022 15:23:49 -0800 (PST) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1owA8z-0003LS-91; Fri, 18 Nov 2022 23:47:33 +0100 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1owA8x-0058ab-0G; Fri, 18 Nov 2022 23:47:31 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1owA8x-0000G3-4P; Fri, 18 Nov 2022 23:47:31 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Angel Iglesias , Lee Jones , Grant Likely , Wolfram Sang , Mauro Carvalho Chehab , Sakari Ailus , Dmitry Torokhov , Linus Walleij , Benjamin Mugnier , Dongliang Mu Cc: linux-i2c@vger.kernel.org, kernel@pengutronix.de, =?utf-8?q?Uwe_Kleine-K?= =?utf-8?q?=C3=B6nig?= , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 360/606] media: i2c/ov7670: Convert to i2c's .probe_new() Date: Fri, 18 Nov 2022 23:41:34 +0100 Message-Id: <20221118224540.619276-361-uwe@kleine-koenig.org> X-Mailer: git-send-email 2.38.1 In-Reply-To: <20221118224540.619276-1-uwe@kleine-koenig.org> References: <20221118224540.619276-1-uwe@kleine-koenig.org> MIME-Version: 1.0 X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749880364930197652?= X-GMAIL-MSGID: =?utf-8?q?1749880364930197652?= From: Uwe Kleine-König .probe_new() doesn't get the i2c_device_id * parameter, so determine that explicitly in the probe function. Signed-off-by: Uwe Kleine-König --- drivers/media/i2c/ov7670.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/media/i2c/ov7670.c b/drivers/media/i2c/ov7670.c index 11d3bef65d43..27db0a07de1f 100644 --- a/drivers/media/i2c/ov7670.c +++ b/drivers/media/i2c/ov7670.c @@ -1847,9 +1847,9 @@ static int ov7670_parse_dt(struct device *dev, return 0; } -static int ov7670_probe(struct i2c_client *client, - const struct i2c_device_id *id) +static int ov7670_probe(struct i2c_client *client) { + const struct i2c_device_id *id = i2c_client_get_device_id(client); struct v4l2_fract tpf; struct v4l2_subdev *sd; struct ov7670_info *info; @@ -2038,7 +2038,7 @@ static struct i2c_driver ov7670_driver = { .name = "ov7670", .of_match_table = of_match_ptr(ov7670_of_match), }, - .probe = ov7670_probe, + .probe_new = ov7670_probe, .remove = ov7670_remove, .id_table = ov7670_id, };