Message ID | 20220123175201.34839-1-u.kleine-koenig@pengutronix.de |
---|---|
Headers | show |
Series | spi: make remove callback a void function | expand |
My usual mailer won't let me reply to this many people, so I'm using Gmail. No idea what chaos this will cause, but here goes ... > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > --- [...] > drivers/mfd/arizona-spi.c | 4 +--- > drivers/mfd/da9052-spi.c | 3 +-- > drivers/mfd/ezx-pcap.c | 4 +--- > drivers/mfd/madera-spi.c | 4 +--- > drivers/mfd/mc13xxx-spi.c | 3 +-- > drivers/mfd/rsmu_spi.c | 4 +--- > drivers/mfd/stmpe-spi.c | 4 +--- > drivers/mfd/tps65912-spi.c | 4 +--- > drivers/video/backlight/ams369fg06.c | 3 +-- > drivers/video/backlight/corgi_lcd.c | 3 +-- > drivers/video/backlight/ili922x.c | 3 +-- > drivers/video/backlight/l4f00242t03.c | 3 +-- > drivers/video/backlight/lms501kf03.c | 3 +-- > drivers/video/backlight/ltv350qv.c | 3 +-- > drivers/video/backlight/tdo24m.c | 3 +-- > drivers/video/backlight/tosa_lcd.c | 4 +--- > drivers/video/backlight/vgg2432a4.c | 4 +--- If it's okay with Mark, it's okay with me. Acked-by: Lee Jones <lee.jones@linaro.org>
Hi Uwe, u.kleine-koenig@pengutronix.de wrote on Sun, 23 Jan 2022 18:52:01 +0100: > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > --- [...] > drivers/mtd/devices/mchp23k256.c | 4 +--- > drivers/mtd/devices/mchp48l640.c | 4 +--- > drivers/mtd/devices/mtd_dataflash.c | 4 +--- > drivers/mtd/devices/sst25l.c | 4 +--- For MTD devices: Acked-by: Miquel Raynal <miquel.raynal@bootlin.com> Thanks, Miquèl
On Sun, Jan 23, 2022 at 6:54 PM Uwe Kleine-König <u.kleine-koenig@pengutronix.de> wrote: > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > drivers/spi/spi-slave-system-control.c | 3 +-- > drivers/spi/spi-slave-time.c | 3 +-- > drivers/spi/spi.c | 11 ++--------- > drivers/spi/spidev.c | 4 +--- Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds
On Sun, Jan 23, 2022 at 06:52:01PM +0100, Uwe Kleine-König wrote: > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. I was going to apply this but it needs rebasing against current code unfortunately.
On 23/01/2022 18:52, Uwe Kleine-König wrote: > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. > > Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> > --- > drivers/bus/moxtet.c | 4 +--- > drivers/char/tpm/st33zp24/spi.c | 4 +--- > drivers/char/tpm/tpm_tis_spi_main.c | 3 +-- > drivers/clk/clk-lmk04832.c | 4 +--- > drivers/gpio/gpio-74x164.c | 4 +--- > drivers/gpio/gpio-max3191x.c | 4 +--- > drivers/gpio/gpio-max7301.c | 4 +--- > drivers/gpio/gpio-mc33880.c | 4 +--- > drivers/gpio/gpio-pisosr.c | 4 +--- > drivers/gpu/drm/panel/panel-abt-y030xx067a.c | 4 +--- > drivers/gpu/drm/panel/panel-ilitek-ili9322.c | 4 +--- > drivers/gpu/drm/panel/panel-ilitek-ili9341.c | 3 +-- > drivers/gpu/drm/panel/panel-innolux-ej030na.c | 4 +--- > drivers/gpu/drm/panel/panel-lg-lb035q02.c | 4 +--- > drivers/gpu/drm/panel/panel-lg-lg4573.c | 4 +--- > drivers/gpu/drm/panel/panel-nec-nl8048hl11.c | 4 +--- > drivers/gpu/drm/panel/panel-novatek-nt39016.c | 4 +--- > drivers/gpu/drm/panel/panel-samsung-db7430.c | 3 +-- > drivers/gpu/drm/panel/panel-samsung-ld9040.c | 4 +--- > drivers/gpu/drm/panel/panel-samsung-s6d27a1.c | 3 +-- > drivers/gpu/drm/panel/panel-samsung-s6e63m0-spi.c | 3 +-- > drivers/gpu/drm/panel/panel-sitronix-st7789v.c | 4 +--- > drivers/gpu/drm/panel/panel-sony-acx565akm.c | 4 +--- > drivers/gpu/drm/panel/panel-tpo-td028ttec1.c | 4 +--- > drivers/gpu/drm/panel/panel-tpo-td043mtea1.c | 4 +--- > drivers/gpu/drm/panel/panel-tpo-tpg110.c | 3 +-- > drivers/gpu/drm/panel/panel-widechips-ws2401.c | 3 +-- > drivers/gpu/drm/tiny/hx8357d.c | 4 +--- > drivers/gpu/drm/tiny/ili9163.c | 4 +--- > drivers/gpu/drm/tiny/ili9225.c | 4 +--- > drivers/gpu/drm/tiny/ili9341.c | 4 +--- > drivers/gpu/drm/tiny/ili9486.c | 4 +--- > drivers/gpu/drm/tiny/mi0283qt.c | 4 +--- > drivers/gpu/drm/tiny/repaper.c | 4 +--- > drivers/gpu/drm/tiny/st7586.c | 4 +--- > drivers/gpu/drm/tiny/st7735r.c | 4 +--- > drivers/hwmon/adcxx.c | 4 +--- > drivers/hwmon/adt7310.c | 3 +-- > drivers/hwmon/max1111.c | 3 +-- > drivers/hwmon/max31722.c | 4 +--- > drivers/iio/accel/bma400_spi.c | 4 +--- > drivers/iio/accel/bmc150-accel-spi.c | 4 +--- > drivers/iio/accel/bmi088-accel-spi.c | 4 +--- > drivers/iio/accel/kxsd9-spi.c | 4 +--- > drivers/iio/accel/mma7455_spi.c | 4 +--- > drivers/iio/accel/sca3000.c | 4 +--- > drivers/iio/adc/ad7266.c | 4 +--- > drivers/iio/adc/ltc2496.c | 4 +--- > drivers/iio/adc/mcp320x.c | 4 +--- > drivers/iio/adc/mcp3911.c | 4 +--- > drivers/iio/adc/ti-adc12138.c | 4 +--- > drivers/iio/adc/ti-ads7950.c | 4 +--- > drivers/iio/adc/ti-ads8688.c | 4 +--- > drivers/iio/adc/ti-tlc4541.c | 4 +--- > drivers/iio/amplifiers/ad8366.c | 4 +--- > drivers/iio/common/ssp_sensors/ssp_dev.c | 4 +--- > drivers/iio/dac/ad5360.c | 4 +--- > drivers/iio/dac/ad5380.c | 4 +--- > drivers/iio/dac/ad5446.c | 4 +--- > drivers/iio/dac/ad5449.c | 4 +--- > drivers/iio/dac/ad5504.c | 4 +--- > drivers/iio/dac/ad5592r.c | 4 +--- > drivers/iio/dac/ad5624r_spi.c | 4 +--- > drivers/iio/dac/ad5686-spi.c | 4 +--- > drivers/iio/dac/ad5761.c | 4 +--- > drivers/iio/dac/ad5764.c | 4 +--- > drivers/iio/dac/ad5791.c | 4 +--- > drivers/iio/dac/ad8801.c | 4 +--- > drivers/iio/dac/ltc1660.c | 4 +--- > drivers/iio/dac/ltc2632.c | 4 +--- > drivers/iio/dac/mcp4922.c | 4 +--- > drivers/iio/dac/ti-dac082s085.c | 4 +--- > drivers/iio/dac/ti-dac7311.c | 3 +-- > drivers/iio/frequency/adf4350.c | 4 +--- > drivers/iio/gyro/bmg160_spi.c | 4 +--- > drivers/iio/gyro/fxas21002c_spi.c | 4 +--- > drivers/iio/health/afe4403.c | 4 +--- > drivers/iio/magnetometer/bmc150_magn_spi.c | 4 +--- > drivers/iio/magnetometer/hmc5843_spi.c | 4 +--- > drivers/iio/potentiometer/max5487.c | 4 +--- > drivers/iio/pressure/ms5611_spi.c | 4 +--- > drivers/iio/pressure/zpa2326_spi.c | 4 +--- > drivers/input/keyboard/applespi.c | 4 +--- > drivers/input/misc/adxl34x-spi.c | 4 +--- > drivers/input/touchscreen/ads7846.c | 4 +--- > drivers/input/touchscreen/cyttsp4_spi.c | 4 +--- > drivers/input/touchscreen/tsc2005.c | 4 +--- > drivers/leds/leds-cr0014114.c | 4 +--- > drivers/leds/leds-dac124s085.c | 4 +--- > drivers/leds/leds-el15203000.c | 4 +--- > drivers/leds/leds-spi-byte.c | 4 +--- > drivers/media/spi/cxd2880-spi.c | 4 +--- > drivers/media/spi/gs1662.c | 4 +--- > drivers/media/tuners/msi001.c | 3 +-- A bit late, but for drivers/media: Acked-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Thanks! Hans
Hi! > The value returned by an spi driver's remove function is mostly ignored. > (Only an error message is printed if the value is non-zero that the > error is ignored.) > > 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. Acked-by: Pavel Machek <pavel@ucw.cz> Pavel