From patchwork Fri Nov 18 22:40:29 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: 22915 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp472939wrr; Fri, 18 Nov 2022 16:01:10 -0800 (PST) X-Google-Smtp-Source: AA0mqf4TJegGy/wp5VyHa0PtXm/YFRPguGZbHRyUpexG2X6lkwvwjLSmhwCZjvz892V1ef9ejDOq X-Received: by 2002:aa7:d1cc:0:b0:468:f964:372e with SMTP id g12-20020aa7d1cc000000b00468f964372emr6330220edp.326.1668816070674; Fri, 18 Nov 2022 16:01:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668816070; cv=none; d=google.com; s=arc-20160816; b=oj76iXRm4HzvRJeN/B3k4GhHSxKSrhPVQ3IopOzlaS5FczNAQdHoWYhZux9m58ZVvq UI7MUA0C6vPeJ7eOIt5YDu7gGkrAQc6yt44N2/yd97OTGp9J9MiJaURO3YGKc2YS3SRT jwRL6aGaewafJ9c5WIsOZvDyxv+uhQ9GVutv5JpkwHjF0NGnm4+StdJwGZatxXMYf0vU wd80sqgFOCNIgvlAtPAX8WTSmSZncUsq59aRZ+HCjDJI3CLTXpgr5QGK1Xxe52SteNEF Za71aOb2MAQ4lSx8hrdm8JcRpBk9y4EbT+KMHj3bhKjHc2DR34QadDQW8+DMdtOzd/zv 11Gw== 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=ge49tJqsO7K0jmBE/HJ3khmhsD9eSzCXJGTvrbGfbRI=; b=uW7r0Y2eKVuyipiTCbFfHHtw/Jl105fCgBaS99dxA3elEjLYuDOYL5UP0NTecnnl9Z hNaGrRzgyyl+/Ugrohx2jx8c6dDfmddZu5S/qALEX0Hz4sdBIGybc19fBU8eHSZCdvxx wSbt6QcSNSQH7KXl2HxP5Hv+z7Sjss91PB0zKOJgNKlv3XFwcZ67VtPjDs4u1aFU6cK4 dpbuB/cakaHkfjt4sRzVT+MHX3uCmqzVOXNVGqCIkZ5F33Ba3ovLYVMzC0LVL/WES7o4 dPLWzu/iIBPtNjOfi7vTK7eTnaVeKzFPA5ZUWHW8XhUG4fAtT/AeOiPHkegTauFP5ISE YFJg== 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 a27-20020a170906191b00b007adadfc97c7si3608084eje.918.2022.11.18.16.00.46; Fri, 18 Nov 2022 16:01:10 -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 S236880AbiKRXtE (ORCPT + 99 others); Fri, 18 Nov 2022 18:49:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42554 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237333AbiKRXsA (ORCPT ); Fri, 18 Nov 2022 18:48:00 -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 6EC38E9309 for ; Fri, 18 Nov 2022 15:26:17 -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 1owA8k-0002j0-BZ; Fri, 18 Nov 2022 23:47:18 +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 1owA8h-0058VN-6C; Fri, 18 Nov 2022 23:47:16 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1owA8g-0000Aq-Tx; Fri, 18 Nov 2022 23:47:14 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Angel Iglesias , Lee Jones , Grant Likely , Wolfram Sang , Benjamin Herrenschmidt , Jonathan Cameron , Adrien Grassein , Jeremy Kerr , Benjamin Mugnier , Christophe Leroy Cc: linux-i2c@vger.kernel.org, kernel@pengutronix.de, =?utf-8?q?Uwe_Kleine-K?= =?utf-8?q?=C3=B6nig?= , linuxppc-dev@lists.ozlabs.org, linux-kernel@vger.kernel.org Subject: [PATCH 295/606] macintosh: windfarm_lm87_sensor: Convert to i2c's .probe_new() Date: Fri, 18 Nov 2022 23:40:29 +0100 Message-Id: <20221118224540.619276-296-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?1749880480267185453?= X-GMAIL-MSGID: =?utf-8?q?1749880480267185453?= From: Uwe Kleine-König The probe function doesn't make use of the i2c_device_id * parameter so it can be trivially converted. Signed-off-by: Uwe Kleine-König --- drivers/macintosh/windfarm_lm87_sensor.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/macintosh/windfarm_lm87_sensor.c b/drivers/macintosh/windfarm_lm87_sensor.c index 40d25463346e..f37a32c2070c 100644 --- a/drivers/macintosh/windfarm_lm87_sensor.c +++ b/drivers/macintosh/windfarm_lm87_sensor.c @@ -95,8 +95,7 @@ static const struct wf_sensor_ops wf_lm87_ops = { .owner = THIS_MODULE, }; -static int wf_lm87_probe(struct i2c_client *client, - const struct i2c_device_id *id) +static int wf_lm87_probe(struct i2c_client *client) { struct wf_lm87_sensor *lm; const char *name = NULL, *loc; @@ -173,7 +172,7 @@ static struct i2c_driver wf_lm87_driver = { .name = "wf_lm87", .of_match_table = wf_lm87_of_id, }, - .probe = wf_lm87_probe, + .probe_new = wf_lm87_probe, .remove = wf_lm87_remove, .id_table = wf_lm87_id, };