Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp1087389imw; Tue, 5 Jul 2022 03:38:25 -0700 (PDT) X-Google-Smtp-Source: AGRyM1uyewPH46E+HyUGaD4njM7b39hFc1wDRYtrptV7bCOt17A4TvZwhXJKJrVT/MMYkkPJ9adl X-Received: by 2002:a17:907:a04b:b0:72a:ee53:7d2e with SMTP id gz11-20020a170907a04b00b0072aee537d2emr408334ejc.764.1657017505286; Tue, 05 Jul 2022 03:38:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1657017505; cv=none; d=google.com; s=arc-20160816; b=LttTdzVce8xICTB/UrPqII0sEubeb20SqDRhGC6zn4redjgcfCcM8tz/ubNaqBgAZp DEKc4XLW9+SG9Lklo+FpZuSZB0zj4D8AfaR51isCTf79vw5RAGgdmHAStbCcRZWK+jUG vsFnccw6dEcSz9OwvFoRQMUUE4r+fXnd/SrNp+NgPp5MSh90Wh5TJO1eWJ0Mm5ufaqAF 9/k4/KKYgS5c8MTaLPV0dBK0CiUyWoDYN4D8/jurfGd+cvlgb5L/CwyPot+j+8NgNzpi UHxoY29X2VXTgpGZnP5o1mEjDetiCMMfg+ZE3FQsKr+X+di66YjZPbH9WPCGTsqjmEbz p/tA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=mEjtMakiW0EySpcbbvi4iHxAbsgXIOf2nckHkAxDFJs=; b=JQAENt/I4bsO4HN9XOXQcpzxKnK2c/4peJbDvI3E+zqcmJyvRjKuToFhAFrWZtRyXT jBy/HbQ9R/K2hdsdf4zsDtucMZlQJeAiSEuh3FI2u2gtZ0HS83tQWUzuCtS7x0aXFW3p gBA8MY6o/BQ/s+JBgTjjb01KDII3p+tszj43oF4xgFaZJ1oo+ZnOoaSAjXRMSVE3xRjo QpmvTrX6QYf3KVo4hRWAtW3krl7dpw+cBhTZkmdVLlNEYGgBra82IFvn6GugVQHOTdZH AXY4jEJxI/Orke1UBmOUjd2m1GTQNV8HLjVv2qk4IouudSgFsQbYEfd7Si5O9bKgXihD pT6g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v23-20020aa7d817000000b0043574594151si11096976edq.54.2022.07.05.03.37.48; Tue, 05 Jul 2022 03:38:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-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-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231375AbiGEKhI (ORCPT + 99 others); Tue, 5 Jul 2022 06:37:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59262 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230104AbiGEKhH (ORCPT ); Tue, 5 Jul 2022 06:37:07 -0400 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 0238DAE56 for ; Tue, 5 Jul 2022 03:37:06 -0700 (PDT) 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 1o8fuq-0001LC-19; Tue, 05 Jul 2022 12:36:24 +0200 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 1o8fue-004XxA-J7; Tue, 05 Jul 2022 12:36:16 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1o8fuh-0038F6-8t; Tue, 05 Jul 2022 12:36:15 +0200 Date: Tue, 5 Jul 2022 12:36:15 +0200 From: Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= To: Jean Delvare Cc: Wolfram Sang , Guenter Roeck , linux-i2c@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linuxppc-dev@lists.ozlabs.org, openipmi-developer@lists.sourceforge.net, linux-integrity@vger.kernel.org, linux-clk@vger.kernel.org, linux-crypto@vger.kernel.org, linux-gpio@vger.kernel.org, dri-devel@lists.freedesktop.org, chrome-platform@lists.linux.dev, linux-rpi-kernel@lists.infradead.org, linux-input@vger.kernel.org, linux-hwmon@vger.kernel.org, linux-iio@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-leds@vger.kernel.org, linux-media@vger.kernel.org, patches@opensource.cirrus.com, alsa-devel@alsa-project.org, linux-omap@vger.kernel.org, linux-mtd@lists.infradead.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, platform-driver-x86@vger.kernel.org, acpi4asus-user@lists.sourceforge.net, linux-pm@vger.kernel.org, linux-pwm@vger.kernel.org, linux-rtc@vger.kernel.org, linux-staging@lists.linux.dev, linux-serial@vger.kernel.org, linux-usb@vger.kernel.org, linux-fbdev@vger.kernel.org, linux-watchdog@vger.kernel.org, kasan-dev@googlegroups.com, linux-mediatek@lists.infradead.org Subject: Re: [PATCH 6/6] i2c: Make remove callback return void Message-ID: <20220705103615.ceeq7rku53x743ps@pengutronix.de> References: <20220628140313.74984-1-u.kleine-koenig@pengutronix.de> <20220628140313.74984-7-u.kleine-koenig@pengutronix.de> <20220705120852.049dc235@endymion.delvare> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="gut2agzhpaayxotv" Content-Disposition: inline In-Reply-To: <20220705120852.049dc235@endymion.delvare> 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-crypto@vger.kernel.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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-crypto@vger.kernel.org --gut2agzhpaayxotv Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jul 05, 2022 at 12:08:52PM +0200, Jean Delvare wrote: > On Tue, 28 Jun 2022 16:03:12 +0200, Uwe Kleine-K=F6nig wrote: > > From: Uwe Kleine-K=F6nig > >=20 > > The value returned by an i2c driver's remove function is mostly ignored. > > (Only an error message is printed if the value is non-zero that the > > error is ignored.) > >=20 > > So change the prototype of the remove function to return no value. This > > way driver authors are not tempted to assume that passing an error to > > the upper layer is a good idea. All drivers are adapted accordingly. > > There is no intended change of behaviour, all callbacks were prepared to > > return 0 before. > >=20 > > Signed-off-by: Uwe Kleine-K=F6nig > > --- >=20 > That's a huge change for a relatively small benefit, but if this is > approved by the I2C core maintainer then fine with me. For: Agreed, it's huge. The benefit isn't really measureable, the motivation is to improve the situation for driver authors who with the change cannot make wrong assumptions about what to return in .remove(). During the preparation this uncovered a few bugs. See for example bbc126ae381cf0a27822c1f822d0aeed74cc40d9. > > drivers/hwmon/adc128d818.c | 4 +--- > > drivers/hwmon/adt7470.c | 3 +-- > > drivers/hwmon/asb100.c | 6 ++---- > > drivers/hwmon/asc7621.c | 4 +--- > > drivers/hwmon/dme1737.c | 4 +--- > > drivers/hwmon/f75375s.c | 5 ++--- > > drivers/hwmon/fschmd.c | 6 ++---- > > drivers/hwmon/ftsteutates.c | 3 +-- > > drivers/hwmon/ina209.c | 4 +--- > > drivers/hwmon/ina3221.c | 4 +--- > > drivers/hwmon/jc42.c | 3 +-- > > drivers/hwmon/mcp3021.c | 4 +--- > > drivers/hwmon/occ/p8_i2c.c | 4 +--- > > drivers/hwmon/pcf8591.c | 3 +-- > > drivers/hwmon/smm665.c | 3 +-- > > drivers/hwmon/tps23861.c | 4 +--- > > drivers/hwmon/w83781d.c | 4 +--- > > drivers/hwmon/w83791d.c | 6 ++---- > > drivers/hwmon/w83792d.c | 6 ++---- > > drivers/hwmon/w83793.c | 6 ++---- > > drivers/hwmon/w83795.c | 4 +--- > > drivers/hwmon/w83l785ts.c | 6 ++---- > > drivers/i2c/i2c-core-base.c | 6 +----- > > drivers/i2c/i2c-slave-eeprom.c | 4 +--- > > drivers/i2c/i2c-slave-testunit.c | 3 +-- > > drivers/i2c/i2c-smbus.c | 3 +-- > > drivers/i2c/muxes/i2c-mux-ltc4306.c | 4 +--- > > drivers/i2c/muxes/i2c-mux-pca9541.c | 3 +-- > > drivers/i2c/muxes/i2c-mux-pca954x.c | 3 +-- >=20 > Reviewed-by: Jean Delvare Thanks Uwe --=20 Pengutronix e.K. | Uwe Kleine-K=F6nig | Industrial Linux Solutions | https://www.pengutronix.de/ | --gut2agzhpaayxotv Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEfnIqFpAYrP8+dKQLwfwUeK3K7AkFAmLEFBwACgkQwfwUeK3K 7AkavggAgLmynakXX/rOF4Jwy2OuBXH29kecKqPd6xj4yHsu3ggy8kd/hlU4jJib vV0H9ioq69hhMqjme5AHJJsueLFi/t/iwuQwuWUKluCBBlx0RXBsVx8qxV7A0uWa mdKU3ApPaN7y0cS1jccdN7ydsL3H2ayzIwfQuNqx1G3P/uqXfkusV0fjwQ/rQct3 qs4t2/QiHUd0tStlGw2eSKxp1z5KRrDMstK17fiZSsw/SYoMyldV8Ame6+gaxx0X e93FqM5jj67ovjD3jJanfOwI5vesu4+szu4GK6vHRWvpsieHsSeyS+GNgfM5oLA7 iguZ0rauzy0je3hrHuKgp1maJ59ibQ== =fYiS -----END PGP SIGNATURE----- --gut2agzhpaayxotv--