From patchwork Fri Nov 18 22:37:26 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: 22601 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:adf:f944:0:0:0:0:0 with SMTP id q4csp448889wrr; Fri, 18 Nov 2022 14:53:39 -0800 (PST) X-Google-Smtp-Source: AA0mqf6jL0jTZAfRvxYxX7nFbeHxwsFdS15lAF/UuftW0zpayovovpB40MwJ72FKTh1KrRPYblu1 X-Received: by 2002:a17:90a:8904:b0:218:93e8:800f with SMTP id u4-20020a17090a890400b0021893e8800fmr2019737pjn.136.1668812019453; Fri, 18 Nov 2022 14:53:39 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668812019; cv=none; d=google.com; s=arc-20160816; b=kDtkCuE4escJDI1gJd3F/J8PZ9UHqeLefqZdt91xqIFA4DUDUDgu/CG4FvEX3M/id/ Iu5rFaTg3fORUVCik5f9ytvWxNQWYZCwRtbkpe2vqsn5eZhoOVNbLb9tiK68IzxjFJyN gmEkq491WdQPbWMH/y0hFDpAig8KrPT8RoP44ExSKJIp/1eDhEA0nPwjnk5gvCVPGLz1 U1gafccNeTvGXA9WTYfDHivp9Np7q4GjfcK2b97GP4t1C1nyOa2JPhxFEWc8QosE/HJK ZqRzavChAVQAhr9Z1DuWPakeXh+Qo3tOpc6iL3F3sl5RlIt+PK9tavUsysFgTAAoX9/1 mQRQ== 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=jcNoMnU9Z2QJodsOTAuXq0Zxidpwu/AVnrNbbbBi7hE=; b=fM+wMcvQewDXY8ac6OOqfEad6cS/sGVxVOUDNUbK1GIgMFfJoNm3gNgY5ZsmVZc4ek y7KPFA0aPkyVPywSSnXRAy3GP3AXO8OJk+q2wcNiGS3RnH52Hq7MEdTXLraadxvLbMzh 8tgKDqUaB6r+nA1YUu4vQEJNdPXQ3boRUZZEp04YmweLwaOethqFZ5wcQLnHdAeZQLis yhuRheoVPV06aJ4rK2335zsbbHRY51TYBvXS7XXUhlgMJOzHlCyugDE69Bwn/HbL9ZMr wjCZLacw9GbGJj/XPdHQo57tXRqdrDFJIo348nr1SBi+vxdhnXcfp2Y8V0xW7oap9zPu QpCw== 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 n4-20020a170902d2c400b001836e51050esi5559855plc.572.2022.11.18.14.53.27; Fri, 18 Nov 2022 14:53:39 -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 S234463AbiKRWxA (ORCPT + 99 others); Fri, 18 Nov 2022 17:53:00 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51770 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234444AbiKRWw1 (ORCPT ); Fri, 18 Nov 2022 17:52:27 -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 EBC65B73B9 for ; Fri, 18 Nov 2022 14:47:33 -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 1owA85-0000RM-Eo; Fri, 18 Nov 2022 23:46:37 +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 1owA80-0058Ge-LX; Fri, 18 Nov 2022 23:46:33 +0100 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1owA7z-00Hb28-L4; Fri, 18 Nov 2022 23:46:31 +0100 From: =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= To: Angel Iglesias , Lee Jones , Grant Likely , Wolfram Sang , Jonathan Cameron Cc: linux-i2c@vger.kernel.org, kernel@pengutronix.de, =?utf-8?q?Uwe_Kleine-K?= =?utf-8?q?=C3=B6nig?= , Lars-Peter Clausen , linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 112/606] iio: light: adjd_s311: Convert to i2c's .probe_new() Date: Fri, 18 Nov 2022 23:37:26 +0100 Message-Id: <20221118224540.619276-113-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?1749876232279896740?= X-GMAIL-MSGID: =?utf-8?q?1749876232279896740?= 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/iio/light/adjd_s311.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/drivers/iio/light/adjd_s311.c b/drivers/iio/light/adjd_s311.c index 6b33975c8d73..210a90f44c53 100644 --- a/drivers/iio/light/adjd_s311.c +++ b/drivers/iio/light/adjd_s311.c @@ -233,8 +233,7 @@ static const struct iio_info adjd_s311_info = { .write_raw = adjd_s311_write_raw, }; -static int adjd_s311_probe(struct i2c_client *client, - const struct i2c_device_id *id) +static int adjd_s311_probe(struct i2c_client *client) { struct adjd_s311_data *data; struct iio_dev *indio_dev; @@ -271,7 +270,7 @@ static struct i2c_driver adjd_s311_driver = { .driver = { .name = ADJD_S311_DRV_NAME, }, - .probe = adjd_s311_probe, + .probe_new = adjd_s311_probe, .id_table = adjd_s311_id, }; module_i2c_driver(adjd_s311_driver);