IIO: Drop manual assignment of THIS_MODULE
Subsystems (52)
Jonathan Cameron
maintainercover IIO: Drop manual assignment of THIS_MODULE
This has been in the todo list for quite some time. There are two places in IIO in which every driver assigns THIS_MODULE to a structure element, so that the core can correctly assign ownership of various resources.
With a simple macro, and moving the actual element used to store these out of the relevant ops structures we can remove the necessity to do this leading to a reduction in boilerplate.
We have a few iio drivers as part of other drivers outside of IIO, but I have hopefully caught all of those.
I've split it mainly up into directories just to avoid having several hundred patches for such a trivial per driver change. I'm not going to attempt to put together a coherent cc list for these and instead am mostly just going to post them to the mailing list for general review.
Thanks,
Jonathan
Jonathan Cameron (38):
iio: Use macro magic to avoid manual assign of driver_module
iio: triggers: Use macros to avoid boilerplate assignment of owner.
coccinelle: Add an iio_no_owner semantic patch to drop driver_owner iio:adc: drop assign iio_info.driver_module and iio_trigger_ops.owner iio:accel: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:amplifiers:ad8366 drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:chemical: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:common: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:counter:104-quad-8 drop assign iio_info.driver_module iio:dac: drop assignment of iio_info.driver_module iio:dummy: drop assignment of iio_info.driver_module iio:frequency: drop assign iio_info.driver_module iio:gyro: drop assign iio_info.driver_module and iio_trigger_ops.owner iio:health: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:humidity: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:imu: drop assign iio_info.driver_module and iio_trigger_ops.owner iio:light: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:magnetometer: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:orientation: drop assign iio_info.driver_module iio:dpot: drop assign iio_info.driver_module iio:potentiostat:lmp91000 drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:pressure: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:proximity: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:temperature: drop assignment of iio_info.driver_module iio:triggers: drop assign iio_info.driver_module and
iio_trigger_ops.owner
staging:iio:accel: drop assignment of iio_info.driver_module staging:iio:adc: drop assign iio_info.driver_module staging:iio:cdc: drop assign iio_info.driver_module staging:iio:frequency: drop assign iio_info.driver_module staging:iio:gyro:adis16060 drop assign iio_info.driver_module staging:iio:ad5933: drop assign iio_info.driver_module staging:iio:meter: drop assign iio_info.driver_module and
iio_trigger_ops.owner
iio:resolver: drop assignment of iio_info.driver_module iio:adc: drop assignment of iio_trigger_ops.owner staging:iio:light:tsl2x7x drop assignment of driver_module
input: tsc2007 - drop the driver_module assignment in iio interface. platform/x86: toshiba_acpi: drop assignment of iio_info.driver_module
iio: drop iio_info.driver_module and iio_trigger_ops.owner.
drivers/iio/accel/adxl345_core.c | 1 - drivers/iio/accel/bma180.c | 2 - drivers/iio/accel/bma220_spi.c | 1 - drivers/iio/accel/bmc150-accel-core.c | 3 - drivers/iio/accel/da280.c | 1 - drivers/iio/accel/da311.c | 1 - drivers/iio/accel/dmard06.c | 1 - drivers/iio/accel/dmard09.c | 1 - drivers/iio/accel/dmard10.c | 1 - drivers/iio/accel/hid-sensor-accel-3d.c | 1 - drivers/iio/accel/kxcjk-1013.c | 2 - drivers/iio/accel/kxsd9.c | 1 - drivers/iio/accel/mc3230.c | 1 - drivers/iio/accel/mma7455_core.c | 1 - drivers/iio/accel/mma7660.c | 1 - drivers/iio/accel/mma8452.c | 2 - drivers/iio/accel/mma9551.c | 1 - drivers/iio/accel/mma9553.c | 1 - drivers/iio/accel/mxc4005.c | 2 - drivers/iio/accel/mxc6255.c | 1 - drivers/iio/accel/sca3000.c | 1 - drivers/iio/accel/st_accel_core.c | 2 - drivers/iio/accel/stk8312.c | 2 - drivers/iio/accel/stk8ba50.c | 2 - drivers/iio/adc/ad7266.c | 1 - drivers/iio/adc/ad7291.c | 1 - drivers/iio/adc/ad7298.c | 1 - drivers/iio/adc/ad7476.c | 1 - drivers/iio/adc/ad7766.c | 2 - drivers/iio/adc/ad7791.c | 2 - drivers/iio/adc/ad7793.c | 2 - drivers/iio/adc/ad7887.c | 1 - drivers/iio/adc/ad7923.c | 1 - drivers/iio/adc/ad799x.c | 3 - drivers/iio/adc/ad_sigma_delta.c | 1 - drivers/iio/adc/aspeed_adc.c | 1 - drivers/iio/adc/at91-sama5d2_adc.c | 1 - drivers/iio/adc/at91_adc.c | 2 - drivers/iio/adc/axp288_adc.c | 1 - drivers/iio/adc/bcm_iproc_adc.c | 1 - drivers/iio/adc/berlin2-adc.c | 1 - drivers/iio/adc/cc10001_adc.c | 1 - drivers/iio/adc/cpcap-adc.c | 1 - drivers/iio/adc/da9150-gpadc.c | 1 - drivers/iio/adc/envelope-detector.c | 1 - drivers/iio/adc/exynos_adc.c | 1 - drivers/iio/adc/hi8435.c | 1 - drivers/iio/adc/hx711.c | 1 - drivers/iio/adc/imx7d_adc.c | 1 - drivers/iio/adc/ina2xx-adc.c | 1 - drivers/iio/adc/lp8788_adc.c | 1 - drivers/iio/adc/lpc18xx_adc.c | 1 - drivers/iio/adc/lpc32xx_adc.c | 1 - drivers/iio/adc/ltc2485.c | 1 - drivers/iio/adc/ltc2497.c | 1 - drivers/iio/adc/max1027.c | 2 - drivers/iio/adc/max11100.c | 1 - drivers/iio/adc/max1118.c | 1 - drivers/iio/adc/max1363.c | 2 - drivers/iio/adc/max9611.c | 1 - drivers/iio/adc/mcp320x.c | 1 - drivers/iio/adc/mcp3422.c | 1 - drivers/iio/adc/men_z188_adc.c | 1 - drivers/iio/adc/meson_saradc.c | 1 - drivers/iio/adc/mt6577_auxadc.c | 1 - drivers/iio/adc/mxs-lradc-adc.c | 2 - drivers/iio/adc/nau7802.c | 1 - drivers/iio/adc/palmas_gpadc.c | 1 - drivers/iio/adc/qcom-pm8xxx-xoadc.c | 1 - drivers/iio/adc/qcom-spmi-iadc.c | 1 - drivers/iio/adc/qcom-spmi-vadc.c | 1 - drivers/iio/adc/rcar-gyroadc.c | 1 - drivers/iio/adc/rockchip_saradc.c | 1 - drivers/iio/adc/spear_adc.c | 1 - drivers/iio/adc/stm32-adc.c | 1 - drivers/iio/adc/stx104.c | 1 - drivers/iio/adc/sun4i-gpadc-iio.c | 1 - drivers/iio/adc/ti-adc081c.c | 1 - drivers/iio/adc/ti-adc0832.c | 1 - drivers/iio/adc/ti-adc084s021.c | 1 - drivers/iio/adc/ti-adc108s102.c | 1 - drivers/iio/adc/ti-adc12138.c | 1 - drivers/iio/adc/ti-adc128s052.c | 1 - drivers/iio/adc/ti-adc161s626.c | 1 - drivers/iio/adc/ti-ads1015.c | 2 - drivers/iio/adc/ti-ads7950.c | 1 - drivers/iio/adc/ti-ads8688.c | 1 - drivers/iio/adc/ti-tlc4541.c | 1 - drivers/iio/adc/ti_am335x_adc.c | 1 - drivers/iio/adc/twl4030-madc.c | 1 - drivers/iio/adc/twl6030-gpadc.c | 1 - drivers/iio/adc/vf610_adc.c | 1 - drivers/iio/adc/viperboard_adc.c | 1 - drivers/iio/adc/xilinx-xadc-core.c | 2 - drivers/iio/amplifiers/ad8366.c | 1 - drivers/iio/chemical/ams-iaq-core.c | 1 - drivers/iio/chemical/atlas-ph-sensor.c | 2 - drivers/iio/chemical/vz89x.c | 1 - .../iio/common/cros_ec_sensors/cros_ec_sensors.c | 1 - .../iio/common/hid-sensors/hid-sensor-trigger.c | 1 - drivers/iio/counter/104-quad-8.c | 1 - drivers/iio/dac/ad5064.c | 1 - drivers/iio/dac/ad5360.c | 1 - drivers/iio/dac/ad5380.c | 1 - drivers/iio/dac/ad5421.c | 1 - drivers/iio/dac/ad5446.c | 1 - drivers/iio/dac/ad5449.c | 1 - drivers/iio/dac/ad5504.c | 1 - drivers/iio/dac/ad5592r-base.c | 1 - drivers/iio/dac/ad5624r_spi.c | 1 - drivers/iio/dac/ad5686.c | 1 - drivers/iio/dac/ad5755.c | 1 - drivers/iio/dac/ad5761.c | 1 - drivers/iio/dac/ad5764.c | 1 - drivers/iio/dac/ad5791.c | 1 - drivers/iio/dac/ad7303.c | 1 - drivers/iio/dac/ad8801.c | 1 - drivers/iio/dac/cio-dac.c | 1 - drivers/iio/dac/dpot-dac.c | 1 - drivers/iio/dac/lpc18xx_dac.c | 1 - drivers/iio/dac/ltc2632.c | 1 - drivers/iio/dac/m62332.c | 1 - drivers/iio/dac/max517.c | 1 - drivers/iio/dac/max5821.c | 1 - drivers/iio/dac/mcp4725.c | 1 - drivers/iio/dac/mcp4922.c | 1 - drivers/iio/dac/stm32-dac.c | 1 - drivers/iio/dac/vf610_dac.c | 1 - drivers/iio/dummy/iio_simple_dummy.c | 1 - drivers/iio/frequency/ad9523.c | 1 - drivers/iio/frequency/adf4350.c | 1 - drivers/iio/gyro/adis16080.c | 1 - drivers/iio/gyro/adis16130.c | 1 - drivers/iio/gyro/adis16136.c | 1 - drivers/iio/gyro/adis16260.c | 1 - drivers/iio/gyro/adxrs450.c | 1 - drivers/iio/gyro/bmg160_core.c | 2 - drivers/iio/gyro/hid-sensor-gyro-3d.c | 1 - drivers/iio/gyro/itg3200_buffer.c | 1 - drivers/iio/gyro/itg3200_core.c | 1 - drivers/iio/gyro/mpu3050-core.c | 2 - drivers/iio/gyro/st_gyro_core.c | 2 - drivers/iio/health/afe4403.c | 2 - drivers/iio/health/afe4404.c | 2 - drivers/iio/health/max30100.c | 1 - drivers/iio/health/max30102.c | 1 - drivers/iio/humidity/am2315.c | 1 - drivers/iio/humidity/dht11.c | 1 - drivers/iio/humidity/hdc100x.c | 1 - drivers/iio/humidity/hid-sensor-humidity.c | 1 - drivers/iio/humidity/hts221_buffer.c | 1 - drivers/iio/humidity/hts221_core.c | 1 - drivers/iio/humidity/htu21.c | 1 - drivers/iio/humidity/si7005.c | 1 - drivers/iio/humidity/si7020.c | 1 - drivers/iio/imu/adis16400_core.c | 1 - drivers/iio/imu/adis16480.c | 1 - drivers/iio/imu/adis_trigger.c | 1 - drivers/iio/imu/bmi160/bmi160_core.c | 1 - drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 1 - drivers/iio/imu/inv_mpu6050/inv_mpu_trigger.c | 1 - drivers/iio/imu/kmx61.c | 3 - drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c | 2 - drivers/iio/industrialio-core.c | 35 +++----- drivers/iio/industrialio-trigger.c | 24 +++--- drivers/iio/light/acpi-als.c | 1 - drivers/iio/light/adjd_s311.c | 1 - drivers/iio/light/al3320a.c | 1 - drivers/iio/light/apds9300.c | 2 - drivers/iio/light/apds9960.c | 1 - drivers/iio/light/bh1750.c | 1 - drivers/iio/light/bh1780.c | 1 - drivers/iio/light/cm32181.c | 1 - drivers/iio/light/cm3232.c | 1 - drivers/iio/light/cm3323.c | 1 - drivers/iio/light/cm3605.c | 1 - drivers/iio/light/cm36651.c | 1 - drivers/iio/light/cros_ec_light_prox.c | 1 - drivers/iio/light/gp2ap020a00f.c | 2 - drivers/iio/light/hid-sensor-als.c | 1 - drivers/iio/light/hid-sensor-prox.c | 1 - drivers/iio/light/isl29018.c | 2 - drivers/iio/light/isl29028.c | 1 - drivers/iio/light/isl29125.c | 1 - drivers/iio/light/jsa1212.c | 1 - drivers/iio/light/lm3533-als.c | 1 - drivers/iio/light/ltr501.c | 4 - drivers/iio/light/max44000.c | 1 - drivers/iio/light/opt3001.c | 1 - drivers/iio/light/pa12203001.c | 1 - drivers/iio/light/rpr0521.c | 1 - drivers/iio/light/si1145.c | 3 - drivers/iio/light/stk3310.c | 1 - drivers/iio/light/tcs3414.c | 1 - drivers/iio/light/tcs3472.c | 1 - drivers/iio/light/tsl2563.c | 2 - drivers/iio/light/tsl2583.c | 1 - drivers/iio/light/tsl4531.c | 1 - drivers/iio/light/us5182d.c | 1 - drivers/iio/light/vcnl4000.c | 1 - drivers/iio/light/veml6070.c | 1 - drivers/iio/light/vl6180.c | 1 - drivers/iio/magnetometer/ak8974.c | 1 - drivers/iio/magnetometer/ak8975.c | 1 - drivers/iio/magnetometer/bmc150_magn.c | 2 - drivers/iio/magnetometer/hid-sensor-magn-3d.c | 1 - drivers/iio/magnetometer/hmc5843_core.c | 1 - drivers/iio/magnetometer/mag3110.c | 1 - drivers/iio/magnetometer/mmc35240.c | 1 - drivers/iio/magnetometer/st_magn_core.c | 2 - drivers/iio/orientation/hid-sensor-incl-3d.c | 1 - drivers/iio/orientation/hid-sensor-rotation.c | 1 - drivers/iio/potentiometer/ds1803.c | 1 - drivers/iio/potentiometer/max5481.c | 1 - drivers/iio/potentiometer/max5487.c | 1 - drivers/iio/potentiometer/mcp4131.c | 1 - drivers/iio/potentiometer/mcp4531.c | 1 - drivers/iio/potentiometer/tpl0102.c | 1 - drivers/iio/potentiostat/lmp91000.c | 2 - drivers/iio/pressure/abp060mg.c | 1 - drivers/iio/pressure/bmp280-core.c | 1 - drivers/iio/pressure/cros_ec_baro.c | 1 - drivers/iio/pressure/hid-sensor-press.c | 1 - drivers/iio/pressure/hp03.c | 1 - drivers/iio/pressure/hp206c.c | 1 - drivers/iio/pressure/mpl115.c | 1 - drivers/iio/pressure/mpl3115.c | 1 - drivers/iio/pressure/ms5611_core.c | 1 - drivers/iio/pressure/ms5637.c | 1 - drivers/iio/pressure/st_pressure_core.c | 2 - drivers/iio/pressure/t5403.c | 1 - drivers/iio/pressure/zpa2326.c | 2 - drivers/iio/proximity/as3935.c | 2 - drivers/iio/proximity/pulsedlight-lidar-lite-v2.c | 1 - drivers/iio/proximity/srf04.c | 1 - drivers/iio/proximity/srf08.c | 1 - drivers/iio/proximity/sx9500.c | 2 - drivers/iio/temperature/hid-sensor-temperature.c | 1 - drivers/iio/temperature/maxim_thermocouple.c | 1 - drivers/iio/temperature/mlx90614.c | 1 - drivers/iio/temperature/tmp006.c | 1 - drivers/iio/temperature/tmp007.c | 1 - drivers/iio/temperature/tsys01.c | 1 - drivers/iio/temperature/tsys02d.c | 1 - drivers/iio/trigger/iio-trig-hrtimer.c | 1 - drivers/iio/trigger/iio-trig-interrupt.c | 1 - drivers/iio/trigger/iio-trig-loop.c | 1 - drivers/iio/trigger/iio-trig-sysfs.c | 1 - drivers/iio/trigger/stm32-timer-trigger.c | 2 - drivers/input/touchscreen/tsc2007_iio.c | 1 - drivers/platform/x86/toshiba_acpi.c | 1 - drivers/staging/iio/accel/adis16201.c | 1 - drivers/staging/iio/accel/adis16203.c | 1 - drivers/staging/iio/accel/adis16209.c | 1 - drivers/staging/iio/accel/adis16240.c | 1 - drivers/staging/iio/adc/ad7192.c | 2 - drivers/staging/iio/adc/ad7280a.c | 1 - drivers/staging/iio/adc/ad7606.c | 4 - drivers/staging/iio/adc/ad7780.c | 1 - drivers/staging/iio/adc/ad7816.c | 1 - drivers/staging/iio/addac/adt7316.c | 2 - drivers/staging/iio/cdc/ad7150.c | 1 - drivers/staging/iio/cdc/ad7152.c | 1 - drivers/staging/iio/cdc/ad7746.c | 1 - drivers/staging/iio/frequency/ad9832.c | 1 - drivers/staging/iio/frequency/ad9834.c | 2 - drivers/staging/iio/gyro/adis16060_core.c | 1 - drivers/staging/iio/impedance-analyzer/ad5933.c | 1 - drivers/staging/iio/light/tsl2x7x.c | 5 -- drivers/staging/iio/meter/ade7753.c | 1 - drivers/staging/iio/meter/ade7754.c | 1 - drivers/staging/iio/meter/ade7758_core.c | 1 - drivers/staging/iio/meter/ade7758_trigger.c | 1 - drivers/staging/iio/meter/ade7759.c | 1 - drivers/staging/iio/meter/ade7854.c | 1 - drivers/staging/iio/resolver/ad2s1200.c | 1 - drivers/staging/iio/resolver/ad2s1210.c | 1 - drivers/staging/iio/resolver/ad2s90.c | 1 - drivers/staging/iio/trigger/iio-trig-bfin-timer.c | 1 - include/linux/iio/iio.h | 34 ++++++-- include/linux/iio/trigger.h | 20 +++-- scripts/coccinelle/api/iio_no_owner.cocci | 94 ++++++++++++++++++++++ 282 files changed, 160 insertions(+), 380 deletions(-) create mode 100644 scripts/coccinelle/api/iio_no_owner.cocci
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 1/38 iio: Use macro magic to avoid manual assign of driver_module
Starting point in boiler plate reduction similar to that done for many similar cases elsewhere in the kernel.
--- drivers/iio/industrialio-core.c | 35 +++++++++-------------------------- drivers/iio/industrialio-trigger.c | 6 +++--- include/linux/iio/iio.h | 31 +++++++++++++++++++++++++++++-- 3 files changed, 41 insertions(+), 31 deletions(-)
drivers/iio/industrialio-core.c +9 -26
@@ -1665,14 +1665,11 @@ static int iio_check_unique_scan_index(struct iio_dev *indio_dev)static const struct iio_buffer_setup_ops noop_ring_setup_ops; -/** -* iio_device_register() - register a device with the IIO subsystem -* @indio_dev: Device structure filled by the device driver -**/ -int iio_device_register (struct iio_dev *indio_dev) +int __iio_device_register (struct iio_dev *indio_dev,struct module *this_mod) {int ret; + indio_dev->driver_module = this_mod;/* If the calling driver did not initialize of_node, do it here */ if (!indio_dev->dev.of_node && indio_dev->dev.parent) indio_dev->dev.of_node = indio_dev->dev.parent->of_node;
@@ -1718,7 +1715,8 @@ int iio_device_register(struct iio_dev *indio_dev) indio_dev->setup_ops = &noop_ring_setup_ops;cdev_init (&indio_dev->chrdev, &iio_buffer_fileops); - indio_dev->chrdev.owner = indio_dev->info->driver_module; + + indio_dev->chrdev.owner = this_mod; ret =cdev_device_add (&indio_dev->chrdev, &indio_dev->dev);if (ret <0 )
@@ -1736,7 +1734,7 @@ int iio_device_register(struct iio_dev *indio_dev)iio_device_unregister_debugfs (indio_dev);return ret; } -EXPORT_SYMBOL (iio_device_register); +EXPORT_SYMBOL (__iio_device_register);/** * iio_device_unregister() - unregister a device from the IIO subsystem
@@ -1768,23 +1766,8 @@ static void devm_iio_device_unreg(struct device *dev, void *res)iio_device_unregister (*(struct iio_dev **)res); } -/** -* devm_iio_device_register - Resource-managed iio_device_register() -* @dev: Device to allocate iio_dev for -* @indio_dev: Device structure filled by the device driver -* -* Managed iio_device_register. The IIO device registered with this -* function is automatically unregistered on driver detach. This function -* calls iio_device_register() internally. Refer to that function for more -* information. -* -* If an iio_dev registered with this function needs to be unregistered -* separately, devm_iio_device_unregister() must be used. -* -* RETURNS: -* 0 on success, negative error number on failure. -*/ -int devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev) +int __devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev, +struct module *this_mod) {struct iio_dev **ptr;int ret;
@@ -1794,7 +1777,7 @@ int devm_iio_device_register(struct device *dev, struct iio_dev *indio_dev)return -ENOMEM ; *ptr = indio_dev; - ret =iio_device_register (indio_dev); + ret =__iio_device_register (indio_dev, this_mod);if (!ret)devres_add (dev, ptr);else
@@ -1802,7 +1785,7 @@ int devm_iio_device_register(struct device *dev, struct iio_dev *indio_dev)return ret; } -EXPORT_SYMBOL_GPL (devm_iio_device_register); +EXPORT_SYMBOL_GPL (__devm_iio_device_register);/** * devm_iio_device_unregister - Resource-managed iio_device_unregister()
drivers/iio/industrialio-trigger.c +3 -3
@@ -250,7 +250,7 @@ static int iio_trigger_attach_poll_func(struct iio_trigger *trig, = bitmap_empty(trig->pool, CONFIG_IIO_CONSUMERS_PER_TRIGGER);/* Prevent the module from being removed whilst attached to a trigger */ -__module_get (pf->indio_dev->info->driver_module); +__module_get (pf->indio_dev->driver_module);/* Get irq number */ pf->irq =iio_trigger_get_irq (trig);
@@ -286,7 +286,7 @@ static int iio_trigger_attach_poll_func(struct iio_trigger *trig, out_put_irq:iio_trigger_put_irq (trig, pf->irq); out_put_module: -module_put (pf->indio_dev->info->driver_module); +module_put (pf->indio_dev->driver_module);return ret; }
@@ -307,7 +307,7 @@ static int iio_trigger_detach_poll_func(struct iio_trigger *trig, trig->attached_own_device = false;iio_trigger_put_irq (trig, pf->irq);free_irq (pf->irq, pf); -module_put (pf->indio_dev->info->driver_module); +module_put (pf->indio_dev->driver_module);return ret; }
include/linux/iio/iio.h +29 -2
@@ -512,6 +512,7 @@ struct iio_buffer_setup_ops {/** * struct iio_dev - industrial I/O device * @id: [INTERN] used to identify device internally +* @driver_module: [INTERN] used to make it harder to undercut users * @modes: [DRIVER] operating modes supported by device * @currentmode: [DRIVER] current operating mode * @dev: [DRIVER] device structure, should be assigned a parent
@@ -552,6 +553,7 @@ struct iio_buffer_setup_ops {*/ struct iio_dev {int id; +struct module *driver_module;int modes;int currentmode;
@@ -598,9 +600,34 @@ struct iio_dev {const struct iio_chan_spec *iio_find_channel_from_si (struct iio_dev *indio_dev,int si); -int iio_device_register (struct iio_dev *indio_dev); +/** +* iio_device_register() - register a device with the IIO subsystem +* @indio_dev: Device structure filled by the device driver +**/ +#define iio_device_register (iio_dev) \ + __iio_device_register(iio_dev, THIS_MODULE) +int __iio_device_register (struct iio_dev *indio_dev,struct module *this_mod);void iio_device_unregister (struct iio_dev *indio_dev); -int devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev); +/** +* devm_iio_device_register - Resource-managed iio_device_register() +* @dev: Device to allocate iio_dev for +* @indio_dev: Device structure filled by the device driver +* +* Managed iio_device_register. The IIO device registered with this +* function is automatically unregistered on driver detach. This function +* calls iio_device_register() internally. Refer to that function for more +* information. +* +* If an iio_dev registered with this function needs to be unregistered +* separately, devm_iio_device_unregister() must be used. +* +* RETURNS: +* 0 on success, negative error number on failure. +*/ +#define devm_iio_device_register (dev, indio_dev) \ + __devm_iio_device_register(dev, indio_dev, THIS_MODULE); +int __devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev, +struct module *this_mod);void devm_iio_device_unregister (struct device *dev,struct iio_dev *indio_dev);int iio_push_event (struct iio_dev *indio_dev,u64 ev_code,s64 timestamp);int iio_device_claim_direct_mode (struct iio_dev *indio_dev);
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerRe: [PATCH 01/38] iio: Use macro magic to avoid manual assign of driver_module
Quoted 4 lines · On Mon, 29 May 2017 16:51:17 +0100 Jonathan Cameron <[email protected]> wrote:
Starting point in boiler plate reduction similar to that done for many similar cases elsewhere in the kernel.
Signed-off-by Jonathan Cameron <[email protected]>
Hi all,
I've been slightly less lazy than last week and added some cc's.
If any of you lovely people have a bit of time to take a look at the first two patches in this series that would be great.
I'm definitely looking for a acked-by or reviewed-by on this series before applying.
Thanks,
Jonathan
Quoted 178 lines
--- drivers/iio/industrialio-core.c | 35 +++++++++-------------------------- drivers/iio/industrialio-trigger.c | 6 +++--- include/linux/iio/iio.h | 31 +++++++++++++++++++++++++++++-- 3 files changed, 41 insertions(+), 31 deletions(-)drivers/iio/industrialio-core.c +9
-26@@ -1665,14 +1665,11 @@ static int iio_check_unique_scan_index(struct iio_dev *indio_dev)static const struct iio_buffer_setup_ops noop_ring_setup_ops; -/** -* iio_device_register() - register a device with the IIO subsystem -* @indio_dev: Device structure filled by the device driver -**/ -int iio_device_register (struct iio_dev *indio_dev) +int __iio_device_register (struct iio_dev *indio_dev,struct module *this_mod) {int ret; + indio_dev->driver_module = this_mod;/* If the calling driver did not initialize of_node, do it here */ if (!indio_dev->dev.of_node && indio_dev->dev.parent) indio_dev->dev.of_node = indio_dev->dev.parent->of_node;@@ -1718,7 +1715,8 @@ int iio_device_register(struct iio_dev *indio_dev) indio_dev->setup_ops = &noop_ring_setup_ops;cdev_init (&indio_dev->chrdev, &iio_buffer_fileops); - indio_dev->chrdev.owner = indio_dev->info->driver_module; + + indio_dev->chrdev.owner = this_mod; ret =cdev_device_add (&indio_dev->chrdev, &indio_dev->dev);if (ret <0 )@@ -1736,7 +1734,7 @@ int iio_device_register(struct iio_dev *indio_dev)iio_device_unregister_debugfs (indio_dev);return ret; } -EXPORT_SYMBOL (iio_device_register); +EXPORT_SYMBOL (__iio_device_register);/** * iio_device_unregister() - unregister a device from the IIO subsystem @@ -1768,23 +1766,8 @@ static void devm_iio_device_unreg(struct device *dev, void *res)iio_device_unregister (*(struct iio_dev **)res); } -/** -* devm_iio_device_register - Resource-managed iio_device_register() -* @dev: Device to allocate iio_dev for -* @indio_dev: Device structure filled by the device driver -* -* Managed iio_device_register. The IIO device registered with this -* function is automatically unregistered on driver detach. This function -* calls iio_device_register() internally. Refer to that function for more -* information. -* -* If an iio_dev registered with this function needs to be unregistered -* separately, devm_iio_device_unregister() must be used. -* -* RETURNS: -* 0 on success, negative error number on failure. -*/ -int devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev) +int __devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev, +struct module *this_mod) {struct iio_dev **ptr;int ret;@@ -1794,7 +1777,7 @@ int devm_iio_device_register(struct device *dev, struct iio_dev *indio_dev)return -ENOMEM ; *ptr = indio_dev; - ret =iio_device_register (indio_dev); + ret =__iio_device_register (indio_dev, this_mod);if (!ret)devres_add (dev, ptr);else @@ -1802,7 +1785,7 @@ int devm_iio_device_register(struct device *dev, struct iio_dev *indio_dev)return ret; } -EXPORT_SYMBOL_GPL (devm_iio_device_register); +EXPORT_SYMBOL_GPL (__devm_iio_device_register);/** * devm_iio_device_unregister - Resource-managed iio_device_unregister() drivers/iio/industrialio-trigger.c +3
-3@@ -250,7 +250,7 @@ static int iio_trigger_attach_poll_func(struct iio_trigger *trig, = bitmap_empty(trig->pool, CONFIG_IIO_CONSUMERS_PER_TRIGGER);/* Prevent the module from being removed whilst attached to a trigger */ -__module_get (pf->indio_dev->info->driver_module); +__module_get (pf->indio_dev->driver_module);/* Get irq number */ pf->irq =iio_trigger_get_irq (trig);@@ -286,7 +286,7 @@ static int iio_trigger_attach_poll_func(struct iio_trigger *trig, out_put_irq:iio_trigger_put_irq (trig, pf->irq); out_put_module: -module_put (pf->indio_dev->info->driver_module); +module_put (pf->indio_dev->driver_module);return ret; }@@ -307,7 +307,7 @@ static int iio_trigger_detach_poll_func(struct iio_trigger *trig, trig->attached_own_device = false;iio_trigger_put_irq (trig, pf->irq);free_irq (pf->irq, pf); -module_put (pf->indio_dev->info->driver_module); +module_put (pf->indio_dev->driver_module);return ret; }include/linux/iio/iio.h +29
-2@@ -512,6 +512,7 @@ struct iio_buffer_setup_ops {/** * struct iio_dev - industrial I/O device * @id: [INTERN] used to identify device internally +* @driver_module: [INTERN] used to make it harder to undercut users * @modes: [DRIVER] operating modes supported by device * @currentmode: [DRIVER] current operating mode * @dev: [DRIVER] device structure, should be assigned a parent @@ -552,6 +553,7 @@ struct iio_buffer_setup_ops {*/ struct iio_dev {int id; +struct module *driver_module;int modes;int currentmode;@@ -598,9 +600,34 @@ struct iio_dev {const struct iio_chan_spec *iio_find_channel_from_si (struct iio_dev *indio_dev,int si); -int iio_device_register (struct iio_dev *indio_dev); +/** +* iio_device_register() - register a device with the IIO subsystem +* @indio_dev: Device structure filled by the device driver +**/ +#define iio_device_register (iio_dev) \ + __iio_device_register(iio_dev, THIS_MODULE) +int __iio_device_register (struct iio_dev *indio_dev,struct module *this_mod);void iio_device_unregister (struct iio_dev *indio_dev); -int devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev); +/** +* devm_iio_device_register - Resource-managed iio_device_register() +* @dev: Device to allocate iio_dev for +* @indio_dev: Device structure filled by the device driver +* +* Managed iio_device_register. The IIO device registered with this +* function is automatically unregistered on driver detach. This function +* calls iio_device_register() internally. Refer to that function for more +* information. +* +* If an iio_dev registered with this function needs to be unregistered +* separately, devm_iio_device_unregister() must be used. +* +* RETURNS: +* 0 on success, negative error number on failure. +*/ +#define devm_iio_device_register (dev, indio_dev) \ + __devm_iio_device_register(dev, indio_dev, THIS_MODULE); +int __devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev, +struct module *this_mod);void devm_iio_device_unregister (struct device *dev,struct iio_dev *indio_dev);int iio_push_event (struct iio_dev *indio_dev,u64 ev_code,s64 timestamp);int iio_device_claim_direct_mode (struct iio_dev *indio_dev);
Re: [PATCH 01/38] iio: Use macro magic to avoid manual assign of driver_module
In reply to Jonathan CameronQuoted 4 lines · Jonathan Cameron
Starting point in boiler plate reduction similar to that done for many similar cases elsewhere in the kernel.
Signed-off-by Jonathan Cameron <[email protected]>
Sorry for the long delay.
Whole patch series looks sensible.
Although I personally believe we shouldn't grab the owner module at all, but that is a separate issue.
One small bit inline.
- Lars
include/linux/iio/iio.h struct iio_dev { · line 608
Quoted 11 lines
include/linux/iio/iio.h +6
-1@@ -598,9 +600,34 @@ struct iio_dev {const struct iio_chan_spec *iio_find_channel_from_si (struct iio_dev *indio_dev,int si); -int iio_device_register (struct iio_dev *indio_dev); +/** +* iio_device_register() - register a device with the IIO subsystem +* @indio_dev: Device structure filled by the device driver +**/ +#define iio_device_register (iio_dev) \ + __iio_device_register(iio_dev, THIS_MODULE)
There should be parentheses around iio_dev.
Quoted 11 lines
include/linux/iio/iio.h +9
-1+int __iio_device_register (struct iio_dev *indio_dev,struct module *this_mod);void iio_device_unregister (struct iio_dev *indio_dev); -int devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev); +/** +* devm_iio_device_register - Resource-managed iio_device_register() +* @dev: Device to allocate iio_dev for +* @indio_dev: Device structure filled by the device driver +* +* Managed iio_device_register. The IIO device registered with this +* function is automatically unregistered on driver detach. This function +* calls iio_device_register() internally. Refer to that function for more
include/linux/iio/iio.h struct iio_dev { · line 628
Quoted 10 lines
include/linux/iio/iio.h +10
-0+* information. +* +* If an iio_dev registered with this function needs to be unregistered +* separately, devm_iio_device_unregister() must be used. +* +* RETURNS: +* 0 on success, negative error number on failure. +*/ +#define devm_iio_device_register (dev, indio_dev) \ + __devm_iio_device_register(dev, indio_dev, THIS_MODULE);
Same here
Quoted 6 lines
include/linux/iio/iio.h +2
-0+int __devm_iio_device_register (struct device *dev,struct iio_dev *indio_dev, +struct module *this_mod);void devm_iio_device_unregister (struct device *dev,struct iio_dev *indio_dev);int iio_push_event (struct iio_dev *indio_dev,u64 ev_code,s64 timestamp);int iio_device_claim_direct_mode (struct iio_dev *indio_dev);
Jonathan Cameron
maintainerPATCH 2/38 iio: triggers: Use macros to avoid boilerplate assignment of owner.
In reply to Jonathan CameronThis trig_ops.owner assignment occurs in all trigger drivers and can be simply automated using a macro as has been done in many other places in the kernel.
--- drivers/iio/industrialio-trigger.c | 18 ++++++++++++------ include/linux/iio/trigger.h | 19 +++++++++++++------ 2 files changed, 25 insertions(+), 12 deletions(-)
drivers/iio/industrialio-trigger.c +12 -6
@@ -66,10 +66,13 @@ ATTRIBUTE_GROUPS(iio_trig_dev);static struct iio_trigger *__iio_trigger_find_by_name (const char *name); -int iio_trigger_register (struct iio_trigger *trig_info) +int __iio_trigger_register (struct iio_trigger *trig_info, +struct module *this_mod) {int ret; + trig_info->owner = this_mod; +/* trig_info->ops is required for the module member */ if (!trig_info->ops)return -EINVAL ;
@@ -105,7 +108,7 @@ int iio_trigger_register(struct iio_trigger *trig_info)ida_simple_remove (&iio_trigger_ida, trig_info->id);return ret; } -EXPORT_SYMBOL (iio_trigger_register); +EXPORT_SYMBOL (__iio_trigger_register);void iio_trigger_unregister (struct iio_trigger *trig_info) {
@@ -662,9 +665,10 @@ static void devm_iio_trigger_unreg(struct device *dev, void *res) }/** -* devm_iio_trigger_register - Resource-managed iio_trigger_register() +* __devm_iio_trigger_register - Resource-managed iio_trigger_register() * @dev: device this trigger was allocated for * @trig_info: trigger to register +* @this_mod: module registering the trigger * * Managed iio_trigger_register(). The IIO trigger registered with this * function is automatically unregistered on driver detach. This function
@@ -677,7 +681,9 @@ static void devm_iio_trigger_unreg(struct device *dev, void *res)* RETURNS: * 0 on success, negative error number on failure. */ -int devm_iio_trigger_register (struct device *dev,struct iio_trigger *trig_info) +int __devm_iio_trigger_register (struct device *dev, +struct iio_trigger *trig_info, +struct module *this_mod) {struct iio_trigger **ptr;int ret;
@@ -687,7 +693,7 @@ int devm_iio_trigger_register(struct device *dev, struct iio_trigger *trig_info)return -ENOMEM ; *ptr = trig_info; - ret =iio_trigger_register (trig_info); + ret =__iio_trigger_register (trig_info, this_mod);if (!ret)devres_add (dev, ptr);else
@@ -695,7 +701,7 @@ int devm_iio_trigger_register(struct device *dev, struct iio_trigger *trig_info)return ret; } -EXPORT_SYMBOL_GPL (devm_iio_trigger_register); +EXPORT_SYMBOL_GPL (__devm_iio_trigger_register);/** * devm_iio_trigger_unregister - Resource-managed iio_trigger_unregister()
include/linux/iio/trigger.h +13 -6
@@ -62,6 +62,7 @@ struct iio_trigger_ops {**/ struct iio_trigger {const struct iio_trigger_ops *ops; +struct module *owner;int id;const char *name;struct device dev;
@@ -87,14 +88,14 @@ static inline struct iio_trigger *to_iio_trigger(struct device *d)static inline void iio_trigger_put (struct iio_trigger *trig) { -module_put (trig->ops->owner); +module_put (trig->owner);put_device (&trig->dev); }static inline struct iio_trigger *iio_trigger_get (struct iio_trigger *trig) {get_device (&trig->dev); -__module_get (trig->ops->owner); +__module_get (trig->owner);return trig; }
@@ -127,10 +128,16 @@ static inline void *iio_trigger_get_drvdata(struct iio_trigger *trig)* iio_trigger_register() - register a trigger with the IIO core * @trig_info: trigger to be registered **/ -int iio_trigger_register (struct iio_trigger *trig_info); - -int devm_iio_trigger_register (struct device *dev, -struct iio_trigger *trig_info); +#define iio_trigger_register (trig_info) \ + __iio_trigger_register(trig_info, THIS_MODULE) +int __iio_trigger_register (struct iio_trigger *trig_info, +struct module *this_mod); + +#define devm_iio_trigger_register (dev, trig_info) \ + __devm_iio_trigger_register(dev, trig_info, THIS_MODULE) +int __devm_iio_trigger_register (struct device *dev, +struct iio_trigger *trig_info, +struct module *this_mod);/** * iio_trigger_unregister() - unregister a trigger from the core
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 3/38 coccinelle: Add an iio_no_owner semantic patch to drop driver_owner
In reply to Jonathan CameronAfter some macro magic has made the core code assign this appropriately the field isn't used. This patch automates the removal of the relevant assignments.
Will be removed again once all instances have been dealt with and the field is finally removed.
--- scripts/coccinelle/api/iio_no_owner.cocci | 94 +++++++++++++++++++++++++++++++ 1 file changed, 94 insertions(+)
scripts/coccinelle/api/iio_no_owner.cocci new file +94 -0
@@ -0,0 +1,94 @@ +/// Remove .owner field if calls are used which set it automatically +/// +// Confidence: High +// Copyright : (C) 2017 Jonathan Cmeron. GPLv2. +// Loosely based on platform_no_drv_owner.smpl +// Copyright: (C) 2014 Wolfram Sang. GPL v2. + +virtual patch +virtual context +virtual org +virtual report + +@match1@ +identifier I; +expression E; +@@ +static struct iio_info I = { + .driver_module = E, +}; + +@fix1 depends on match1 && patch && !context && !org && !report@ +identifier match1.I; +@@ +static struct iio_info I = { +- .driver_module = THIS_MODULE, +}; + +@match2@ +identifier O; +expression E; +@@ +static struct iio_trigger_ops O = { + .owner = E, +}; + +@fix2 depends on match2 && patch && !context && !org && !report@ +identifier match2.O; +@@ +static struct iio_trigger_ops O = { +- .owner = THIS_MODULE, +}; + +// ---------------------------------------------------------------------------- + +@fix1_context depends on match1 && !patch && (context || org || report)@ +identifier match1.I; +position j0; +@@ + + static struct iio_info I = { +* .driver_module@j0 = THIS_MODULE, + }; + +@fix2_context depends on match2 && !patch && (context || org || report)@ +identifier match2.O; +position j0; +@@ + + static struct iio_trigger_ops O = { +* .owner@j0 = THIS_MODULE, + }; + + +// ---------------------------------------------------------------------------- + +@script:python fix1_org depends on org@ +j0 << fix1_context.j0; +@@ + +msg = "Setting .driver_module here is deprecated and soon to be removed." +coccilib.org.print_todo(j0[0], msg) + +@script:python fix2_org depends on org@ +j0 << fix2_context.j0; +@@ + +msg = "Setting .owner here is deprecated and soon to be removed." +coccilib.org.print_todo(j0[0], msg) + +// ---------------------------------------------------------------------------- + +@script:python fix1_report depends on report@ +j0 << fix1_context.j0; +@@ + +msg = "Setting .driver_module here is deprecated and soon to be removed." +coccilib.report.print_report(j0[0], msg) + +@script:python fix2_report depends on report@ +j0 << fix2_context.j0; +@@ + +msg = "Setting .owner here is deprecated and soon to be removed." +coccilib.report.print_report(j0[0], msg)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 4/38 iio:adc: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/adc/ad7266.c | 1 - drivers/iio/adc/ad7291.c | 1 - drivers/iio/adc/ad7298.c | 1 - drivers/iio/adc/ad7476.c | 1 - drivers/iio/adc/ad7766.c | 2 -- drivers/iio/adc/ad7791.c | 2 -- drivers/iio/adc/ad7793.c | 2 -- drivers/iio/adc/ad7887.c | 1 - drivers/iio/adc/ad7923.c | 1 - drivers/iio/adc/ad799x.c | 3 --- drivers/iio/adc/ad_sigma_delta.c | 1 - drivers/iio/adc/aspeed_adc.c | 1 - drivers/iio/adc/at91-sama5d2_adc.c | 1 - drivers/iio/adc/at91_adc.c | 2 -- drivers/iio/adc/axp288_adc.c | 1 - drivers/iio/adc/bcm_iproc_adc.c | 1 - drivers/iio/adc/berlin2-adc.c | 1 - drivers/iio/adc/cc10001_adc.c | 1 - drivers/iio/adc/cpcap-adc.c | 1 - drivers/iio/adc/da9150-gpadc.c | 1 - drivers/iio/adc/envelope-detector.c | 1 - drivers/iio/adc/exynos_adc.c | 1 - drivers/iio/adc/hi8435.c | 1 - drivers/iio/adc/hx711.c | 1 - drivers/iio/adc/imx7d_adc.c | 1 - drivers/iio/adc/ina2xx-adc.c | 1 - drivers/iio/adc/lp8788_adc.c | 1 - drivers/iio/adc/lpc18xx_adc.c | 1 - drivers/iio/adc/lpc32xx_adc.c | 1 - drivers/iio/adc/ltc2485.c | 1 - drivers/iio/adc/ltc2497.c | 1 - drivers/iio/adc/max1027.c | 2 -- drivers/iio/adc/max11100.c | 1 - drivers/iio/adc/max1118.c | 1 - drivers/iio/adc/max1363.c | 2 -- drivers/iio/adc/max9611.c | 1 - drivers/iio/adc/mcp320x.c | 1 - drivers/iio/adc/mcp3422.c | 1 - drivers/iio/adc/men_z188_adc.c | 1 - drivers/iio/adc/meson_saradc.c | 1 - drivers/iio/adc/mt6577_auxadc.c | 1 - drivers/iio/adc/mxs-lradc-adc.c | 2 -- drivers/iio/adc/nau7802.c | 1 - drivers/iio/adc/palmas_gpadc.c | 1 - drivers/iio/adc/qcom-pm8xxx-xoadc.c | 1 - drivers/iio/adc/qcom-spmi-iadc.c | 1 - drivers/iio/adc/qcom-spmi-vadc.c | 1 - drivers/iio/adc/rcar-gyroadc.c | 1 - drivers/iio/adc/rockchip_saradc.c | 1 - drivers/iio/adc/spear_adc.c | 1 - drivers/iio/adc/stm32-adc.c | 1 - drivers/iio/adc/stx104.c | 1 - drivers/iio/adc/sun4i-gpadc-iio.c | 1 - drivers/iio/adc/ti-adc081c.c | 1 - drivers/iio/adc/ti-adc0832.c | 1 - drivers/iio/adc/ti-adc084s021.c | 1 - drivers/iio/adc/ti-adc108s102.c | 1 - drivers/iio/adc/ti-adc12138.c | 1 - drivers/iio/adc/ti-adc128s052.c | 1 - drivers/iio/adc/ti-adc161s626.c | 1 - drivers/iio/adc/ti-ads1015.c | 2 -- drivers/iio/adc/ti-ads7950.c | 1 - drivers/iio/adc/ti-ads8688.c | 1 - drivers/iio/adc/ti-tlc4541.c | 1 - drivers/iio/adc/ti_am335x_adc.c | 1 - drivers/iio/adc/twl4030-madc.c | 1 - drivers/iio/adc/twl6030-gpadc.c | 1 - drivers/iio/adc/vf610_adc.c | 1 - drivers/iio/adc/viperboard_adc.c | 1 - drivers/iio/adc/xilinx-xadc-core.c | 2 -- 70 files changed, 81 deletions(-)
drivers/iio/adc/ad7266.c +0 -1
@@ -280,7 +280,6 @@ static AD7266_DECLARE_DIFF_CHANNELS_FIXED(u, 'u');static const struct iio_info ad7266_info = { .read_raw = &ad7266_read_raw, .update_scan_mode = &ad7266_update_scan_mode, - .driver_module =THIS_MODULE , };static const unsigned long ad7266_available_scan_masks[] = {
drivers/iio/adc/ad7291.c +0 -1
@@ -461,7 +461,6 @@ static const struct iio_info ad7291_info = { .write_event_config = &ad7291_write_event_config, .read_event_value = &ad7291_read_event_value, .write_event_value = &ad7291_write_event_value, - .driver_module = THIS_MODULE, }; static int ad7291_probe(struct i2c_client *client,
drivers/iio/adc/ad7298.c +0 -1
@@ -280,7 +280,6 @@ static int ad7298_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad7298_info = { .read_raw = &ad7298_read_raw, .update_scan_mode = ad7298_update_scan_mode, - .driver_module =THIS_MODULE , };static int ad7298_probe (struct spi_device *spi)
drivers/iio/adc/ad7476.c +0 -1
@@ -195,7 +195,6 @@ static const struct ad7476_chip_info ad7476_chip_info_tbl[] = { };static const struct iio_info ad7476_info = { - .driver_module =THIS_MODULE , .read_raw = &ad7476_read_raw, };
drivers/iio/adc/ad7766.c +0 -2
@@ -187,7 +187,6 @@ static const struct iio_buffer_setup_ops ad7766_buffer_setup_ops = { };static const struct iio_info ad7766_info = { - .driver_module =THIS_MODULE , .read_raw = &ad7766_read_raw, };
@@ -210,7 +209,6 @@ static int ad7766_set_trigger_state(struct iio_trigger *trig, bool enable) }static const struct iio_trigger_ops ad7766_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = ad7766_set_trigger_state, .validate_device = iio_trigger_validate_own_device, };
drivers/iio/adc/ad7791.c +0 -2
@@ -310,13 +310,11 @@ static const struct iio_info ad7791_info = { .read_raw = &ad7791_read_raw, .attrs = &ad7791_attribute_group, .validate_trigger = ad_sd_validate_trigger, - .driver_module = THIS_MODULE, };static const struct iio_info ad7791_no_filter_info = { .read_raw = &ad7791_read_raw, .validate_trigger = ad_sd_validate_trigger, - .driver_module =THIS_MODULE , }; static int ad7791_setup(struct ad7791_state *st,
drivers/iio/adc/ad7793.c +0 -2
@@ -563,7 +563,6 @@ static const struct iio_info ad7793_info = { .write_raw_get_fmt = &ad7793_write_raw_get_fmt, .attrs = &ad7793_attribute_group, .validate_trigger = ad_sd_validate_trigger, - .driver_module = THIS_MODULE, };static const struct iio_info ad7797_info = {
@@ -572,7 +571,6 @@ static const struct iio_info ad7797_info = { .write_raw_get_fmt = &ad7793_write_raw_get_fmt, .attrs = &ad7793_attribute_group, .validate_trigger = ad_sd_validate_trigger, - .driver_module = THIS_MODULE, };#define DECLARE_AD7793_CHANNELS (_name, _b, _sb, _s) \
drivers/iio/adc/ad7887.c +0 -1
@@ -229,7 +229,6 @@ static const struct ad7887_chip_info ad7887_chip_info_tbl[] = {static const struct iio_info ad7887_info = { .read_raw = &ad7887_read_raw, - .driver_module =THIS_MODULE , };static int ad7887_probe (struct spi_device *spi)
drivers/iio/adc/ad7923.c +0 -1
@@ -262,7 +262,6 @@ static int ad7923_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad7923_info = { .read_raw = &ad7923_read_raw, .update_scan_mode = ad7923_update_scan_mode, - .driver_module =THIS_MODULE , };static int ad7923_probe (struct spi_device *spi)
drivers/iio/adc/ad799x.c +0 -3
@@ -526,13 +526,11 @@ static const struct attribute_group ad799x_event_attrs_group = {static const struct iio_info ad7991_info = { .read_raw = &ad799x_read_raw, - .driver_module =THIS_MODULE , .update_scan_mode = ad799x_update_scan_mode, };static const struct iio_info ad7993_4_7_8_noirq_info = { .read_raw = &ad799x_read_raw, - .driver_module =THIS_MODULE , .update_scan_mode = ad799x_update_scan_mode, };
@@ -543,7 +541,6 @@ static const struct iio_info ad7993_4_7_8_irq_info = { .write_event_config = &ad799x_write_event_config, .read_event_value = &ad799x_read_event_value, .write_event_value = &ad799x_write_event_value, - .driver_module = THIS_MODULE, .update_scan_mode = ad799x_update_scan_mode, };
drivers/iio/adc/ad_sigma_delta.c +0 -1
@@ -435,7 +435,6 @@ int ad_sd_validate_trigger(struct iio_dev *indio_dev, struct iio_trigger *trig)EXPORT_SYMBOL_GPL (ad_sd_validate_trigger);static const struct iio_trigger_ops ad_sd_trigger_ops = { - .owner =THIS_MODULE , };static int ad_sd_probe_trigger (struct iio_dev *indio_dev)
drivers/iio/adc/aspeed_adc.c +0 -1
@@ -158,7 +158,6 @@ static int aspeed_adc_reg_access(struct iio_dev *indio_dev, }static const struct iio_info aspeed_adc_iio_info = { - .driver_module =THIS_MODULE , .read_raw = aspeed_adc_read_raw, .write_raw = aspeed_adc_write_raw, .debugfs_reg_access = aspeed_adc_reg_access,
drivers/iio/adc/at91-sama5d2_adc.c +0 -1
@@ -383,7 +383,6 @@ static int at91_adc_write_raw(struct iio_dev *indio_dev,static const struct iio_info at91_adc_info = { .read_raw = &at91_adc_read_raw, .write_raw = &at91_adc_write_raw, - .driver_module =THIS_MODULE , };static int at91_adc_probe (struct platform_device *pdev)
drivers/iio/adc/at91_adc.c +0 -2
@@ -594,7 +594,6 @@ static int at91_adc_configure_trigger(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops at91_adc_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &at91_adc_configure_trigger, };
@@ -976,7 +975,6 @@ static int at91_adc_probe_pdata(struct at91_adc_state *st, }static const struct iio_info at91_adc_info = { - .driver_module =THIS_MODULE , .read_raw = &at91_adc_read_raw, };
drivers/iio/adc/axp288_adc.c +0 -1
@@ -143,7 +143,6 @@ static int axp288_adc_read_raw(struct iio_dev *indio_dev,static const struct iio_info axp288_adc_iio_info = { .read_raw = &axp288_adc_read_raw, - .driver_module =THIS_MODULE , };static int axp288_adc_probe (struct platform_device *pdev)
drivers/iio/adc/bcm_iproc_adc.c +0 -1
@@ -492,7 +492,6 @@ static int iproc_adc_read_raw(struct iio_dev *indio_dev,static const struct iio_info iproc_adc_iio_info = { .read_raw = &iproc_adc_read_raw, - .driver_module =THIS_MODULE , };#define IPROC_ADC_CHANNEL (_index, _id) { \
drivers/iio/adc/berlin2-adc.c +0 -1
@@ -277,7 +277,6 @@ static irqreturn_t berlin2_adc_tsen_irq(int irq, void *private) }static const struct iio_info berlin2_adc_info = { - .driver_module =THIS_MODULE , .read_raw = berlin2_adc_read_raw, };
drivers/iio/adc/cc10001_adc.c +0 -1
@@ -262,7 +262,6 @@ static int cc10001_update_scan_mode(struct iio_dev *indio_dev, }static const struct iio_info cc10001_adc_info = { - .driver_module =THIS_MODULE , .read_raw = &cc10001_adc_read_raw, .update_scan_mode = &cc10001_update_scan_mode, };
drivers/iio/adc/cpcap-adc.c +0 -1
@@ -932,7 +932,6 @@ static int cpcap_adc_read(struct iio_dev *indio_dev,static const struct iio_info cpcap_adc_info = { .read_raw = &cpcap_adc_read, - .driver_module =THIS_MODULE , };/*
drivers/iio/adc/da9150-gpadc.c +0 -1
@@ -249,7 +249,6 @@ static int da9150_gpadc_read_raw(struct iio_dev *indio_dev,static const struct iio_info da9150_gpadc_info = { .read_raw = &da9150_gpadc_read_raw, - .driver_module =THIS_MODULE , }; #define DA9150_GPADC_CHANNEL(_id, _hw_id, _type, chan_info, \
drivers/iio/adc/envelope-detector.c +0 -1
@@ -322,7 +322,6 @@ static const struct iio_chan_spec envelope_detector_iio_channel = {static const struct iio_info envelope_detector_info = { .read_raw = &envelope_detector_read_raw, - .driver_module =THIS_MODULE , };static int envelope_detector_probe (struct platform_device *pdev)
drivers/iio/adc/exynos_adc.c +0 -1
@@ -657,7 +657,6 @@ static int exynos_adc_reg_access(struct iio_dev *indio_dev,static const struct iio_info exynos_adc_iio_info = { .read_raw = &exynos_read_raw, .debugfs_reg_access = &exynos_adc_reg_access, - .driver_module =THIS_MODULE , };#define ADC_CHANNEL (_index, _id) { \
drivers/iio/adc/hi8435.c +0 -1
@@ -408,7 +408,6 @@ static const struct iio_chan_spec hi8435_channels[] = { };static const struct iio_info hi8435_info = { - .driver_module =THIS_MODULE , .read_raw = hi8435_read_raw, .read_event_config = hi8435_read_event_config, .write_event_config = hi8435_write_event_config,
drivers/iio/adc/hx711.c +0 -1
@@ -374,7 +374,6 @@ static const struct attribute_group hx711_attribute_group = { };static const struct iio_info hx711_iio_info = { - .driver_module =THIS_MODULE , .read_raw = hx711_read_raw, .write_raw = hx711_write_raw, .write_raw_get_fmt = hx711_write_raw_get_fmt,
drivers/iio/adc/imx7d_adc.c +0 -1
@@ -412,7 +412,6 @@ static int imx7d_adc_reg_access(struct iio_dev *indio_dev, }static const struct iio_info imx7d_adc_iio_info = { - .driver_module =THIS_MODULE , .read_raw = &imx7d_adc_read_raw, .debugfs_reg_access = &imx7d_adc_reg_access, };
drivers/iio/adc/ina2xx-adc.c +0 -1
@@ -614,7 +614,6 @@ static const struct attribute_group ina2xx_attribute_group = { };static const struct iio_info ina2xx_info = { - .driver_module =THIS_MODULE , .attrs = &ina2xx_attribute_group, .read_raw = ina2xx_read_raw, .write_raw = ina2xx_write_raw,
drivers/iio/adc/lp8788_adc.c +0 -1
@@ -125,7 +125,6 @@ static int lp8788_adc_read_raw(struct iio_dev *indio_dev,static const struct iio_info lp8788_adc_info = { .read_raw = &lp8788_adc_read_raw, - .driver_module =THIS_MODULE , };#define LP8788_CHAN (_id, _type) { \
drivers/iio/adc/lpc18xx_adc.c +0 -1
@@ -116,7 +116,6 @@ static int lpc18xx_adc_read_raw(struct iio_dev *indio_dev,static const struct iio_info lpc18xx_adc_info = { .read_raw = lpc18xx_adc_read_raw, - .driver_module =THIS_MODULE , };static int lpc18xx_adc_probe (struct platform_device *pdev)
drivers/iio/adc/lpc32xx_adc.c +0 -1
@@ -100,7 +100,6 @@ static int lpc32xx_read_raw(struct iio_dev *indio_dev,static const struct iio_info lpc32xx_adc_iio_info = { .read_raw = &lpc32xx_read_raw, - .driver_module =THIS_MODULE , };#define LPC32XX_ADC_CHANNEL (_index) { \
drivers/iio/adc/ltc2485.c +0 -1
@@ -90,7 +90,6 @@ static const struct iio_chan_spec ltc2485_channel[] = {static const struct iio_info ltc2485_info = { .read_raw = ltc2485_read_raw, - .driver_module =THIS_MODULE , }; static int ltc2485_probe(struct i2c_client *client,
drivers/iio/adc/ltc2497.c +0 -1
@@ -184,7 +184,6 @@ static const struct iio_chan_spec ltc2497_channel[] = {static const struct iio_info ltc2497_info = { .read_raw = ltc2497_read_raw, - .driver_module =THIS_MODULE , }; static int ltc2497_probe(struct i2c_client *client,
drivers/iio/adc/max1027.c +0 -2
@@ -381,13 +381,11 @@ static irqreturn_t max1027_trigger_handler(int irq, void *private) }static const struct iio_trigger_ops max1027_trigger_ops = { - .owner =THIS_MODULE , .validate_device = &iio_trigger_validate_own_device, .set_trigger_state = &max1027_set_trigger_state, };static const struct iio_info max1027_info = { - .driver_module =THIS_MODULE , .read_raw = &max1027_read_raw, .validate_trigger = &max1027_validate_trigger, .debugfs_reg_access = &max1027_debugfs_reg_access,
drivers/iio/adc/max11100.c +0 -1
@@ -100,7 +100,6 @@ static int max11100_read_raw(struct iio_dev *indio_dev, }static const struct iio_info max11100_info = { - .driver_module =THIS_MODULE , .read_raw = max11100_read_raw, };
drivers/iio/adc/max1118.c +0 -1
@@ -155,7 +155,6 @@ static int max1118_read_raw(struct iio_dev *indio_dev,static const struct iio_info max1118_info = { .read_raw = max1118_read_raw, - .driver_module =THIS_MODULE , };static irqreturn_t max1118_trigger_handler (int irq,void *p)
drivers/iio/adc/max1363.c +0 -2
@@ -1029,7 +1029,6 @@ static int max1363_update_scan_mode(struct iio_dev *indio_dev,static const struct iio_info max1238_info = { .read_raw = &max1363_read_raw, - .driver_module =THIS_MODULE , .update_scan_mode = &max1363_update_scan_mode, };
@@ -1040,7 +1039,6 @@ static const struct iio_info max1363_info = { .write_event_config = &max1363_write_event_config, .read_raw = &max1363_read_raw, .update_scan_mode = &max1363_update_scan_mode, - .driver_module = THIS_MODULE, .event_attrs = &max1363_event_attribute_group, };
drivers/iio/adc/max9611.c +0 -1
@@ -460,7 +460,6 @@ static const struct attribute_group max9611_attribute_group = { };static const struct iio_info indio_info = { - .driver_module =THIS_MODULE , .read_raw = max9611_read_raw, .attrs = &max9611_attribute_group, };
drivers/iio/adc/mcp320x.c +0 -1
@@ -242,7 +242,6 @@ static const struct iio_chan_spec mcp3208_channels[] = {static const struct iio_info mcp320x_info = { .read_raw = mcp320x_read_raw, - .driver_module =THIS_MODULE , };static const struct mcp320x_chip_info mcp320x_chip_infos[] = {
drivers/iio/adc/mcp3422.c +0 -1
@@ -327,7 +327,6 @@ static const struct iio_info mcp3422_info = { .write_raw = mcp3422_write_raw, .write_raw_get_fmt = mcp3422_write_raw_get_fmt, .attrs = &mcp3422_attribute_group, - .driver_module = THIS_MODULE, }; static int mcp3422_probe(struct i2c_client *client,
drivers/iio/adc/men_z188_adc.c +0 -1
@@ -80,7 +80,6 @@ static int z188_iio_read_raw(struct iio_dev *iio_dev,static const struct iio_info z188_adc_info = { .read_raw = &z188_iio_read_raw, - .driver_module =THIS_MODULE , };static void men_z188_config_channels (void __iomem *addr)
drivers/iio/adc/meson_saradc.c +0 -1
@@ -840,7 +840,6 @@ static int meson_sar_adc_calib(struct iio_dev *indio_dev)static const struct iio_info meson_sar_adc_iio_info = { .read_raw = meson_sar_adc_iio_info_read_raw, - .driver_module =THIS_MODULE , };static const struct meson_sar_adc_data meson_sar_adc_meson8_data = {
drivers/iio/adc/mt6577_auxadc.c +0 -1
@@ -180,7 +180,6 @@ static int mt6577_auxadc_read_raw(struct iio_dev *indio_dev, }static const struct iio_info mt6577_auxadc_info = { - .driver_module =THIS_MODULE , .read_raw = &mt6577_auxadc_read_raw, };
drivers/iio/adc/mxs-lradc-adc.c +0 -2
@@ -382,7 +382,6 @@ static const struct attribute_group mxs_lradc_adc_attribute_group = { };static const struct iio_info mxs_lradc_adc_iio_info = { - .driver_module =THIS_MODULE , .read_raw = mxs_lradc_adc_read_raw, .write_raw = mxs_lradc_adc_write_raw, .write_raw_get_fmt = mxs_lradc_adc_write_raw_get_fmt,
@@ -455,7 +454,6 @@ static int mxs_lradc_adc_configure_trigger(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops mxs_lradc_adc_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &mxs_lradc_adc_configure_trigger, };
drivers/iio/adc/nau7802.c +0 -1
@@ -402,7 +402,6 @@ static int nau7802_write_raw_get_fmt(struct iio_dev *indio_dev, }static const struct iio_info nau7802_info = { - .driver_module =THIS_MODULE , .read_raw = &nau7802_read_raw, .write_raw = &nau7802_write_raw, .write_raw_get_fmt = nau7802_write_raw_get_fmt,
drivers/iio/adc/palmas_gpadc.c +0 -1
@@ -430,7 +430,6 @@ static int palmas_gpadc_read_raw(struct iio_dev *indio_dev,static const struct iio_info palmas_gpadc_iio_info = { .read_raw = palmas_gpadc_read_raw, - .driver_module =THIS_MODULE , };#define PALMAS_ADC_CHAN_IIO (chan, _type, chan_info) \
drivers/iio/adc/qcom-pm8xxx-xoadc.c +0 -1
@@ -728,7 +728,6 @@ static int pm8xxx_of_xlate(struct iio_dev *indio_dev, }static const struct iio_info pm8xxx_xoadc_info = { - .driver_module =THIS_MODULE , .of_xlate = pm8xxx_of_xlate, .read_raw = pm8xxx_read_raw, };
drivers/iio/adc/qcom-spmi-iadc.c +0 -1
@@ -356,7 +356,6 @@ static int iadc_read_raw(struct iio_dev *indio_dev,static const struct iio_info iadc_info = { .read_raw = iadc_read_raw, - .driver_module =THIS_MODULE , };static irqreturn_t iadc_isr (int irq,void *dev_id)
drivers/iio/adc/qcom-spmi-vadc.c +0 -1
@@ -506,7 +506,6 @@ static int vadc_of_xlate(struct iio_dev *indio_dev,static const struct iio_info vadc_info = { .read_raw = vadc_read_raw, .of_xlate = vadc_of_xlate, - .driver_module =THIS_MODULE , };struct vadc_channels {
drivers/iio/adc/rcar-gyroadc.c +0 -1
@@ -277,7 +277,6 @@ static int rcar_gyroadc_reg_access(struct iio_dev *indio_dev, }static const struct iio_info rcar_gyroadc_iio_info = { - .driver_module =THIS_MODULE , .read_raw = rcar_gyroadc_read_raw, .debugfs_reg_access = rcar_gyroadc_reg_access, };
drivers/iio/adc/rockchip_saradc.c +0 -1
@@ -125,7 +125,6 @@ static irqreturn_t rockchip_saradc_isr(int irq, void *dev_id)static const struct iio_info rockchip_saradc_iio_info = { .read_raw = rockchip_saradc_read_raw, - .driver_module =THIS_MODULE , };#define ADC_CHANNEL (_index, _id) { \
drivers/iio/adc/spear_adc.c +0 -1
@@ -254,7 +254,6 @@ static int spear_adc_configure(struct spear_adc_state *st)static const struct iio_info spear_adc_info = { .read_raw = &spear_adc_read_raw, .write_raw = &spear_adc_write_raw, - .driver_module =THIS_MODULE , };static int spear_adc_probe (struct platform_device *pdev)
drivers/iio/adc/stm32-adc.c +0 -1
@@ -699,7 +699,6 @@ static const struct iio_info stm32_adc_iio_info = { .update_scan_mode = stm32_adc_update_scan_mode, .debugfs_reg_access = stm32_adc_debugfs_reg_access, .of_xlate = stm32_adc_of_xlate, - .driver_module = THIS_MODULE, };static unsigned int stm32_adc_dma_residue (struct stm32_adc *adc)
drivers/iio/adc/stx104.c +0 -1
@@ -172,7 +172,6 @@ static int stx104_write_raw(struct iio_dev *indio_dev, }static const struct iio_info stx104_info = { - .driver_module =THIS_MODULE , .read_raw = stx104_read_raw, .write_raw = stx104_write_raw };
drivers/iio/adc/sun4i-gpadc-iio.c +0 -1
@@ -349,7 +349,6 @@ static int sun4i_gpadc_read_raw(struct iio_dev *indio_dev,static const struct iio_info sun4i_gpadc_iio_info = { .read_raw = sun4i_gpadc_read_raw, - .driver_module =THIS_MODULE , };static irqreturn_t sun4i_gpadc_temp_data_irq_handler (int irq,void *dev_id)
drivers/iio/adc/ti-adc081c.c +0 -1
@@ -124,7 +124,6 @@ static struct adcxx1c_model adcxx1c_models[] = {static const struct iio_info adc081c_info = { .read_raw = adc081c_read_raw, - .driver_module =THIS_MODULE , };static irqreturn_t adc081c_trigger_handler (int irq,void *p)
drivers/iio/adc/ti-adc0832.c +0 -1
@@ -195,7 +195,6 @@ static int adc0832_read_raw(struct iio_dev *iio,static const struct iio_info adc0832_info = { .read_raw = adc0832_read_raw, - .driver_module =THIS_MODULE , };static irqreturn_t adc0832_trigger_handler (int irq,void *p)
drivers/iio/adc/ti-adc084s021.c +0 -1
@@ -186,7 +186,6 @@ static int adc084s021_buffer_postdisable(struct iio_dev *indio_dev)static const struct iio_info adc084s021_info = { .read_raw = adc084s021_read_raw, - .driver_module =THIS_MODULE , };static const struct iio_buffer_setup_ops adc084s021_buffer_setup_ops = {
drivers/iio/adc/ti-adc108s102.c +0 -1
@@ -220,7 +220,6 @@ static int adc108s102_read_raw(struct iio_dev *indio_dev,static const struct iio_info adc108s102_info = { .read_raw = &adc108s102_read_raw, .update_scan_mode = &adc108s102_update_scan_mode, - .driver_module =THIS_MODULE , };static int adc108s102_probe (struct spi_device *spi)
drivers/iio/adc/ti-adc12138.c +0 -1
@@ -277,7 +277,6 @@ static int adc12138_read_raw(struct iio_dev *iio,static const struct iio_info adc12138_info = { .read_raw = adc12138_read_raw, - .driver_module =THIS_MODULE , };static int adc12138_init (struct adc12138 *adc)
drivers/iio/adc/ti-adc128s052.c +0 -1
@@ -130,7 +130,6 @@ static const struct adc128_configuration adc128_config[] = {static const struct iio_info adc128_info = { .read_raw = adc128_read_raw, - .driver_module =THIS_MODULE , };static int adc128_probe (struct spi_device *spi)
drivers/iio/adc/ti-adc161s626.c +0 -1
@@ -173,7 +173,6 @@ static int ti_adc_read_raw(struct iio_dev *indio_dev, }static const struct iio_info ti_adc_info = { - .driver_module =THIS_MODULE , .read_raw = ti_adc_read_raw, };
drivers/iio/adc/ti-ads1015.c +0 -2
@@ -474,14 +474,12 @@ static const struct attribute_group ads1115_attribute_group = { };static const struct iio_info ads1015_info = { - .driver_module =THIS_MODULE , .read_raw = ads1015_read_raw, .write_raw = ads1015_write_raw, .attrs = &ads1015_attribute_group, };static const struct iio_info ads1115_info = { - .driver_module =THIS_MODULE , .read_raw = ads1015_read_raw, .write_raw = ads1015_write_raw, .attrs = &ads1115_attribute_group,
drivers/iio/adc/ti-ads7950.c +0 -1
@@ -360,7 +360,6 @@ static int ti_ads7950_read_raw(struct iio_dev *indio_dev,static const struct iio_info ti_ads7950_info = { .read_raw = &ti_ads7950_read_raw, .update_scan_mode = ti_ads7950_update_scan_mode, - .driver_module =THIS_MODULE , };static int ti_ads7950_probe (struct spi_device *spi)
drivers/iio/adc/ti-ads8688.c +0 -1
@@ -369,7 +369,6 @@ static const struct iio_info ads8688_info = { .write_raw = &ads8688_write_raw, .write_raw_get_fmt = &ads8688_write_raw_get_fmt, .attrs = &ads8688_attribute_group, - .driver_module = THIS_MODULE, };static const struct ads8688_chip_info ads8688_chip_info_tbl[] = {
drivers/iio/adc/ti-tlc4541.c +0 -1
@@ -157,7 +157,6 @@ static int tlc4541_read_raw(struct iio_dev *indio_dev,static const struct iio_info tlc4541_info = { .read_raw = &tlc4541_read_raw, - .driver_module =THIS_MODULE , };static int tlc4541_probe (struct spi_device *spi)
drivers/iio/adc/ti_am335x_adc.c +0 -1
@@ -533,7 +533,6 @@ static int tiadc_read_raw(struct iio_dev *indio_dev,static const struct iio_info tiadc_info = { .read_raw = &tiadc_read_raw, - .driver_module =THIS_MODULE , }; static int tiadc_request_dma(struct platform_device *pdev,
drivers/iio/adc/twl4030-madc.c +0 -1
@@ -100,7 +100,6 @@ static int twl4030_madc_read(struct iio_dev *iio_dev,static const struct iio_info twl4030_madc_iio_info = { .read_raw = &twl4030_madc_read, - .driver_module =THIS_MODULE , };#define TWL4030_ADC_CHANNEL (_channel, _type, _name) { \
drivers/iio/adc/twl6030-gpadc.c +0 -1
@@ -843,7 +843,6 @@ static const struct iio_chan_spec twl6032_gpadc_iio_channels[] = {static const struct iio_info twl6030_gpadc_iio_info = { .read_raw = &twl6030_gpadc_read_raw, - .driver_module =THIS_MODULE , };static const struct twl6030_gpadc_platform_data twl6030_pdata = {
drivers/iio/adc/vf610_adc.c +0 -1
@@ -799,7 +799,6 @@ static int vf610_adc_reg_access(struct iio_dev *indio_dev, }static const struct iio_info vf610_adc_iio_info = { - .driver_module =THIS_MODULE , .read_raw = &vf610_read_raw, .write_raw = &vf610_write_raw, .debugfs_reg_access = &vf610_adc_reg_access,
drivers/iio/adc/viperboard_adc.c +0 -1
@@ -107,7 +107,6 @@ static int vprbrd_iio_read_raw(struct iio_dev *iio_dev,static const struct iio_info vprbrd_adc_iio_info = { .read_raw = &vprbrd_iio_read_raw, - .driver_module =THIS_MODULE , };static int vprbrd_adc_probe (struct platform_device *pdev)
drivers/iio/adc/xilinx-xadc-core.c +0 -2
@@ -675,7 +675,6 @@ static int xadc_trigger_set_state(struct iio_trigger *trigger, bool state) }static const struct iio_trigger_ops xadc_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &xadc_trigger_set_state, };
@@ -1028,7 +1027,6 @@ static const struct iio_info xadc_info = { .read_event_value = &xadc_read_event_value, .write_event_value = &xadc_write_event_value, .update_scan_mode = &xadc_update_scan_mode, - .driver_module = THIS_MODULE, };static const struct of_device_id xadc_of_match_table[] = {
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 5/38 iio:accel: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/accel/adxl345_core.c | 1 - drivers/iio/accel/bma180.c | 2 -- drivers/iio/accel/bma220_spi.c | 1 - drivers/iio/accel/bmc150-accel-core.c | 3 --- drivers/iio/accel/da280.c | 1 - drivers/iio/accel/da311.c | 1 - drivers/iio/accel/dmard06.c | 1 - drivers/iio/accel/dmard09.c | 1 - drivers/iio/accel/dmard10.c | 1 - drivers/iio/accel/hid-sensor-accel-3d.c | 1 - drivers/iio/accel/kxcjk-1013.c | 2 -- drivers/iio/accel/kxsd9.c | 1 - drivers/iio/accel/mc3230.c | 1 - drivers/iio/accel/mma7455_core.c | 1 - drivers/iio/accel/mma7660.c | 1 - drivers/iio/accel/mma8452.c | 2 -- drivers/iio/accel/mma9551.c | 1 - drivers/iio/accel/mma9553.c | 1 - drivers/iio/accel/mxc4005.c | 2 -- drivers/iio/accel/mxc6255.c | 1 - drivers/iio/accel/sca3000.c | 1 - drivers/iio/accel/st_accel_core.c | 2 -- drivers/iio/accel/stk8312.c | 2 -- drivers/iio/accel/stk8ba50.c | 2 -- 24 files changed, 33 deletions(-)
drivers/iio/accel/adxl345_core.c +0 -1
@@ -95,7 +95,6 @@ static int adxl345_read_raw(struct iio_dev *indio_dev, }static const struct iio_info adxl345_info = { - .driver_module =THIS_MODULE , .read_raw = adxl345_read_raw, };
drivers/iio/accel/bma180.c +0 -2
@@ -541,7 +541,6 @@ static const struct iio_info bma180_info = { .attrs = &bma180_attrs_group, .read_raw = bma180_read_raw, .write_raw = bma180_write_raw, - .driver_module = THIS_MODULE, };static const char *const bma180_power_modes[] = {"low_noise" ,"low_power" };
@@ -722,7 +721,6 @@ static int bma180_trig_try_reen(struct iio_trigger *trig)static const struct iio_trigger_ops bma180_trigger_ops = { .set_trigger_state = bma180_data_rdy_trigger_set_state, .try_reenable = bma180_trig_try_reen, - .owner =THIS_MODULE , }; static int bma180_probe(struct i2c_client *client,
drivers/iio/accel/bma220_spi.c +0 -1
@@ -186,7 +186,6 @@ static int bma220_write_raw(struct iio_dev *indio_dev, }static const struct iio_info bma220_info = { - .driver_module =THIS_MODULE , .read_raw = bma220_read_raw, .write_raw = bma220_write_raw, .attrs = &bma220_attribute_group,
drivers/iio/accel/bmc150-accel-core.c +0 -3
@@ -1100,7 +1100,6 @@ static const struct iio_info bmc150_accel_info = { .write_event_value = bmc150_accel_write_event, .write_event_config = bmc150_accel_write_event_config, .read_event_config = bmc150_accel_read_event_config, - .driver_module = THIS_MODULE, };static const struct iio_info bmc150_accel_info_fifo = {
@@ -1114,7 +1113,6 @@ static const struct iio_info bmc150_accel_info_fifo = { .validate_trigger = bmc150_accel_validate_trigger, .hwfifo_set_watermark = bmc150_accel_set_watermark, .hwfifo_flush_to_buffer = bmc150_accel_fifo_flush, - .driver_module = THIS_MODULE, };static const unsigned long bmc150_accel_scan_masks[] = {
@@ -1206,7 +1204,6 @@ static int bmc150_accel_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops bmc150_accel_trigger_ops = { .set_trigger_state = bmc150_accel_trigger_set_state, .try_reenable = bmc150_accel_trig_try_reen, - .owner =THIS_MODULE , };static int bmc150_accel_handle_roc_event (struct iio_dev *indio_dev)
drivers/iio/accel/da280.c +0 -1
@@ -88,7 +88,6 @@ static int da280_read_raw(struct iio_dev *indio_dev, }static const struct iio_info da280_info = { - .driver_module =THIS_MODULE , .read_raw = da280_read_raw, };
drivers/iio/accel/da311.c +0 -1
@@ -212,7 +212,6 @@ static int da311_read_raw(struct iio_dev *indio_dev, }static const struct iio_info da311_info = { - .driver_module =THIS_MODULE , .read_raw = da311_read_raw, };
drivers/iio/accel/dmard06.c +0 -1
@@ -124,7 +124,6 @@ static int dmard06_read_raw(struct iio_dev *indio_dev, }static const struct iio_info dmard06_info = { - .driver_module =THIS_MODULE , .read_raw = dmard06_read_raw, };
drivers/iio/accel/dmard09.c +0 -1
@@ -93,7 +93,6 @@ static int dmard09_read_raw(struct iio_dev *indio_dev, }static const struct iio_info dmard09_info = { - .driver_module =THIS_MODULE , .read_raw = dmard09_read_raw, };
drivers/iio/accel/dmard10.c +0 -1
@@ -170,7 +170,6 @@ static int dmard10_read_raw(struct iio_dev *indio_dev, }static const struct iio_info dmard10_info = { - .driver_module =THIS_MODULE , .read_raw = dmard10_read_raw, };
drivers/iio/accel/hid-sensor-accel-3d.c +0 -1
@@ -225,7 +225,6 @@ static int accel_3d_write_raw(struct iio_dev *indio_dev, }static const struct iio_info accel_3d_info = { - .driver_module =THIS_MODULE , .read_raw = &accel_3d_read_raw, .write_raw = &accel_3d_write_raw, };
drivers/iio/accel/kxcjk-1013.c +0 -2
@@ -950,7 +950,6 @@ static const struct iio_info kxcjk1013_info = { .write_event_value = kxcjk1013_write_event, .write_event_config = kxcjk1013_write_event_config, .read_event_config = kxcjk1013_read_event_config, - .driver_module = THIS_MODULE, };static const unsigned long kxcjk1013_scan_masks[] = {0x7 ,0 };
@@ -1036,7 +1035,6 @@ static int kxcjk1013_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops kxcjk1013_trigger_ops = { .set_trigger_state = kxcjk1013_data_rdy_trigger_set_state, .try_reenable = kxcjk1013_trig_try_reen, - .owner =THIS_MODULE , };static irqreturn_t kxcjk1013_event_handler (int irq,void *private)
drivers/iio/accel/kxsd9.c +0 -1
@@ -390,7 +390,6 @@ static const struct iio_info kxsd9_info = { .read_raw = &kxsd9_read_raw, .write_raw = &kxsd9_write_raw, .attrs = &kxsd9_attribute_group, - .driver_module = THIS_MODULE, };/* Four channels apart from timestamp, scan mask = 0x0f */
drivers/iio/accel/mc3230.c +0 -1
@@ -107,7 +107,6 @@ static int mc3230_read_raw(struct iio_dev *indio_dev, }static const struct iio_info mc3230_info = { - .driver_module =THIS_MODULE , .read_raw = mc3230_read_raw, };
drivers/iio/accel/mma7455_core.c +0 -1
@@ -199,7 +199,6 @@ static const struct iio_info mma7455_info = { .attrs = &mma7455_group, .read_raw = mma7455_read_raw, .write_raw = mma7455_write_raw, - .driver_module = THIS_MODULE, };#define MMA7455_CHANNEL (axis, idx) { \
drivers/iio/accel/mma7660.c +0 -1
@@ -168,7 +168,6 @@ static int mma7660_read_raw(struct iio_dev *indio_dev, }static const struct iio_info mma7660_info = { - .driver_module =THIS_MODULE , .read_raw = mma7660_read_raw, .attrs = &mma7660_attribute_group, };
drivers/iio/accel/mma8452.c +0 -2
@@ -1337,7 +1337,6 @@ static const struct iio_info mma8452_info = { .read_event_config = &mma8452_read_event_config, .write_event_config = &mma8452_write_event_config, .debugfs_reg_access = &mma8452_reg_access_dbg, - .driver_module = THIS_MODULE, };static const unsigned long mma8452_scan_masks[] = {0x7 ,0 };
@@ -1368,7 +1367,6 @@ static int mma8452_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops mma8452_trigger_ops = { .set_trigger_state = mma8452_data_rdy_trigger_set_state, .validate_device = iio_trigger_validate_own_device, - .owner =THIS_MODULE , };static int mma8452_trigger_setup (struct iio_dev *indio_dev)
drivers/iio/accel/mma9551.c +0 -1
@@ -333,7 +333,6 @@ static const struct iio_chan_spec mma9551_channels[] = { };static const struct iio_info mma9551_info = { - .driver_module =THIS_MODULE , .read_raw = mma9551_read_raw, .read_event_config = mma9551_read_event_config, .write_event_config = mma9551_write_event_config,
drivers/iio/accel/mma9553.c +0 -1
@@ -987,7 +987,6 @@ static const struct iio_chan_spec mma9553_channels[] = { };static const struct iio_info mma9553_info = { - .driver_module =THIS_MODULE , .read_raw = mma9553_read_raw, .write_raw = mma9553_write_raw, .read_event_config = mma9553_read_event_config,
drivers/iio/accel/mxc4005.c +0 -2
@@ -264,7 +264,6 @@ static int mxc4005_write_raw(struct iio_dev *indio_dev, }static const struct iio_info mxc4005_info = { - .driver_module =THIS_MODULE , .read_raw = mxc4005_read_raw, .write_raw = mxc4005_write_raw, .attrs = &mxc4005_attrs_group,
@@ -376,7 +375,6 @@ static int mxc4005_trigger_try_reen(struct iio_trigger *trig)static const struct iio_trigger_ops mxc4005_trigger_ops = { .set_trigger_state = mxc4005_set_trigger_state, .try_reenable = mxc4005_trigger_try_reen, - .owner =THIS_MODULE , };static int mxc4005_chip_init (struct mxc4005_data *data)
drivers/iio/accel/mxc6255.c +0 -1
@@ -78,7 +78,6 @@ static int mxc6255_read_raw(struct iio_dev *indio_dev, }static const struct iio_info mxc6255_info = { - .driver_module =THIS_MODULE , .read_raw = mxc6255_read_raw, };
drivers/iio/accel/sca3000.c +0 -1
@@ -1454,7 +1454,6 @@ static const struct iio_info sca3000_info = { .write_event_value = &sca3000_write_event_value, .read_event_config = &sca3000_read_event_config, .write_event_config = &sca3000_write_event_config, - .driver_module = THIS_MODULE, };static int sca3000_probe (struct spi_device *spi)
drivers/iio/accel/st_accel_core.c +0 -2
@@ -689,7 +689,6 @@ static const struct attribute_group st_accel_attribute_group = { };static const struct iio_info accel_info = { - .driver_module =THIS_MODULE , .attrs = &st_accel_attribute_group, .read_raw = &st_accel_read_raw, .write_raw = &st_accel_write_raw,
@@ -698,7 +697,6 @@ static const struct iio_info accel_info = {#ifdef CONFIG_IIO_TRIGGER static const struct iio_trigger_ops st_accel_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state =ST_ACCEL_TRIGGER_SET_STATE , .validate_device = st_sensors_validate_device, };
drivers/iio/accel/stk8312.c +0 -2
@@ -237,7 +237,6 @@ static int stk8312_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops stk8312_trigger_ops = { .set_trigger_state = stk8312_data_rdy_trigger_set_state, - .owner =THIS_MODULE , };static int stk8312_set_sample_rate (struct stk8312_data *data,u8 rate)
@@ -421,7 +420,6 @@ static int stk8312_write_raw(struct iio_dev *indio_dev, }static const struct iio_info stk8312_info = { - .driver_module =THIS_MODULE , .read_raw = stk8312_read_raw, .write_raw = stk8312_write_raw, .attrs = &stk8312_attribute_group,
drivers/iio/accel/stk8ba50.c +0 -2
@@ -179,7 +179,6 @@ static int stk8ba50_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops stk8ba50_trigger_ops = { .set_trigger_state = stk8ba50_data_rdy_trigger_set_state, - .owner =THIS_MODULE , };static int stk8ba50_set_power (struct stk8ba50_data *data,bool mode)
@@ -307,7 +306,6 @@ static int stk8ba50_write_raw(struct iio_dev *indio_dev, }static const struct iio_info stk8ba50_info = { - .driver_module =THIS_MODULE , .read_raw = stk8ba50_read_raw, .write_raw = stk8ba50_write_raw, .attrs = &stk8ba50_attribute_group,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 6/38 iio:amplifiers:ad8366 drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/amplifiers/ad8366.c | 1 - 1 file changed, 1 deletion(-)
drivers/iio/amplifiers/ad8366.c +0 -1
@@ -117,7 +117,6 @@ static int ad8366_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad8366_info = { .read_raw = &ad8366_read_raw, .write_raw = &ad8366_write_raw, - .driver_module =THIS_MODULE , };#define AD8366_CHAN (_channel) { \
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 7/38 iio:chemical: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/chemical/ams-iaq-core.c | 1 - drivers/iio/chemical/atlas-ph-sensor.c | 2 -- drivers/iio/chemical/vz89x.c | 1 - 3 files changed, 4 deletions(-)
drivers/iio/chemical/ams-iaq-core.c +0 -1
@@ -141,7 +141,6 @@ static int ams_iaqcore_read_raw(struct iio_dev *indio_dev,static const struct iio_info ams_iaqcore_info = { .read_raw = ams_iaqcore_read_raw, - .driver_module =THIS_MODULE , }; static int ams_iaqcore_probe(struct i2c_client *client,
drivers/iio/chemical/atlas-ph-sensor.c +0 -2
@@ -344,7 +344,6 @@ static int atlas_buffer_predisable(struct iio_dev *indio_dev) }static const struct iio_trigger_ops atlas_interrupt_trigger_ops = { - .owner =THIS_MODULE , };static const struct iio_buffer_setup_ops atlas_buffer_setup_ops = {
@@ -499,7 +498,6 @@ static int atlas_write_raw(struct iio_dev *indio_dev, }static const struct iio_info atlas_info = { - .driver_module =THIS_MODULE , .read_raw = atlas_read_raw, .write_raw = atlas_write_raw, };
drivers/iio/chemical/vz89x.c +0 -1
@@ -326,7 +326,6 @@ static int vz89x_read_raw(struct iio_dev *indio_dev,static const struct iio_info vz89x_info = { .attrs = &vz89x_attrs_group, .read_raw = vz89x_read_raw, - .driver_module =THIS_MODULE , };static const struct vz89x_chip_data vz89x_chips[] = {
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 8/38 iio:common: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
Clearly this set jumps across multiple areas, but inherently it can't be grouped like the other sets in this series so I've done all the stuff in the common directory together.
--- drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c | 1 - drivers/iio/common/hid-sensors/hid-sensor-trigger.c | 1 - 2 files changed, 2 deletions(-)
drivers/iio/common/cros_ec_sensors/cros_ec_sensors.c +0 -1
@@ -185,7 +185,6 @@ static int cros_ec_sensors_write(struct iio_dev *indio_dev,static const struct iio_info ec_sensors_info = { .read_raw = &cros_ec_sensors_read, .write_raw = &cros_ec_sensors_write, - .driver_module =THIS_MODULE , };static int cros_ec_sensors_probe (struct platform_device *pdev)
drivers/iio/common/hid-sensors/hid-sensor-trigger.c +0 -1
@@ -241,7 +241,6 @@ void hid_sensor_remove_trigger(struct hid_sensor_common *attrb)EXPORT_SYMBOL (hid_sensor_remove_trigger);static const struct iio_trigger_ops hid_sensor_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &hid_sensor_data_rdy_trigger_set_state, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 9/38 iio:counter:104-quad-8 drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent is now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/counter/104-quad-8.c | 1 - 1 file changed, 1 deletion(-)
drivers/iio/counter/104-quad-8.c +0 -1
@@ -185,7 +185,6 @@ static int quad8_write_raw(struct iio_dev *indio_dev, }static const struct iio_info quad8_info = { - .driver_module =THIS_MODULE , .read_raw = quad8_read_raw, .write_raw = quad8_write_raw };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 10/38 iio:dac: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure element will shortly go away.
--- drivers/iio/dac/ad5064.c | 1 - drivers/iio/dac/ad5360.c | 1 - drivers/iio/dac/ad5380.c | 1 - drivers/iio/dac/ad5421.c | 1 - drivers/iio/dac/ad5446.c | 1 - drivers/iio/dac/ad5449.c | 1 - drivers/iio/dac/ad5504.c | 1 - drivers/iio/dac/ad5592r-base.c | 1 - drivers/iio/dac/ad5624r_spi.c | 1 - drivers/iio/dac/ad5686.c | 1 - drivers/iio/dac/ad5755.c | 1 - drivers/iio/dac/ad5761.c | 1 - drivers/iio/dac/ad5764.c | 1 - drivers/iio/dac/ad5791.c | 1 - drivers/iio/dac/ad7303.c | 1 - drivers/iio/dac/ad8801.c | 1 - drivers/iio/dac/cio-dac.c | 1 - drivers/iio/dac/dpot-dac.c | 1 - drivers/iio/dac/lpc18xx_dac.c | 1 - drivers/iio/dac/ltc2632.c | 1 - drivers/iio/dac/m62332.c | 1 - drivers/iio/dac/max517.c | 1 - drivers/iio/dac/max5821.c | 1 - drivers/iio/dac/mcp4725.c | 1 - drivers/iio/dac/mcp4922.c | 1 - drivers/iio/dac/stm32-dac.c | 1 - drivers/iio/dac/vf610_dac.c | 1 - 27 files changed, 27 deletions(-)
drivers/iio/dac/ad5064.c +0 -1
@@ -366,7 +366,6 @@ static int ad5064_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5064_info = { .read_raw = ad5064_read_raw, .write_raw = ad5064_write_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ad5064_ext_info[] = {
drivers/iio/dac/ad5360.c +0 -1
@@ -425,7 +425,6 @@ static const struct iio_info ad5360_info = { .read_raw = ad5360_read_raw, .write_raw = ad5360_write_raw, .attrs = &ad5360_attribute_group, - .driver_module = THIS_MODULE, };static const char *const ad5360_vref_name[] = {
drivers/iio/dac/ad5380.c +0 -1
@@ -237,7 +237,6 @@ static int ad5380_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad5380_info = { .read_raw = ad5380_read_raw, .write_raw = ad5380_write_raw, - .driver_module =THIS_MODULE , };static struct iio_chan_spec_ext_info ad5380_ext_info[] = {
drivers/iio/dac/ad5421.c +0 -1
@@ -465,7 +465,6 @@ static const struct iio_info ad5421_info = { .read_event_config = ad5421_read_event_config, .write_event_config = ad5421_write_event_config, .read_event_value = ad5421_read_event_value, - .driver_module = THIS_MODULE, };static int ad5421_probe (struct spi_device *spi)
drivers/iio/dac/ad5446.c +0 -1
@@ -212,7 +212,6 @@ static int ad5446_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5446_info = { .read_raw = ad5446_read_raw, .write_raw = ad5446_write_raw, - .driver_module =THIS_MODULE , }; static int ad5446_probe(struct device *dev, const char *name,
drivers/iio/dac/ad5449.c +0 -1
@@ -193,7 +193,6 @@ static int ad5449_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5449_info = { .read_raw = ad5449_read_raw, .write_raw = ad5449_write_raw, - .driver_module =THIS_MODULE , };#define AD5449_CHANNEL (chan, bits) { \
drivers/iio/dac/ad5504.c +0 -1
@@ -232,7 +232,6 @@ static const struct iio_info ad5504_info = { .write_raw = ad5504_write_raw, .read_raw = ad5504_read_raw, .event_attrs = &ad5504_ev_attribute_group, - .driver_module = THIS_MODULE, };static const struct iio_chan_spec_ext_info ad5504_ext_info[] = {
drivers/iio/dac/ad5592r-base.c +0 -1
@@ -474,7 +474,6 @@ static const struct iio_info ad5592r_info = { .read_raw = ad5592r_read_raw, .write_raw = ad5592r_write_raw, .write_raw_get_fmt = ad5592r_write_raw_get_fmt, - .driver_module = THIS_MODULE, }; static ssize_t ad5592r_show_scale_available(struct iio_dev *iio_dev,
drivers/iio/dac/ad5624r_spi.c +0 -1
@@ -149,7 +149,6 @@ static ssize_t ad5624r_write_dac_powerdown(struct iio_dev *indio_dev,static const struct iio_info ad5624r_info = { .write_raw = ad5624r_write_raw, .read_raw = ad5624r_read_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ad5624r_ext_info[] = {
drivers/iio/dac/ad5686.c +0 -1
@@ -252,7 +252,6 @@ static int ad5686_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5686_info = { .read_raw = ad5686_read_raw, .write_raw = ad5686_write_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ad5686_ext_info[] = {
drivers/iio/dac/ad5755.c +0 -1
@@ -417,7 +417,6 @@ static ssize_t ad5755_write_powerdown(struct iio_dev *indio_dev, uintptr_t priv,static const struct iio_info ad5755_info = { .read_raw = ad5755_read_raw, .write_raw = ad5755_write_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ad5755_ext_info[] = {
drivers/iio/dac/ad5761.c +0 -1
@@ -251,7 +251,6 @@ static int ad5761_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5761_info = { .read_raw = &ad5761_read_raw, .write_raw = &ad5761_write_raw, - .driver_module =THIS_MODULE , };#define AD5761_CHAN (_bits) { \
drivers/iio/dac/ad5764.c +0 -1
@@ -268,7 +268,6 @@ static int ad5764_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad5764_info = { .read_raw = ad5764_read_raw, .write_raw = ad5764_write_raw, - .driver_module =THIS_MODULE , };static int ad5764_probe (struct spi_device *spi)
drivers/iio/dac/ad5791.c +0 -1
@@ -340,7 +340,6 @@ static int ad5791_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad5791_info = { .read_raw = &ad5791_read_raw, .write_raw = &ad5791_write_raw, - .driver_module =THIS_MODULE , };static int ad5791_probe (struct spi_device *spi)
drivers/iio/dac/ad7303.c +0 -1
@@ -161,7 +161,6 @@ static int ad7303_write_raw(struct iio_dev *indio_dev,static const struct iio_info ad7303_info = { .read_raw = ad7303_read_raw, .write_raw = ad7303_write_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ad7303_ext_info[] = {
drivers/iio/dac/ad8801.c +0 -1
@@ -92,7 +92,6 @@ static int ad8801_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad8801_info = { .read_raw = ad8801_read_raw, .write_raw = ad8801_write_raw, - .driver_module =THIS_MODULE , };#define AD8801_CHANNEL (chan) { \
drivers/iio/dac/cio-dac.c +0 -1
@@ -85,7 +85,6 @@ static int cio_dac_write_raw(struct iio_dev *indio_dev, }static const struct iio_info cio_dac_info = { - .driver_module =THIS_MODULE , .read_raw = cio_dac_read_raw, .write_raw = cio_dac_write_raw };
drivers/iio/dac/dpot-dac.c +0 -1
@@ -128,7 +128,6 @@ static const struct iio_info dpot_dac_info = { .read_raw = dpot_dac_read_raw, .read_avail = dpot_dac_read_avail, .write_raw = dpot_dac_write_raw, - .driver_module = THIS_MODULE, };static int dpot_dac_channel_max_ohms (struct iio_dev *indio_dev)
drivers/iio/dac/lpc18xx_dac.c +0 -1
@@ -103,7 +103,6 @@ static int lpc18xx_dac_write_raw(struct iio_dev *indio_dev,static const struct iio_info lpc18xx_dac_info = { .read_raw = lpc18xx_dac_read_raw, .write_raw = lpc18xx_dac_write_raw, - .driver_module =THIS_MODULE , };static int lpc18xx_dac_probe (struct platform_device *pdev)
drivers/iio/dac/ltc2632.c +0 -1
@@ -159,7 +159,6 @@ static ssize_t ltc2632_write_dac_powerdown(struct iio_dev *indio_dev,static const struct iio_info ltc2632_info = { .write_raw = ltc2632_write_raw, .read_raw = ltc2632_read_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec_ext_info ltc2632_ext_info[] = {
drivers/iio/dac/m62332.c +0 -1
@@ -174,7 +174,6 @@ static SIMPLE_DEV_PM_OPS(m62332_pm_ops, m62332_suspend, m62332_resume);static const struct iio_info m62332_info = { .read_raw = m62332_read_raw, .write_raw = m62332_write_raw, - .driver_module =THIS_MODULE , };#define M62332_CHANNEL (chan) { \
drivers/iio/dac/max517.c +0 -1
@@ -137,7 +137,6 @@ static SIMPLE_DEV_PM_OPS(max517_pm_ops, max517_suspend, max517_resume);static const struct iio_info max517_info = { .read_raw = max517_read_raw, .write_raw = max517_write_raw, - .driver_module =THIS_MODULE , };#define MAX517_CHANNEL (chan) { \
drivers/iio/dac/max5821.c +0 -1
@@ -300,7 +300,6 @@ static SIMPLE_DEV_PM_OPS(max5821_pm_ops, max5821_suspend, max5821_resume);static const struct iio_info max5821_info = { .read_raw = max5821_read_raw, .write_raw = max5821_write_raw, - .driver_module =THIS_MODULE , }; static int max5821_probe(struct i2c_client *client,
drivers/iio/dac/mcp4725.c +0 -1
@@ -363,7 +363,6 @@ static const struct iio_info mcp4725_info = { .read_raw = mcp4725_read_raw, .write_raw = mcp4725_write_raw, .attrs = &mcp4725_attribute_group, - .driver_module = THIS_MODULE, };#ifdef CONFIG_OF
drivers/iio/dac/mcp4922.c +0 -1
@@ -119,7 +119,6 @@ static const struct iio_chan_spec mcp4922_channels[3][MCP4922_NUM_CHANNELS] = {static const struct iio_info mcp4922_info = { .read_raw = &mcp4922_read_raw, .write_raw = &mcp4922_write_raw, - .driver_module =THIS_MODULE , };static int mcp4922_probe (struct spi_device *spi)
drivers/iio/dac/stm32-dac.c +0 -1
@@ -156,7 +156,6 @@ static const struct iio_info stm32_dac_iio_info = { .read_raw = stm32_dac_read_raw, .write_raw = stm32_dac_write_raw, .debugfs_reg_access = stm32_dac_debugfs_reg_access, - .driver_module = THIS_MODULE, };static const char *const stm32_dac_powerdown_modes[] = {
drivers/iio/dac/vf610_dac.c +0 -1
@@ -167,7 +167,6 @@ static int vf610_write_raw(struct iio_dev *indio_dev, }static const struct iio_info vf610_dac_iio_info = { - .driver_module =THIS_MODULE , .read_raw = &vf610_read_raw, .write_raw = &vf610_write_raw, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 11/38 iio:dummy: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThe equivalent is now done via macro magic when the relevant register call is made. The actual structure element will shortly go away.
--- drivers/iio/dummy/iio_simple_dummy.c | 1 - 1 file changed, 1 deletion(-)
drivers/iio/dummy/iio_simple_dummy.c +0 -1
@@ -519,7 +519,6 @@ static int iio_dummy_write_raw(struct iio_dev *indio_dev,* Device type specific information. */ static const struct iio_info iio_dummy_info = { - .driver_module =THIS_MODULE , .read_raw = &iio_dummy_read_raw, .write_raw = &iio_dummy_write_raw, #ifdef CONFIG_IIO_SIMPLE_DUMMY_EVENTS
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 12/38 iio:frequency: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent is now done via macro magic when the relevant register call is made. The actual structure element will shortly go away.
--- drivers/iio/frequency/ad9523.c | 1 - drivers/iio/frequency/adf4350.c | 1 - 2 files changed, 2 deletions(-)
drivers/iio/frequency/ad9523.c +0 -1
@@ -738,7 +738,6 @@ static const struct iio_info ad9523_info = { .write_raw = &ad9523_write_raw, .debugfs_reg_access = &ad9523_reg_access, .attrs = &ad9523_attribute_group, - .driver_module = THIS_MODULE, };static int ad9523_setup (struct iio_dev *indio_dev)
drivers/iio/frequency/adf4350.c +0 -1
@@ -374,7 +374,6 @@ static const struct iio_chan_spec adf4350_chan = {static const struct iio_info adf4350_info = { .debugfs_reg_access = &adf4350_reg_access, - .driver_module =THIS_MODULE , };#ifdef CONFIG_OF
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 13/38 iio:gyro: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/gyro/adis16080.c | 1 - drivers/iio/gyro/adis16130.c | 1 - drivers/iio/gyro/adis16136.c | 1 - drivers/iio/gyro/adis16260.c | 1 - drivers/iio/gyro/adxrs450.c | 1 - drivers/iio/gyro/bmg160_core.c | 2 -- drivers/iio/gyro/hid-sensor-gyro-3d.c | 1 - drivers/iio/gyro/itg3200_buffer.c | 1 - drivers/iio/gyro/itg3200_core.c | 1 - drivers/iio/gyro/mpu3050-core.c | 2 -- drivers/iio/gyro/st_gyro_core.c | 2 -- 11 files changed, 14 deletions(-)
drivers/iio/gyro/adis16080.c +0 -1
@@ -163,7 +163,6 @@ static const struct iio_chan_spec adis16080_channels[] = {static const struct iio_info adis16080_info = { .read_raw = &adis16080_read_raw, - .driver_module =THIS_MODULE , };enum {
drivers/iio/gyro/adis16130.c +0 -1
@@ -137,7 +137,6 @@ static const struct iio_chan_spec adis16130_channels[] = {static const struct iio_info adis16130_info = { .read_raw = &adis16130_read_raw, - .driver_module =THIS_MODULE , };static int adis16130_probe (struct spi_device *spi)
drivers/iio/gyro/adis16136.c +0 -1
@@ -398,7 +398,6 @@ static const struct attribute_group adis16136_attribute_group = { };static const struct iio_info adis16136_info = { - .driver_module =THIS_MODULE , .attrs = &adis16136_attribute_group, .read_raw = &adis16136_read_raw, .write_raw = &adis16136_write_raw,
drivers/iio/gyro/adis16260.c +0 -1
@@ -321,7 +321,6 @@ static const struct iio_info adis16260_info = { .read_raw = &adis16260_read_raw, .write_raw = &adis16260_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static const char *const adis1620_status_error_msgs[] = {
drivers/iio/gyro/adxrs450.c +0 -1
@@ -405,7 +405,6 @@ static const struct iio_chan_spec adxrs450_channels[2][2] = { };static const struct iio_info adxrs450_info = { - .driver_module =THIS_MODULE , .read_raw = &adxrs450_read_raw, .write_raw = &adxrs450_write_raw, };
drivers/iio/gyro/bmg160_core.c +0 -2
@@ -858,7 +858,6 @@ static const struct iio_info bmg160_info = { .write_event_value = bmg160_write_event, .write_event_config = bmg160_write_event_config, .read_event_config = bmg160_read_event_config, - .driver_module = THIS_MODULE, };static const unsigned long bmg160_accel_scan_masks[] = {
@@ -956,7 +955,6 @@ static int bmg160_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops bmg160_trigger_ops = { .set_trigger_state = bmg160_data_rdy_trigger_set_state, .try_reenable = bmg160_trig_try_reen, - .owner =THIS_MODULE , };static irqreturn_t bmg160_event_handler (int irq,void *private)
drivers/iio/gyro/hid-sensor-gyro-3d.c +0 -1
@@ -186,7 +186,6 @@ static int gyro_3d_write_raw(struct iio_dev *indio_dev, }static const struct iio_info gyro_3d_info = { - .driver_module =THIS_MODULE , .read_raw = &gyro_3d_read_raw, .write_raw = &gyro_3d_write_raw, };
drivers/iio/gyro/itg3200_buffer.c +0 -1
@@ -101,7 +101,6 @@ static int itg3200_data_rdy_trigger_set_state(struct iio_trigger *trig, }static const struct iio_trigger_ops itg3200_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &itg3200_data_rdy_trigger_set_state, };
drivers/iio/gyro/itg3200_core.c +0 -1
@@ -278,7 +278,6 @@ static const struct iio_chan_spec itg3200_channels[] = {static const struct iio_info itg3200_info = { .read_raw = &itg3200_read_raw, .write_raw = &itg3200_write_raw, - .driver_module =THIS_MODULE , };static const unsigned long itg3200_available_scan_masks[] = {0xffffffff ,0x0 };
drivers/iio/gyro/mpu3050-core.c +0 -2
@@ -742,7 +742,6 @@ static const struct attribute_group mpu3050_attribute_group = { };static const struct iio_info mpu3050_info = { - .driver_module =THIS_MODULE , .read_raw = mpu3050_read_raw, .write_raw = mpu3050_write_raw, .attrs = &mpu3050_attribute_group,
@@ -1032,7 +1031,6 @@ static int mpu3050_drdy_trigger_set_state(struct iio_trigger *trig, }static const struct iio_trigger_ops mpu3050_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = mpu3050_drdy_trigger_set_state, };
drivers/iio/gyro/st_gyro_core.c +0 -2
@@ -325,7 +325,6 @@ static const struct attribute_group st_gyro_attribute_group = { };static const struct iio_info gyro_info = { - .driver_module =THIS_MODULE , .attrs = &st_gyro_attribute_group, .read_raw = &st_gyro_read_raw, .write_raw = &st_gyro_write_raw,
@@ -334,7 +333,6 @@ static const struct iio_info gyro_info = {#ifdef CONFIG_IIO_TRIGGER static const struct iio_trigger_ops st_gyro_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state =ST_GYRO_TRIGGER_SET_STATE , .validate_device = st_sensors_validate_device, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 14/38 iio:health: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/health/afe4403.c | 2 -- drivers/iio/health/afe4404.c | 2 -- drivers/iio/health/max30100.c | 1 - drivers/iio/health/max30102.c | 1 - 4 files changed, 6 deletions(-)
drivers/iio/health/afe4403.c +0 -2
@@ -309,7 +309,6 @@ static const struct iio_info afe4403_iio_info = { .attrs = &afe440x_attribute_group, .read_raw = afe4403_read_raw, .write_raw = afe4403_write_raw, - .driver_module = THIS_MODULE, };static irqreturn_t afe4403_trigger_handler (int irq,void *private)
@@ -354,7 +353,6 @@ static irqreturn_t afe4403_trigger_handler(int irq, void *private) }static const struct iio_trigger_ops afe4403_trigger_ops = { - .owner =THIS_MODULE , };#define AFE4403_TIMING_PAIRS \
drivers/iio/health/afe4404.c +0 -2
@@ -328,7 +328,6 @@ static const struct iio_info afe4404_iio_info = { .attrs = &afe440x_attribute_group, .read_raw = afe4404_read_raw, .write_raw = afe4404_write_raw, - .driver_module = THIS_MODULE, };static irqreturn_t afe4404_trigger_handler (int irq,void *private)
@@ -355,7 +354,6 @@ static irqreturn_t afe4404_trigger_handler(int irq, void *private) }static const struct iio_trigger_ops afe4404_trigger_ops = { - .owner =THIS_MODULE , };/* Default timings from data-sheet */
drivers/iio/health/max30100.c +0 -1
@@ -420,7 +420,6 @@ static int max30100_read_raw(struct iio_dev *indio_dev, }static const struct iio_info max30100_info = { - .driver_module =THIS_MODULE , .read_raw = max30100_read_raw, };
drivers/iio/health/max30102.c +0 -1
@@ -381,7 +381,6 @@ static int max30102_read_raw(struct iio_dev *indio_dev, }static const struct iio_info max30102_info = { - .driver_module =THIS_MODULE , .read_raw = max30102_read_raw, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 15/38 iio:humidity: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/humidity/am2315.c | 1 - drivers/iio/humidity/dht11.c | 1 - drivers/iio/humidity/hdc100x.c | 1 - drivers/iio/humidity/hid-sensor-humidity.c | 1 - drivers/iio/humidity/hts221_buffer.c | 1 - drivers/iio/humidity/hts221_core.c | 1 - drivers/iio/humidity/htu21.c | 1 - drivers/iio/humidity/si7005.c | 1 - drivers/iio/humidity/si7020.c | 1 - 9 files changed, 9 deletions(-)
drivers/iio/humidity/am2315.c +0 -1
@@ -215,7 +215,6 @@ static int am2315_read_raw(struct iio_dev *indio_dev, }static const struct iio_info am2315_info = { - .driver_module =THIS_MODULE , .read_raw = am2315_read_raw, };
drivers/iio/humidity/dht11.c +0 -1
@@ -284,7 +284,6 @@ static int dht11_read_raw(struct iio_dev *iio_dev, }static const struct iio_info dht11_iio_info = { - .driver_module =THIS_MODULE , .read_raw = dht11_read_raw, };
drivers/iio/humidity/hdc100x.c +0 -1
@@ -351,7 +351,6 @@ static const struct iio_info hdc100x_info = { .read_raw = hdc100x_read_raw, .write_raw = hdc100x_write_raw, .attrs = &hdc100x_attribute_group, - .driver_module = THIS_MODULE, }; static int hdc100x_probe(struct i2c_client *client,
drivers/iio/humidity/hid-sensor-humidity.c +0 -1
@@ -125,7 +125,6 @@ static int humidity_write_raw(struct iio_dev *indio_dev, }static const struct iio_info humidity_info = { - .driver_module =THIS_MODULE , .read_raw = &humidity_read_raw, .write_raw = &humidity_write_raw, };
drivers/iio/humidity/hts221_buffer.c +0 -1
@@ -35,7 +35,6 @@ static int hts221_trig_set_state(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops hts221_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = hts221_trig_set_state, };
drivers/iio/humidity/hts221_core.c +0 -1
@@ -623,7 +623,6 @@ static const struct attribute_group hts221_attribute_group = { };static const struct iio_info hts221_info = { - .driver_module =THIS_MODULE , .attrs = &hts221_attribute_group, .read_raw = hts221_read_raw, .write_raw = hts221_write_raw,
drivers/iio/humidity/htu21.c +0 -1
@@ -175,7 +175,6 @@ static const struct iio_info htu21_info = { .read_raw = htu21_read_raw, .write_raw = htu21_write_raw, .attrs = &htu21_attribute_group, - .driver_module = THIS_MODULE, }; static int htu21_probe(struct i2c_client *client,
drivers/iio/humidity/si7005.c +0 -1
@@ -124,7 +124,6 @@ static const struct iio_chan_spec si7005_channels[] = {static const struct iio_info si7005_info = { .read_raw = si7005_read_raw, - .driver_module =THIS_MODULE , }; static int si7005_probe(struct i2c_client *client,
drivers/iio/humidity/si7020.c +0 -1
@@ -108,7 +108,6 @@ static const struct iio_chan_spec si7020_channels[] = {static const struct iio_info si7020_info = { .read_raw = si7020_read_raw, - .driver_module =THIS_MODULE , }; static int si7020_probe(struct i2c_client *client,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 16/38 iio:imu: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/imu/adis16400_core.c | 1 - drivers/iio/imu/adis16480.c | 1 - drivers/iio/imu/adis_trigger.c | 1 - drivers/iio/imu/bmi160/bmi160_core.c | 1 - drivers/iio/imu/inv_mpu6050/inv_mpu_core.c | 1 - drivers/iio/imu/inv_mpu6050/inv_mpu_trigger.c | 1 - drivers/iio/imu/kmx61.c | 3 --- drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c | 2 -- 8 files changed, 11 deletions(-)
drivers/iio/imu/adis16400_core.c +0 -1
@@ -833,7 +833,6 @@ static struct adis16400_chip_info adis16400_chips[] = { };static const struct iio_info adis16400_info = { - .driver_module =THIS_MODULE , .read_raw = &adis16400_read_raw, .write_raw = &adis16400_write_raw, .update_scan_mode = adis16400_update_scan_mode,
drivers/iio/imu/adis16480.c +0 -1
@@ -720,7 +720,6 @@ static const struct iio_info adis16480_info = { .read_raw = &adis16480_read_raw, .write_raw = &adis16480_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static int adis16480_stop_device (struct iio_dev *indio_dev)
drivers/iio/imu/adis_trigger.c +0 -1
@@ -25,7 +25,6 @@ static int adis_data_rdy_trigger_set_state(struct iio_trigger *trig, }static const struct iio_trigger_ops adis_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &adis_data_rdy_trigger_set_state, };
drivers/iio/imu/bmi160/bmi160_core.c +0 -1
@@ -482,7 +482,6 @@ static const struct attribute_group bmi160_attrs_group = { };static const struct iio_info bmi160_info = { - .driver_module =THIS_MODULE , .read_raw = bmi160_read_raw, .write_raw = bmi160_write_raw, .attrs = &bmi160_attrs_group,
drivers/iio/imu/inv_mpu6050/inv_mpu_core.c +0 -1
@@ -755,7 +755,6 @@ static const struct attribute_group inv_attribute_group = { };static const struct iio_info mpu_info = { - .driver_module =THIS_MODULE , .read_raw = &inv_mpu6050_read_raw, .write_raw = &inv_mpu6050_write_raw, .write_raw_get_fmt = &inv_write_raw_get_fmt,
drivers/iio/imu/inv_mpu6050/inv_mpu_trigger.c +0 -1
@@ -107,7 +107,6 @@ static int inv_mpu_data_rdy_trigger_set_state(struct iio_trigger *trig, }static const struct iio_trigger_ops inv_mpu_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &inv_mpu_data_rdy_trigger_set_state, };
drivers/iio/imu/kmx61.c +0 -3
@@ -1003,7 +1003,6 @@ static int kmx61_mag_validate_trigger(struct iio_dev *indio_dev, }static const struct iio_info kmx61_acc_info = { - .driver_module =THIS_MODULE , .read_raw = kmx61_read_raw, .write_raw = kmx61_write_raw, .attrs = &kmx61_acc_attribute_group,
@@ -1015,7 +1014,6 @@ static const struct iio_info kmx61_acc_info = { };static const struct iio_info kmx61_mag_info = { - .driver_module =THIS_MODULE , .read_raw = kmx61_read_raw, .write_raw = kmx61_write_raw, .attrs = &kmx61_mag_attribute_group,
@@ -1087,7 +1085,6 @@ static int kmx61_trig_try_reenable(struct iio_trigger *trig)static const struct iio_trigger_ops kmx61_trigger_ops = { .set_trigger_state = kmx61_data_rdy_trigger_set_state, .try_reenable = kmx61_trig_try_reenable, - .owner =THIS_MODULE , };static irqreturn_t kmx61_event_handler (int irq,void *private)
drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c +0 -2
@@ -530,7 +530,6 @@ static const struct attribute_group st_lsm6dsx_acc_attribute_group = { };static const struct iio_info st_lsm6dsx_acc_info = { - .driver_module =THIS_MODULE , .attrs = &st_lsm6dsx_acc_attribute_group, .read_raw = st_lsm6dsx_read_raw, .write_raw = st_lsm6dsx_write_raw,
@@ -548,7 +547,6 @@ static const struct attribute_group st_lsm6dsx_gyro_attribute_group = { };static const struct iio_info st_lsm6dsx_gyro_info = { - .driver_module =THIS_MODULE , .attrs = &st_lsm6dsx_gyro_attribute_group, .read_raw = st_lsm6dsx_read_raw, .write_raw = st_lsm6dsx_write_raw,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 17/38 iio:light: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/light/acpi-als.c | 1 - drivers/iio/light/adjd_s311.c | 1 - drivers/iio/light/al3320a.c | 1 - drivers/iio/light/apds9300.c | 2 -- drivers/iio/light/apds9960.c | 1 - drivers/iio/light/bh1750.c | 1 - drivers/iio/light/bh1780.c | 1 - drivers/iio/light/cm32181.c | 1 - drivers/iio/light/cm3232.c | 1 - drivers/iio/light/cm3323.c | 1 - drivers/iio/light/cm3605.c | 1 - drivers/iio/light/cm36651.c | 1 - drivers/iio/light/cros_ec_light_prox.c | 1 - drivers/iio/light/gp2ap020a00f.c | 2 -- drivers/iio/light/hid-sensor-als.c | 1 - drivers/iio/light/hid-sensor-prox.c | 1 - drivers/iio/light/isl29018.c | 2 -- drivers/iio/light/isl29028.c | 1 - drivers/iio/light/isl29125.c | 1 - drivers/iio/light/jsa1212.c | 1 - drivers/iio/light/lm3533-als.c | 1 - drivers/iio/light/ltr501.c | 4 ---- drivers/iio/light/max44000.c | 1 - drivers/iio/light/opt3001.c | 1 - drivers/iio/light/pa12203001.c | 1 - drivers/iio/light/rpr0521.c | 1 - drivers/iio/light/si1145.c | 3 --- drivers/iio/light/stk3310.c | 1 - drivers/iio/light/tcs3414.c | 1 - drivers/iio/light/tcs3472.c | 1 - drivers/iio/light/tsl2563.c | 2 -- drivers/iio/light/tsl2583.c | 1 - drivers/iio/light/tsl4531.c | 1 - drivers/iio/light/us5182d.c | 1 - drivers/iio/light/vcnl4000.c | 1 - drivers/iio/light/veml6070.c | 1 - drivers/iio/light/vl6180.c | 1 - 37 files changed, 46 deletions(-)
drivers/iio/light/acpi-als.c +0 -1
@@ -171,7 +171,6 @@ static int acpi_als_read_raw(struct iio_dev *indio_dev, }static const struct iio_info acpi_als_info = { - .driver_module =THIS_MODULE , .read_raw = acpi_als_read_raw, };
drivers/iio/light/adjd_s311.c +0 -1
@@ -245,7 +245,6 @@ static const struct iio_info adjd_s311_info = { .read_raw = adjd_s311_read_raw, .write_raw = adjd_s311_write_raw, .update_scan_mode = adjd_s311_update_scan_mode, - .driver_module = THIS_MODULE, }; static int adjd_s311_probe(struct i2c_client *client,
drivers/iio/light/al3320a.c +0 -1
@@ -168,7 +168,6 @@ static int al3320a_write_raw(struct iio_dev *indio_dev, }static const struct iio_info al3320a_info = { - .driver_module =THIS_MODULE , .read_raw = al3320a_read_raw, .write_raw = al3320a_write_raw, .attrs = &al3320a_attribute_group,
drivers/iio/light/apds9300.c +0 -2
@@ -337,12 +337,10 @@ static int apds9300_write_interrupt_config(struct iio_dev *indio_dev, }static const struct iio_info apds9300_info_no_irq = { - .driver_module =THIS_MODULE , .read_raw = apds9300_read_raw, };static const struct iio_info apds9300_info = { - .driver_module =THIS_MODULE , .read_raw = apds9300_read_raw, .read_event_value = apds9300_read_thresh, .write_event_value = apds9300_write_thresh,
drivers/iio/light/apds9960.c +0 -1
@@ -744,7 +744,6 @@ static int apds9960_write_event_config(struct iio_dev *indio_dev, }static const struct iio_info apds9960_info = { - .driver_module =THIS_MODULE , .attrs = &apds9960_attribute_group, .read_raw = apds9960_read_raw, .write_raw = apds9960_write_raw,
drivers/iio/light/bh1750.c +0 -1
@@ -217,7 +217,6 @@ static const struct attribute_group bh1750_attribute_group = { };static const struct iio_info bh1750_info = { - .driver_module =THIS_MODULE , .attrs = &bh1750_attribute_group, .read_raw = bh1750_read_raw, .write_raw = bh1750_write_raw,
drivers/iio/light/bh1780.c +0 -1
@@ -128,7 +128,6 @@ static int bh1780_read_raw(struct iio_dev *indio_dev, }static const struct iio_info bh1780_info = { - .driver_module =THIS_MODULE , .read_raw = bh1780_read_raw, .debugfs_reg_access = bh1780_debugfs_reg_access, };
drivers/iio/light/cm32181.c +0 -1
@@ -292,7 +292,6 @@ static const struct attribute_group cm32181_attribute_group = { };static const struct iio_info cm32181_info = { - .driver_module =THIS_MODULE , .read_raw = &cm32181_read_raw, .write_raw = &cm32181_write_raw, .attrs = &cm32181_attribute_group,
drivers/iio/light/cm3232.c +0 -1
@@ -322,7 +322,6 @@ static const struct attribute_group cm3232_attribute_group = { };static const struct iio_info cm3232_info = { - .driver_module =THIS_MODULE , .read_raw = &cm3232_read_raw, .write_raw = &cm3232_write_raw, .attrs = &cm3232_attribute_group,
drivers/iio/light/cm3323.c +0 -1
@@ -211,7 +211,6 @@ static int cm3323_write_raw(struct iio_dev *indio_dev, }static const struct iio_info cm3323_info = { - .driver_module =THIS_MODULE , .read_raw = cm3323_read_raw, .write_raw = cm3323_write_raw, .attrs = &cm3323_attribute_group,
drivers/iio/light/cm3605.c +0 -1
@@ -126,7 +126,6 @@ static int cm3605_read_raw(struct iio_dev *indio_dev, }static const struct iio_info cm3605_info = { - .driver_module =THIS_MODULE , .read_raw = cm3605_read_raw, };
drivers/iio/light/cm36651.c +0 -1
@@ -612,7 +612,6 @@ static const struct attribute_group cm36651_attribute_group = { };static const struct iio_info cm36651_info = { - .driver_module =THIS_MODULE , .read_raw = &cm36651_read_raw, .write_raw = &cm36651_write_raw, .read_event_value = &cm36651_read_prox_thresh,
drivers/iio/light/cros_ec_light_prox.c +0 -1
@@ -175,7 +175,6 @@ static int cros_ec_light_prox_write(struct iio_dev *indio_dev,static const struct iio_info cros_ec_light_prox_info = { .read_raw = &cros_ec_light_prox_read, .write_raw = &cros_ec_light_prox_write, - .driver_module =THIS_MODULE , };static int cros_ec_light_prox_probe (struct platform_device *pdev)
drivers/iio/light/gp2ap020a00f.c +0 -2
@@ -1384,7 +1384,6 @@ static const struct iio_info gp2ap020a00f_info = { .read_event_config = &gp2ap020a00f_read_event_config, .write_event_value = &gp2ap020a00f_write_event_val, .write_event_config = &gp2ap020a00f_write_event_config, - .driver_module = THIS_MODULE, };static int gp2ap020a00f_buffer_postenable (struct iio_dev *indio_dev)
@@ -1481,7 +1480,6 @@ static const struct iio_buffer_setup_ops gp2ap020a00f_buffer_setup_ops = { };static const struct iio_trigger_ops gp2ap020a00f_trigger_ops = { - .owner =THIS_MODULE , }; static int gp2ap020a00f_probe(struct i2c_client *client,
drivers/iio/light/hid-sensor-als.c +0 -1
@@ -177,7 +177,6 @@ static int als_write_raw(struct iio_dev *indio_dev, }static const struct iio_info als_info = { - .driver_module =THIS_MODULE , .read_raw = &als_read_raw, .write_raw = &als_write_raw, };
drivers/iio/light/hid-sensor-prox.c +0 -1
@@ -156,7 +156,6 @@ static int prox_write_raw(struct iio_dev *indio_dev, }static const struct iio_info prox_info = { - .driver_module =THIS_MODULE , .read_raw = &prox_read_raw, .write_raw = &prox_write_raw, };
drivers/iio/light/isl29018.c +0 -2
@@ -624,14 +624,12 @@ static int isl29018_chip_init(struct isl29018_chip *chip)static const struct iio_info isl29018_info = { .attrs = &isl29018_group, - .driver_module =THIS_MODULE , .read_raw = isl29018_read_raw, .write_raw = isl29018_write_raw, };static const struct iio_info isl29023_info = { .attrs = &isl29023_group, - .driver_module =THIS_MODULE , .read_raw = isl29018_read_raw, .write_raw = isl29018_write_raw, };
drivers/iio/light/isl29028.c +0 -1
@@ -536,7 +536,6 @@ static const struct iio_chan_spec isl29028_channels[] = {static const struct iio_info isl29028_info = { .attrs = &isl29108_group, - .driver_module =THIS_MODULE , .read_raw = isl29028_read_raw, .write_raw = isl29028_write_raw, };
drivers/iio/light/isl29125.c +0 -1
@@ -214,7 +214,6 @@ static const struct iio_info isl29125_info = { .read_raw = isl29125_read_raw, .write_raw = isl29125_write_raw, .attrs = &isl29125_attribute_group, - .driver_module = THIS_MODULE, };static int isl29125_buffer_preenable (struct iio_dev *indio_dev)
drivers/iio/light/jsa1212.c +0 -1
@@ -271,7 +271,6 @@ static const struct iio_chan_spec jsa1212_channels[] = { };static const struct iio_info jsa1212_info = { - .driver_module =THIS_MODULE , .read_raw = &jsa1212_read_raw, };
drivers/iio/light/lm3533-als.c +0 -1
@@ -827,7 +827,6 @@ static int lm3533_als_disable(struct lm3533_als *als)static const struct iio_info lm3533_als_info = { .attrs = &lm3533_als_attribute_group, .event_attrs = &lm3533_als_event_attribute_group, - .driver_module =THIS_MODULE , .read_raw = &lm3533_als_read_raw, };
drivers/iio/light/ltr501.c +0 -4
@@ -1158,7 +1158,6 @@ static const struct iio_info ltr501_info_no_irq = { .read_raw = ltr501_read_raw, .write_raw = ltr501_write_raw, .attrs = <r501_attribute_group, - .driver_module = THIS_MODULE, };static const struct iio_info ltr501_info = {
@@ -1169,14 +1168,12 @@ static const struct iio_info ltr501_info = { .write_event_value = <r501_write_event, .read_event_config = <r501_read_event_config, .write_event_config = <r501_write_event_config, - .driver_module = THIS_MODULE, };static const struct iio_info ltr301_info_no_irq = { .read_raw = ltr501_read_raw, .write_raw = ltr501_write_raw, .attrs = <r301_attribute_group, - .driver_module =THIS_MODULE , };static const struct iio_info ltr301_info = {
@@ -1187,7 +1184,6 @@ static const struct iio_info ltr301_info = { .write_event_value = <r501_write_event, .read_event_config = <r501_read_event_config, .write_event_config = <r501_write_event_config, - .driver_module = THIS_MODULE, };static struct ltr501_chip_info ltr501_chip_info_tbl[] = {
drivers/iio/light/max44000.c +0 -1
@@ -402,7 +402,6 @@ static const struct attribute_group max44000_attribute_group = { };static const struct iio_info max44000_info = { - .driver_module =THIS_MODULE , .read_raw = max44000_read_raw, .write_raw = max44000_write_raw, .write_raw_get_fmt = max44000_write_raw_get_fmt,
drivers/iio/light/opt3001.c +0 -1
@@ -585,7 +585,6 @@ static int opt3001_write_event_config(struct iio_dev *iio, }static const struct iio_info opt3001_info = { - .driver_module =THIS_MODULE , .attrs = &opt3001_attribute_group, .read_raw = opt3001_read_raw, .write_raw = opt3001_write_raw,
drivers/iio/light/pa12203001.c +0 -1
@@ -306,7 +306,6 @@ static int pa12203001_write_raw(struct iio_dev *indio_dev, }static const struct iio_info pa12203001_info = { - .driver_module =THIS_MODULE , .read_raw = pa12203001_read_raw, .write_raw = pa12203001_write_raw, .attrs = &pa12203001_attr_group,
drivers/iio/light/rpr0521.c +0 -1
@@ -576,7 +576,6 @@ static int rpr0521_write_raw(struct iio_dev *indio_dev, }static const struct iio_info rpr0521_info = { - .driver_module =THIS_MODULE , .read_raw = rpr0521_read_raw, .write_raw = rpr0521_write_raw, .attrs = &rpr0521_attribute_group,
drivers/iio/light/si1145.c +0 -3
@@ -989,14 +989,12 @@ static const struct attribute_group si114x_attribute_group = {static const struct iio_info si1132_info = { .read_raw = si1145_read_raw, .write_raw = si1145_write_raw, - .driver_module =THIS_MODULE , .attrs = &si1132_attribute_group, };static const struct iio_info si114x_info = { .read_raw = si1145_read_raw, .write_raw = si1145_write_raw, - .driver_module =THIS_MODULE , .attrs = &si114x_attribute_group, };
@@ -1237,7 +1235,6 @@ static int si1145_trigger_set_state(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops si1145_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = si1145_trigger_set_state, };
drivers/iio/light/stk3310.c +0 -1
@@ -409,7 +409,6 @@ static int stk3310_write_raw(struct iio_dev *indio_dev, }static const struct iio_info stk3310_info = { - .driver_module =THIS_MODULE , .read_raw = stk3310_read_raw, .write_raw = stk3310_write_raw, .attrs = &stk3310_attribute_group,
drivers/iio/light/tcs3414.c +0 -1
@@ -241,7 +241,6 @@ static const struct iio_info tcs3414_info = { .read_raw = tcs3414_read_raw, .write_raw = tcs3414_write_raw, .attrs = &tcs3414_attribute_group, - .driver_module = THIS_MODULE, };static int tcs3414_buffer_preenable (struct iio_dev *indio_dev)
drivers/iio/light/tcs3472.c +0 -1
@@ -244,7 +244,6 @@ static const struct iio_info tcs3472_info = { .read_raw = tcs3472_read_raw, .write_raw = tcs3472_write_raw, .attrs = &tcs3472_attribute_group, - .driver_module = THIS_MODULE, }; static int tcs3472_probe(struct i2c_client *client,
drivers/iio/light/tsl2563.c +0 -2
@@ -697,13 +697,11 @@ static int tsl2563_read_interrupt_config(struct iio_dev *indio_dev, }static const struct iio_info tsl2563_info_no_irq = { - .driver_module =THIS_MODULE , .read_raw = &tsl2563_read_raw, .write_raw = &tsl2563_write_raw, };static const struct iio_info tsl2563_info = { - .driver_module =THIS_MODULE , .read_raw = &tsl2563_read_raw, .write_raw = &tsl2563_write_raw, .read_event_value = &tsl2563_read_thresh,
drivers/iio/light/tsl2583.c +0 -1
@@ -804,7 +804,6 @@ static int tsl2583_write_raw(struct iio_dev *indio_dev,static const struct iio_info tsl2583_info = { .attrs = &tsl2583_attribute_group, - .driver_module =THIS_MODULE , .read_raw = tsl2583_read_raw, .write_raw = tsl2583_write_raw, };
drivers/iio/light/tsl4531.c +0 -1
@@ -144,7 +144,6 @@ static const struct iio_info tsl4531_info = { .read_raw = tsl4531_read_raw, .write_raw = tsl4531_write_raw, .attrs = &tsl4531_attribute_group, - .driver_module = THIS_MODULE, };static int tsl4531_check_id (struct i2c_client *client)
drivers/iio/light/us5182d.c +0 -1
@@ -714,7 +714,6 @@ static int us5182d_write_event_config(struct iio_dev *indio_dev, }static const struct iio_info us5182d_info = { - .driver_module =THIS_MODULE , .read_raw = us5182d_read_raw, .write_raw = us5182d_write_raw, .attrs = &us5182d_attr_group,
drivers/iio/light/vcnl4000.c +0 -1
@@ -155,7 +155,6 @@ static int vcnl4000_read_raw(struct iio_dev *indio_dev,static const struct iio_info vcnl4000_info = { .read_raw = vcnl4000_read_raw, - .driver_module =THIS_MODULE , }; static int vcnl4000_probe(struct i2c_client *client,
drivers/iio/light/veml6070.c +0 -1
@@ -136,7 +136,6 @@ static int veml6070_read_raw(struct iio_dev *indio_dev,static const struct iio_info veml6070_info = { .read_raw = veml6070_read_raw, - .driver_module =THIS_MODULE , }; static int veml6070_probe(struct i2c_client *client,
drivers/iio/light/vl6180.c +0 -1
@@ -429,7 +429,6 @@ static const struct iio_info vl6180_info = { .read_raw = vl6180_read_raw, .write_raw = vl6180_write_raw, .attrs = &vl6180_attribute_group, - .driver_module = THIS_MODULE, };static int vl6180_init (struct vl6180_data *data)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 18/38 iio:magnetometer: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/magnetometer/ak8974.c | 1 - drivers/iio/magnetometer/ak8975.c | 1 - drivers/iio/magnetometer/bmc150_magn.c | 2 -- drivers/iio/magnetometer/hid-sensor-magn-3d.c | 1 - drivers/iio/magnetometer/hmc5843_core.c | 1 - drivers/iio/magnetometer/mag3110.c | 1 - drivers/iio/magnetometer/mmc35240.c | 1 - drivers/iio/magnetometer/st_magn_core.c | 2 -- 8 files changed, 10 deletions(-)
drivers/iio/magnetometer/ak8974.c +0 -1
@@ -568,7 +568,6 @@ static const unsigned long ak8974_scan_masks[] = { 0x7, 0 };static const struct iio_info ak8974_info = { .read_raw = &ak8974_read_raw, - .driver_module =THIS_MODULE , };static bool ak8974_writeable_reg (struct device *dev,unsigned int reg)
drivers/iio/magnetometer/ak8975.c +0 -1
@@ -781,7 +781,6 @@ static const unsigned long ak8975_scan_masks[] = { 0x7, 0 };static const struct iio_info ak8975_info = { .read_raw = &ak8975_read_raw, - .driver_module =THIS_MODULE , };static const struct acpi_device_id ak_acpi_match[] = {
drivers/iio/magnetometer/bmc150_magn.c +0 -2
@@ -651,7 +651,6 @@ static const struct iio_info bmc150_magn_info = { .attrs = &bmc150_magn_attrs_group, .read_raw = bmc150_magn_read_raw, .write_raw = bmc150_magn_write_raw, - .driver_module = THIS_MODULE, };static const unsigned long bmc150_magn_scan_masks[] = {
@@ -811,7 +810,6 @@ static int bmc150_magn_data_rdy_trigger_set_state(struct iio_trigger *trig,static const struct iio_trigger_ops bmc150_magn_trigger_ops = { .set_trigger_state = bmc150_magn_data_rdy_trigger_set_state, .try_reenable = bmc150_magn_trig_try_reen, - .owner =THIS_MODULE , };static int bmc150_magn_buffer_preenable (struct iio_dev *indio_dev)
drivers/iio/magnetometer/hid-sensor-magn-3d.c +0 -1
@@ -282,7 +282,6 @@ static int magn_3d_write_raw(struct iio_dev *indio_dev, }static const struct iio_info magn_3d_info = { - .driver_module =THIS_MODULE , .read_raw = &magn_3d_read_raw, .write_raw = &magn_3d_write_raw, };
drivers/iio/magnetometer/hmc5843_core.c +0 -1
@@ -597,7 +597,6 @@ static const struct iio_info hmc5843_info = { .read_raw = &hmc5843_read_raw, .write_raw = &hmc5843_write_raw, .write_raw_get_fmt = &hmc5843_write_raw_get_fmt, - .driver_module = THIS_MODULE, };static const unsigned long hmc5843_scan_masks[] = {0x7 ,0 };
drivers/iio/magnetometer/mag3110.c +0 -1
@@ -333,7 +333,6 @@ static const struct iio_info mag3110_info = { .attrs = &mag3110_group, .read_raw = &mag3110_read_raw, .write_raw = &mag3110_write_raw, - .driver_module = THIS_MODULE, };static const unsigned long mag3110_scan_masks[] = {0x7 ,0xf ,0 };
drivers/iio/magnetometer/mmc35240.c +0 -1
@@ -418,7 +418,6 @@ static int mmc35240_write_raw(struct iio_dev *indio_dev, }static const struct iio_info mmc35240_info = { - .driver_module =THIS_MODULE , .read_raw = mmc35240_read_raw, .write_raw = mmc35240_write_raw, .attrs = &mmc35240_attribute_group,
drivers/iio/magnetometer/st_magn_core.c +0 -2
@@ -435,7 +435,6 @@ static const struct attribute_group st_magn_attribute_group = { };static const struct iio_info magn_info = { - .driver_module =THIS_MODULE , .attrs = &st_magn_attribute_group, .read_raw = &st_magn_read_raw, .write_raw = &st_magn_write_raw,
@@ -444,7 +443,6 @@ static const struct iio_info magn_info = {#ifdef CONFIG_IIO_TRIGGER static const struct iio_trigger_ops st_magn_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state =ST_MAGN_TRIGGER_SET_STATE , .validate_device = st_sensors_validate_device, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 19/38 iio:orientation: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/iio/orientation/hid-sensor-incl-3d.c | 1 - drivers/iio/orientation/hid-sensor-rotation.c | 1 - 2 files changed, 2 deletions(-)
drivers/iio/orientation/hid-sensor-incl-3d.c +0 -1
@@ -186,7 +186,6 @@ static int incl_3d_write_raw(struct iio_dev *indio_dev, }static const struct iio_info incl_3d_info = { - .driver_module =THIS_MODULE , .read_raw = &incl_3d_read_raw, .write_raw = &incl_3d_write_raw, };
drivers/iio/orientation/hid-sensor-rotation.c +0 -1
@@ -138,7 +138,6 @@ static int dev_rot_write_raw(struct iio_dev *indio_dev, }static const struct iio_info dev_rot_info = { - .driver_module =THIS_MODULE , .read_raw_multi = &dev_rot_read_raw, .write_raw = &dev_rot_write_raw, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 20/38 iio:dpot: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/iio/potentiometer/ds1803.c | 1 - drivers/iio/potentiometer/max5481.c | 1 - drivers/iio/potentiometer/max5487.c | 1 - drivers/iio/potentiometer/mcp4131.c | 1 - drivers/iio/potentiometer/mcp4531.c | 1 - drivers/iio/potentiometer/tpl0102.c | 1 - 6 files changed, 6 deletions(-)
drivers/iio/potentiometer/ds1803.c +0 -1
@@ -110,7 +110,6 @@ static int ds1803_write_raw(struct iio_dev *indio_dev,static const struct iio_info ds1803_info = { .read_raw = ds1803_read_raw, .write_raw = ds1803_write_raw, - .driver_module =THIS_MODULE , }; static int ds1803_probe(struct i2c_client *client,
drivers/iio/potentiometer/max5481.c +0 -1
@@ -119,7 +119,6 @@ static int max5481_write_raw(struct iio_dev *indio_dev,static const struct iio_info max5481_info = { .read_raw = max5481_read_raw, .write_raw = max5481_write_raw, - .driver_module =THIS_MODULE , };#if defined(CONFIG_OF )
drivers/iio/potentiometer/max5487.c +0 -1
@@ -83,7 +83,6 @@ static int max5487_write_raw(struct iio_dev *indio_dev,static const struct iio_info max5487_info = { .read_raw = max5487_read_raw, .write_raw = max5487_write_raw, - .driver_module =THIS_MODULE , };static int max5487_spi_probe (struct spi_device *spi)
drivers/iio/potentiometer/mcp4131.c +0 -1
@@ -237,7 +237,6 @@ static int mcp4131_write_raw(struct iio_dev *indio_dev,static const struct iio_info mcp4131_info = { .read_raw = mcp4131_read_raw, .write_raw = mcp4131_write_raw, - .driver_module =THIS_MODULE , };static int mcp4131_probe (struct spi_device *spi)
drivers/iio/potentiometer/mcp4531.c +0 -1
@@ -207,7 +207,6 @@ static const struct iio_info mcp4531_info = { .read_raw = mcp4531_read_raw, .read_avail = mcp4531_read_avail, .write_raw = mcp4531_write_raw, - .driver_module = THIS_MODULE, };#ifdef CONFIG_OF
drivers/iio/potentiometer/tpl0102.c +0 -1
@@ -106,7 +106,6 @@ static int tpl0102_write_raw(struct iio_dev *indio_dev,static const struct iio_info tpl0102_info = { .read_raw = tpl0102_read_raw, .write_raw = tpl0102_write_raw, - .driver_module =THIS_MODULE , }; static int tpl0102_probe(struct i2c_client *client,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 21/38 iio:potentiostat:lmp91000 drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/potentiostat/lmp91000.c | 2 -- 1 file changed, 2 deletions(-)
drivers/iio/potentiostat/lmp91000.c +0 -2
@@ -207,7 +207,6 @@ static int lmp91000_read_raw(struct iio_dev *indio_dev, }static const struct iio_info lmp91000_info = { - .driver_module =THIS_MODULE , .read_raw = lmp91000_read_raw, };
@@ -283,7 +282,6 @@ static int lmp91000_buffer_cb(const void *val, void *private) }static const struct iio_trigger_ops lmp91000_trigger_ops = { - .owner =THIS_MODULE , };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 22/38 iio:pressure: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/pressure/abp060mg.c | 1 - drivers/iio/pressure/bmp280-core.c | 1 - drivers/iio/pressure/cros_ec_baro.c | 1 - drivers/iio/pressure/hid-sensor-press.c | 1 - drivers/iio/pressure/hp03.c | 1 - drivers/iio/pressure/hp206c.c | 1 - drivers/iio/pressure/mpl115.c | 1 - drivers/iio/pressure/mpl3115.c | 1 - drivers/iio/pressure/ms5611_core.c | 1 - drivers/iio/pressure/ms5637.c | 1 - drivers/iio/pressure/st_pressure_core.c | 2 -- drivers/iio/pressure/t5403.c | 1 - drivers/iio/pressure/zpa2326.c | 2 -- 13 files changed, 15 deletions(-)
drivers/iio/pressure/abp060mg.c +0 -1
@@ -168,7 +168,6 @@ static int abp060mg_read_raw(struct iio_dev *indio_dev, }static const struct iio_info abp060mg_info = { - .driver_module =THIS_MODULE , .read_raw = abp060mg_read_raw, };
drivers/iio/pressure/bmp280-core.c +0 -1
@@ -546,7 +546,6 @@ static const struct attribute_group bmp280_attrs_group = { };static const struct iio_info bmp280_info = { - .driver_module =THIS_MODULE , .read_raw = &bmp280_read_raw, .write_raw = &bmp280_write_raw, .attrs = &bmp280_attrs_group,
drivers/iio/pressure/cros_ec_baro.c +0 -1
@@ -120,7 +120,6 @@ static int cros_ec_baro_write(struct iio_dev *indio_dev,static const struct iio_info cros_ec_baro_info = { .read_raw = &cros_ec_baro_read, .write_raw = &cros_ec_baro_write, - .driver_module =THIS_MODULE , };static int cros_ec_baro_probe (struct platform_device *pdev)
drivers/iio/pressure/hid-sensor-press.c +0 -1
@@ -160,7 +160,6 @@ static int press_write_raw(struct iio_dev *indio_dev, }static const struct iio_info press_info = { - .driver_module =THIS_MODULE , .read_raw = &press_read_raw, .write_raw = &press_write_raw, };
drivers/iio/pressure/hp03.c +0 -1
@@ -208,7 +208,6 @@ static int hp03_read_raw(struct iio_dev *indio_dev, }static const struct iio_info hp03_info = { - .driver_module =THIS_MODULE , .read_raw = &hp03_read_raw, };
drivers/iio/pressure/hp206c.c +0 -1
@@ -351,7 +351,6 @@ static const struct iio_info hp206c_info = { .attrs = &hp206c_attribute_group, .read_raw = hp206c_read_raw, .write_raw = hp206c_write_raw, - .driver_module = THIS_MODULE, }; static int hp206c_probe(struct i2c_client *client,
drivers/iio/pressure/mpl115.c +0 -1
@@ -144,7 +144,6 @@ static const struct iio_chan_spec mpl115_channels[] = {static const struct iio_info mpl115_info = { .read_raw = &mpl115_read_raw, - .driver_module =THIS_MODULE , }; int mpl115_probe(struct device *dev, const char *name,
drivers/iio/pressure/mpl3115.c +0 -1
@@ -218,7 +218,6 @@ static const struct iio_chan_spec mpl3115_channels[] = {static const struct iio_info mpl3115_info = { .read_raw = &mpl3115_read_raw, - .driver_module =THIS_MODULE , }; static int mpl3115_probe(struct i2c_client *client,
drivers/iio/pressure/ms5611_core.c +0 -1
@@ -384,7 +384,6 @@ static const struct iio_info ms5611_info = { .read_raw = &ms5611_read_raw, .write_raw = &ms5611_write_raw, .attrs = &ms5611_attribute_group, - .driver_module = THIS_MODULE, };static int ms5611_init (struct iio_dev *indio_dev)
drivers/iio/pressure/ms5637.c +0 -1
@@ -124,7 +124,6 @@ static const struct iio_info ms5637_info = { .read_raw = ms5637_read_raw, .write_raw = ms5637_write_raw, .attrs = &ms5637_attribute_group, - .driver_module = THIS_MODULE, }; static int ms5637_probe(struct i2c_client *client,
drivers/iio/pressure/st_pressure_core.c +0 -2
@@ -547,7 +547,6 @@ static const struct attribute_group st_press_attribute_group = { };static const struct iio_info press_info = { - .driver_module =THIS_MODULE , .attrs = &st_press_attribute_group, .read_raw = &st_press_read_raw, .write_raw = &st_press_write_raw,
@@ -556,7 +555,6 @@ static const struct iio_info press_info = {#ifdef CONFIG_IIO_TRIGGER static const struct iio_trigger_ops st_press_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state =ST_PRESS_TRIGGER_SET_STATE , .validate_device = st_sensors_validate_device, };
drivers/iio/pressure/t5403.c +0 -1
@@ -209,7 +209,6 @@ static const struct iio_info t5403_info = { .read_raw = &t5403_read_raw, .write_raw = &t5403_write_raw, .attrs = &t5403_attribute_group, - .driver_module = THIS_MODULE, }; static int t5403_probe(struct i2c_client *client,
drivers/iio/pressure/zpa2326.c +0 -2
@@ -1394,7 +1394,6 @@ static int zpa2326_set_trigger_state(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops zpa2326_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = zpa2326_set_trigger_state, };
@@ -1594,7 +1593,6 @@ static const struct iio_chan_spec zpa2326_channels[] = { };static const struct iio_info zpa2326_info = { - .driver_module =THIS_MODULE , .attrs = &zpa2326_attribute_group, .read_raw = zpa2326_read_raw, .write_raw = zpa2326_write_raw,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 23/38 iio:proximity: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/iio/proximity/as3935.c | 2 -- drivers/iio/proximity/pulsedlight-lidar-lite-v2.c | 1 - drivers/iio/proximity/srf04.c | 1 - drivers/iio/proximity/srf08.c | 1 - drivers/iio/proximity/sx9500.c | 2 -- 5 files changed, 7 deletions(-)
drivers/iio/proximity/as3935.c +0 -2
@@ -197,7 +197,6 @@ static int as3935_read_raw(struct iio_dev *indio_dev, }static const struct iio_info as3935_info = { - .driver_module =THIS_MODULE , .attrs = &as3935_attribute_group, .read_raw = &as3935_read_raw, };
@@ -223,7 +222,6 @@ static irqreturn_t as3935_trigger_handler(int irq, void *private) }static const struct iio_trigger_ops iio_interrupt_trigger_ops = { - .owner =THIS_MODULE , };static void as3935_event_work (struct work_struct *work)
drivers/iio/proximity/pulsedlight-lidar-lite-v2.c +0 -1
@@ -249,7 +249,6 @@ static irqreturn_t lidar_trigger_handler(int irq, void *private) }static const struct iio_info lidar_info = { - .driver_module =THIS_MODULE , .read_raw = lidar_read_raw, };
drivers/iio/proximity/srf04.c +0 -1
@@ -203,7 +203,6 @@ static int srf04_read_raw(struct iio_dev *indio_dev, }static const struct iio_info srf04_iio_info = { - .driver_module =THIS_MODULE , .read_raw = srf04_read_raw, };
drivers/iio/proximity/srf08.c +0 -1
@@ -329,7 +329,6 @@ static const struct iio_chan_spec srf08_channels[] = {static const struct iio_info srf08_info = { .read_raw = srf08_read_raw, .attrs = &srf08_attribute_group, - .driver_module =THIS_MODULE , }; static int srf08_probe(struct i2c_client *client,
drivers/iio/proximity/sx9500.c +0 -2
@@ -615,7 +615,6 @@ static const struct attribute_group sx9500_attribute_group = { };static const struct iio_info sx9500_info = { - .driver_module =THIS_MODULE , .attrs = &sx9500_attribute_group, .read_raw = &sx9500_read_raw, .write_raw = &sx9500_write_raw,
@@ -650,7 +649,6 @@ static int sx9500_set_trigger_state(struct iio_trigger *trig,static const struct iio_trigger_ops sx9500_trigger_ops = { .set_trigger_state = sx9500_set_trigger_state, - .owner =THIS_MODULE , };static irqreturn_t sx9500_trigger_handler (int irq,void *private)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 24/38 iio:temperature: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/iio/temperature/hid-sensor-temperature.c | 1 - drivers/iio/temperature/maxim_thermocouple.c | 1 - drivers/iio/temperature/mlx90614.c | 1 - drivers/iio/temperature/tmp006.c | 1 - drivers/iio/temperature/tmp007.c | 1 - drivers/iio/temperature/tsys01.c | 1 - drivers/iio/temperature/tsys02d.c | 1 - 7 files changed, 7 deletions(-)
drivers/iio/temperature/hid-sensor-temperature.c +0 -1
@@ -123,7 +123,6 @@ static int temperature_write_raw(struct iio_dev *indio_dev, }static const struct iio_info temperature_info = { - .driver_module =THIS_MODULE , .read_raw = &temperature_read_raw, .write_raw = &temperature_write_raw, };
drivers/iio/temperature/maxim_thermocouple.c +0 -1
@@ -208,7 +208,6 @@ static int maxim_thermocouple_read_raw(struct iio_dev *indio_dev, }static const struct iio_info maxim_thermocouple_info = { - .driver_module =THIS_MODULE , .read_raw = maxim_thermocouple_read_raw, };
drivers/iio/temperature/mlx90614.c +0 -1
@@ -400,7 +400,6 @@ static const struct iio_info mlx90614_info = { .write_raw = mlx90614_write_raw, .write_raw_get_fmt = mlx90614_write_raw_get_fmt, .attrs = &mlx90614_attr_group, - .driver_module = THIS_MODULE, };#ifdef CONFIG_PM
drivers/iio/temperature/tmp006.c +0 -1
@@ -179,7 +179,6 @@ static const struct iio_info tmp006_info = { .read_raw = tmp006_read_raw, .write_raw = tmp006_write_raw, .attrs = &tmp006_attribute_group, - .driver_module = THIS_MODULE, };static bool tmp006_check_identification (struct i2c_client *client)
drivers/iio/temperature/tmp007.c +0 -1
@@ -426,7 +426,6 @@ static const struct iio_info tmp007_info = { .read_event_value = tmp007_read_thresh, .write_event_value = tmp007_write_thresh, .attrs = &tmp007_attribute_group, - .driver_module = THIS_MODULE, };static bool tmp007_identify (struct i2c_client *client)
drivers/iio/temperature/tsys01.c +0 -1
@@ -111,7 +111,6 @@ static const struct iio_chan_spec tsys01_channels[] = {static const struct iio_info tsys01_info = { .read_raw = tsys01_read_raw, - .driver_module =THIS_MODULE , };static bool tsys01_crc_valid (u16 *n_prom)
drivers/iio/temperature/tsys02d.c +0 -1
@@ -120,7 +120,6 @@ static const struct iio_info tsys02d_info = { .read_raw = tsys02d_read_raw, .write_raw = tsys02d_write_raw, .attrs = &tsys02d_attribute_group, - .driver_module = THIS_MODULE, }; static int tsys02d_probe(struct i2c_client *client,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 25/38 iio:triggers: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
Note that stm32-timer-trigger has expanded rather beyond triggers (to include encoder input counting for example) and hence has an iio_info structure.
--- drivers/iio/trigger/iio-trig-hrtimer.c | 1 - drivers/iio/trigger/iio-trig-interrupt.c | 1 - drivers/iio/trigger/iio-trig-loop.c | 1 - drivers/iio/trigger/iio-trig-sysfs.c | 1 - drivers/iio/trigger/stm32-timer-trigger.c | 2 -- 5 files changed, 6 deletions(-)
drivers/iio/trigger/iio-trig-hrtimer.c +0 -1
@@ -114,7 +114,6 @@ static int iio_trig_hrtimer_set_state(struct iio_trigger *trig, bool state) }static const struct iio_trigger_ops iio_hrtimer_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = iio_trig_hrtimer_set_state, };
drivers/iio/trigger/iio-trig-interrupt.c +0 -1
@@ -29,7 +29,6 @@ static irqreturn_t iio_interrupt_trigger_poll(int irq, void *private) }static const struct iio_trigger_ops iio_interrupt_trigger_ops = { - .owner =THIS_MODULE , };static int iio_interrupt_trigger_probe (struct platform_device *pdev)
drivers/iio/trigger/iio-trig-loop.c +0 -1
@@ -74,7 +74,6 @@ static int iio_loop_trigger_set_state(struct iio_trigger *trig, bool state)static const struct iio_trigger_ops iio_loop_trigger_ops = { .set_trigger_state = iio_loop_trigger_set_state, - .owner =THIS_MODULE , };static struct iio_sw_trigger *iio_trig_loop_probe (const char *name)
drivers/iio/trigger/iio-trig-sysfs.c +0 -1
@@ -127,7 +127,6 @@ static const struct attribute_group *iio_sysfs_trigger_attr_groups[] = { };static const struct iio_trigger_ops iio_sysfs_trigger_ops = { - .owner =THIS_MODULE , };static int iio_sysfs_trigger_probe (int id)
drivers/iio/trigger/stm32-timer-trigger.c +0 -2
@@ -318,7 +318,6 @@ static const struct attribute_group *stm32_trigger_attr_groups[] = { };static const struct iio_trigger_ops timer_trigger_ops = { - .owner =THIS_MODULE , };static int stm32_setup_iio_triggers (struct stm32_timer_trigger *priv)
@@ -418,7 +417,6 @@ static int stm32_counter_write_raw(struct iio_dev *indio_dev, }static const struct iio_info stm32_trigger_info = { - .driver_module =THIS_MODULE , .read_raw = stm32_counter_read_raw, .write_raw = stm32_counter_write_raw };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 26/38 staging:iio:accel: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThe equivalent this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/accel/adis16201.c | 1 - drivers/staging/iio/accel/adis16203.c | 1 - drivers/staging/iio/accel/adis16209.c | 1 - drivers/staging/iio/accel/adis16240.c | 1 - 4 files changed, 4 deletions(-)
drivers/staging/iio/accel/adis16201.c +0 -1
@@ -284,7 +284,6 @@ static const struct iio_info adis16201_info = { .read_raw = adis16201_read_raw, .write_raw = adis16201_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static const char *const adis16201_status_error_msgs[] = {
drivers/staging/iio/accel/adis16203.c +0 -1
@@ -232,7 +232,6 @@ static const struct iio_info adis16203_info = { .read_raw = adis16203_read_raw, .write_raw = adis16203_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static const char *const adis16203_status_error_msgs[] = {
drivers/staging/iio/accel/adis16209.c +0 -1
@@ -285,7 +285,6 @@ static const struct iio_info adis16209_info = { .read_raw = adis16209_read_raw, .write_raw = adis16209_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static const char *const adis16209_status_error_msgs[] = {
drivers/staging/iio/accel/adis16240.c +0 -1
@@ -361,7 +361,6 @@ static const struct iio_info adis16240_info = { .read_raw = adis16240_read_raw, .write_raw = adis16240_write_raw, .update_scan_mode = adis_update_scan_mode, - .driver_module = THIS_MODULE, };static const char *const adis16240_status_error_msgs[] = {
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 27/38 staging:iio:adc: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure element will shortly go away.
--- drivers/staging/iio/adc/ad7192.c | 2 -- drivers/staging/iio/adc/ad7280a.c | 1 - drivers/staging/iio/adc/ad7606.c | 4 ---- drivers/staging/iio/adc/ad7780.c | 1 - drivers/staging/iio/adc/ad7816.c | 1 - drivers/staging/iio/addac/adt7316.c | 2 -- 6 files changed, 11 deletions(-)
drivers/staging/iio/adc/ad7192.c +0 -2
@@ -569,7 +569,6 @@ static const struct iio_info ad7192_info = { .write_raw_get_fmt = ad7192_write_raw_get_fmt, .attrs = &ad7192_attribute_group, .validate_trigger = ad_sd_validate_trigger, - .driver_module = THIS_MODULE, };static const struct iio_info ad7195_info = {
@@ -578,7 +577,6 @@ static const struct iio_info ad7195_info = { .write_raw_get_fmt = ad7192_write_raw_get_fmt, .attrs = &ad7195_attribute_group, .validate_trigger = ad_sd_validate_trigger, - .driver_module = THIS_MODULE, };static const struct iio_chan_spec ad7192_channels[] = {
drivers/staging/iio/adc/ad7280a.c +0 -1
@@ -823,7 +823,6 @@ static const struct iio_info ad7280_info = { .read_raw = ad7280_read_raw, .event_attrs = &ad7280_event_attrs_group, .attrs = &ad7280_attrs_group, - .driver_module = THIS_MODULE, };static const struct ad7280_platform_data ad7793_default_pdata = {
drivers/staging/iio/adc/ad7606.c +0 -4
@@ -373,26 +373,22 @@ static irqreturn_t ad7606_interrupt(int irq, void *dev_id) };static const struct iio_info ad7606_info_no_os_or_range = { - .driver_module =THIS_MODULE , .read_raw = &ad7606_read_raw, };static const struct iio_info ad7606_info_os_and_range = { - .driver_module =THIS_MODULE , .read_raw = &ad7606_read_raw, .write_raw = &ad7606_write_raw, .attrs = &ad7606_attribute_group_os_and_range, };static const struct iio_info ad7606_info_os = { - .driver_module =THIS_MODULE , .read_raw = &ad7606_read_raw, .write_raw = &ad7606_write_raw, .attrs = &ad7606_attribute_group_os, };static const struct iio_info ad7606_info_range = { - .driver_module =THIS_MODULE , .read_raw = &ad7606_read_raw, .write_raw = &ad7606_write_raw, .attrs = &ad7606_attribute_group_range,
drivers/staging/iio/adc/ad7780.c +0 -1
@@ -155,7 +155,6 @@ static const struct ad7780_chip_info ad7780_chip_info_tbl[] = {static const struct iio_info ad7780_info = { .read_raw = ad7780_read_raw, - .driver_module =THIS_MODULE , };static int ad7780_probe (struct spi_device *spi)
drivers/staging/iio/adc/ad7816.c +0 -1
@@ -335,7 +335,6 @@ static const struct attribute_group ad7816_event_attribute_group = {static const struct iio_info ad7816_info = { .attrs = &ad7816_attribute_group, .event_attrs = &ad7816_event_attribute_group, - .driver_module =THIS_MODULE , };/*
drivers/staging/iio/addac/adt7316.c +0 -2
@@ -2087,13 +2087,11 @@ EXPORT_SYMBOL_GPL(adt7316_pm_ops);static const struct iio_info adt7316_info = { .attrs = &adt7316_attribute_group, .event_attrs = &adt7316_event_attribute_group, - .driver_module =THIS_MODULE , };static const struct iio_info adt7516_info = { .attrs = &adt7516_attribute_group, .event_attrs = &adt7516_event_attribute_group, - .driver_module =THIS_MODULE , };/*
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 28/38 staging:iio:cdc: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/cdc/ad7150.c | 1 - drivers/staging/iio/cdc/ad7152.c | 1 - drivers/staging/iio/cdc/ad7746.c | 1 - 3 files changed, 3 deletions(-)
drivers/staging/iio/cdc/ad7150.c +0 -1
@@ -569,7 +569,6 @@ static const struct attribute_group ad7150_event_attribute_group = {static const struct iio_info ad7150_info = { .event_attrs = &ad7150_event_attribute_group, - .driver_module =THIS_MODULE , .read_raw = &ad7150_read_raw, .read_event_config = &ad7150_read_event_config, .write_event_config = &ad7150_write_event_config,
drivers/staging/iio/cdc/ad7152.c +0 -1
@@ -445,7 +445,6 @@ static const struct iio_info ad7152_info = { .read_raw = ad7152_read_raw, .write_raw = ad7152_write_raw, .write_raw_get_fmt = ad7152_write_raw_get_fmt, - .driver_module = THIS_MODULE, };static const struct iio_chan_spec ad7152_channels[] = {
drivers/staging/iio/cdc/ad7746.c +0 -1
@@ -667,7 +667,6 @@ static const struct iio_info ad7746_info = { .attrs = &ad7746_attribute_group, .read_raw = ad7746_read_raw, .write_raw = ad7746_write_raw, - .driver_module = THIS_MODULE, };/*
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 29/38 staging:iio:frequency: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/frequency/ad9832.c | 1 - drivers/staging/iio/frequency/ad9834.c | 2 -- 2 files changed, 3 deletions(-)
drivers/staging/iio/frequency/ad9832.c +0 -1
@@ -290,7 +290,6 @@ static const struct attribute_group ad9832_attribute_group = {static const struct iio_info ad9832_info = { .attrs = &ad9832_attribute_group, - .driver_module =THIS_MODULE , };static int ad9832_probe (struct spi_device *spi)
drivers/staging/iio/frequency/ad9834.c +0 -2
@@ -381,12 +381,10 @@ static const struct attribute_group ad9833_attribute_group = {static const struct iio_info ad9834_info = { .attrs = &ad9834_attribute_group, - .driver_module =THIS_MODULE , };static const struct iio_info ad9833_info = { .attrs = &ad9833_attribute_group, - .driver_module =THIS_MODULE , };static int ad9834_probe (struct spi_device *spi)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 30/38 staging:iio:gyro:adis16060 drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/gyro/adis16060_core.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/iio/gyro/adis16060_core.c +0 -1
@@ -103,7 +103,6 @@ static int adis16060_read_raw(struct iio_dev *indio_dev,static const struct iio_info adis16060_info = { .read_raw = adis16060_read_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec adis16060_channels[] = {
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 31/38 staging:iio:ad5933: drop assign iio_info.driver_module
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/impedance-analyzer/ad5933.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/iio/impedance-analyzer/ad5933.c +0 -1
@@ -575,7 +575,6 @@ static int ad5933_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad5933_info = { .read_raw = ad5933_read_raw, .attrs = &ad5933_attribute_group, - .driver_module =THIS_MODULE , };static int ad5933_ring_preenable (struct iio_dev *indio_dev)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 32/38 staging:iio:meter: drop assign iio_info.driver_module and iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of both of these are now done via macro magic when the relevant register calls are made. The actual structure elements will shortly go away.
--- drivers/staging/iio/meter/ade7753.c | 1 - drivers/staging/iio/meter/ade7754.c | 1 - drivers/staging/iio/meter/ade7758_core.c | 1 - drivers/staging/iio/meter/ade7758_trigger.c | 1 - drivers/staging/iio/meter/ade7759.c | 1 - drivers/staging/iio/meter/ade7854.c | 1 - 6 files changed, 6 deletions(-)
drivers/staging/iio/meter/ade7753.c +0 -1
@@ -561,7 +561,6 @@ static const struct attribute_group ade7753_attribute_group = {static const struct iio_info ade7753_info = { .attrs = &ade7753_attribute_group, - .driver_module =THIS_MODULE , };static int ade7753_probe (struct spi_device *spi)
drivers/staging/iio/meter/ade7754.c +0 -1
@@ -601,7 +601,6 @@ static const struct attribute_group ade7754_attribute_group = {static const struct iio_info ade7754_info = { .attrs = &ade7754_attribute_group, - .driver_module =THIS_MODULE , };static int ade7754_probe (struct spi_device *spi)
drivers/staging/iio/meter/ade7758_core.c +0 -1
@@ -827,7 +827,6 @@ static const struct iio_info ade7758_info = { .attrs = &ade7758_attribute_group, .read_raw = &ade7758_read_raw, .write_raw = &ade7758_write_raw, - .driver_module = THIS_MODULE, };static int ade7758_probe (struct spi_device *spi)
drivers/staging/iio/meter/ade7758_trigger.c +0 -1
@@ -53,7 +53,6 @@ static int ade7758_trig_try_reen(struct iio_trigger *trig) }static const struct iio_trigger_ops ade7758_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = &ade7758_data_rdy_trigger_set_state, .try_reenable = &ade7758_trig_try_reen, };
drivers/staging/iio/meter/ade7759.c +0 -1
@@ -493,7 +493,6 @@ static const struct attribute_group ade7759_attribute_group = {static const struct iio_info ade7759_info = { .attrs = &ade7759_attribute_group, - .driver_module =THIS_MODULE , };static int ade7759_probe (struct spi_device *spi)
drivers/staging/iio/meter/ade7854.c +0 -1
@@ -530,7 +530,6 @@ static const struct attribute_group ade7854_attribute_group = {static const struct iio_info ade7854_info = { .attrs = &ade7854_attribute_group, - .driver_module =THIS_MODULE , };int ade7854_probe (struct iio_dev *indio_dev,struct device *dev)
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 33/38 iio:resolver: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThe equivalent is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/resolver/ad2s1200.c | 1 - drivers/staging/iio/resolver/ad2s1210.c | 1 - drivers/staging/iio/resolver/ad2s90.c | 1 - 3 files changed, 3 deletions(-)
drivers/staging/iio/resolver/ad2s1200.c +0 -1
@@ -98,7 +98,6 @@ static const struct iio_chan_spec ad2s1200_channels[] = {static const struct iio_info ad2s1200_info = { .read_raw = ad2s1200_read_raw, - .driver_module =THIS_MODULE , };static int ad2s1200_probe (struct spi_device *spi)
drivers/staging/iio/resolver/ad2s1210.c +0 -1
@@ -638,7 +638,6 @@ static int ad2s1210_initial(struct ad2s1210_state *st)static const struct iio_info ad2s1210_info = { .read_raw = ad2s1210_read_raw, .attrs = &ad2s1210_attribute_group, - .driver_module =THIS_MODULE , };static int ad2s1210_setup_gpios (struct ad2s1210_state *st)
drivers/staging/iio/resolver/ad2s90.c +0 -1
@@ -48,7 +48,6 @@ static int ad2s90_read_raw(struct iio_dev *indio_dev,static const struct iio_info ad2s90_info = { .read_raw = ad2s90_read_raw, - .driver_module =THIS_MODULE , };static const struct iio_chan_spec ad2s90_chan = {
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 34/38 iio:adc: drop assignment of iio_trigger_ops.owner
In reply to Jonathan CameronThe equivalent of this is now done via macro magic when the relevant register call is made. The actual structure elements will shortly go away.
--- drivers/staging/iio/trigger/iio-trig-bfin-timer.c | 1 - 1 file changed, 1 deletion(-)
drivers/staging/iio/trigger/iio-trig-bfin-timer.c +0 -1
@@ -172,7 +172,6 @@ static int iio_bfin_tmr_get_number(int irq) }static const struct iio_trigger_ops iio_bfin_tmr_trigger_ops = { - .owner =THIS_MODULE , .set_trigger_state = iio_bfin_tmr_set_state, };
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 35/38 staging:iio:light:tsl2x7x drop assignment of driver_module
In reply to Jonathan CameronThe equivalent is now done via macro magic in the register call.
Note this is the only case not found by the coccinelle script suggesting that perhaps that script needs to be a little more clever!
--- drivers/staging/iio/light/tsl2x7x.c | 5 ----- 1 file changed, 5 deletions(-)
drivers/staging/iio/light/tsl2x7x.c +0 -5
@@ -1681,7 +1681,6 @@ static const struct iio_info tsl2X7X_device_info[] = { [ALS] = { .attrs = &tsl2X7X_device_attr_group_tbl[ALS], .event_attrs = &tsl2X7X_event_attr_group_tbl[ALS], - .driver_module = THIS_MODULE, .read_raw = &tsl2x7x_read_raw, .write_raw = &tsl2x7x_write_raw, .read_event_value = &tsl2x7x_read_thresh,
@@ -1692,7 +1691,6 @@ static const struct iio_info tsl2X7X_device_info[] = { [PRX] = { .attrs = &tsl2X7X_device_attr_group_tbl[PRX], .event_attrs = &tsl2X7X_event_attr_group_tbl[PRX], - .driver_module = THIS_MODULE, .read_raw = &tsl2x7x_read_raw, .write_raw = &tsl2x7x_write_raw, .read_event_value = &tsl2x7x_read_thresh,
@@ -1703,7 +1701,6 @@ static const struct iio_info tsl2X7X_device_info[] = { [ALSPRX] = { .attrs = &tsl2X7X_device_attr_group_tbl[ALSPRX], .event_attrs = &tsl2X7X_event_attr_group_tbl[ALSPRX], - .driver_module = THIS_MODULE, .read_raw = &tsl2x7x_read_raw, .write_raw = &tsl2x7x_write_raw, .read_event_value = &tsl2x7x_read_thresh,
@@ -1714,7 +1711,6 @@ static const struct iio_info tsl2X7X_device_info[] = { [PRX2] = { .attrs = &tsl2X7X_device_attr_group_tbl[PRX2], .event_attrs = &tsl2X7X_event_attr_group_tbl[PRX], - .driver_module = THIS_MODULE, .read_raw = &tsl2x7x_read_raw, .write_raw = &tsl2x7x_write_raw, .read_event_value = &tsl2x7x_read_thresh,
@@ -1725,7 +1721,6 @@ static const struct iio_info tsl2X7X_device_info[] = { [ALSPRX2] = { .attrs = &tsl2X7X_device_attr_group_tbl[ALSPRX2], .event_attrs = &tsl2X7X_event_attr_group_tbl[ALSPRX], - .driver_module = THIS_MODULE, .read_raw = &tsl2x7x_read_raw, .write_raw = &tsl2x7x_write_raw, .read_event_value = &tsl2x7x_read_thresh,
Signature · 1 line
2.13.0
Jonathan Cameron
maintainerPATCH 36/38 input: tsc2007 - drop the driver_module assignment in iio interface.
In reply to Jonathan CameronThis is now handled via some macro magic during the register. The field in iio_info will be removed shortly.
--- drivers/input/touchscreen/tsc2007_iio.c | 1 - 1 file changed, 1 deletion(-)
drivers/input/touchscreen/tsc2007_iio.c +0 -1
@@ -104,7 +104,6 @@ static int tsc2007_read_raw(struct iio_dev *indio_dev,static const struct iio_info tsc2007_iio_info = { .read_raw = tsc2007_read_raw, - .driver_module =THIS_MODULE , };int tsc2007_iio_configure (struct tsc2007 *ts)
Signature · 1 line
2.13.0
Re: [PATCH 36/38] input: tsc2007 - drop the driver_module assignment in iio interface.
Quoted 6 lines · Jonathan Cameron
This is now handled via some macro magic during the register. The field in
iio_infowill be removed shortly.Cc Linux Input <[email protected]>Cc Dmitry Torokhov <[email protected]>Signed-off-by Jonathan Cameron <[email protected]>
It sounds the patch needs something from your tree so please merge it though there.
Quoted 19 lines
--- drivers/input/touchscreen/tsc2007_iio.c | 1 - 1 file changed, 1 deletion(-)drivers/input/touchscreen/tsc2007_iio.c +0
-1@@ -104,7 +104,6 @@ static int tsc2007_read_raw(struct iio_dev *indio_dev,static const struct iio_info tsc2007_iio_info = { .read_raw = tsc2007_read_raw, - .driver_module =THIS_MODULE , };int tsc2007_iio_configure (struct tsc2007 *ts)Signature · 1 line
2.13.0
Signature · 1 line
Dmitry
Jonathan Cameron
maintainerPATCH 37/38 platform/x86: toshiba_acpi: drop assignment of iio_info.driver_module
In reply to Jonathan CameronThis is now handled by use of a macro for device registration. The field in iio_info will be going away shortly as it is no longer used.
--- drivers/platform/x86/toshiba_acpi.c | 1 - 1 file changed, 1 deletion(-)
drivers/platform/x86/toshiba_acpi.c +0 -1
@@ -2515,7 +2515,6 @@ static const struct iio_chan_spec toshiba_iio_accel_channels[] = { };static const struct iio_info toshiba_iio_accel_info = { - .driver_module =THIS_MODULE , .read_raw = &toshiba_iio_accel_read_raw, };
Signature · 1 line
2.13.0
Re: [PATCH 37/38] platform/x86: toshiba_acpi: drop assignment of iio_info.driver_module
Quoted 5 lines · Jonathan Cameron
This is now handled by use of a macro for device registration. The field in
iio_infowill be going away shortly as it is no longer used.Cc Azael Avalos <[email protected]>Cc <[email protected]>
Quoted 20 lines
Signed-off-by Jonathan Cameron <[email protected]>--- drivers/platform/x86/toshiba_acpi.c | 1 - 1 file changed, 1 deletion(-)drivers/platform/x86/toshiba_acpi.c +0
-2@@ -2515,7 +2515,6 @@ static const struct iio_chan_spec toshiba_iio_accel_channels[] = { };static const struct iio_info toshiba_iio_accel_info = { - .driver_module =THIS_MODULE , .read_raw = &toshiba_iio_accel_read_raw, }; --2.13.0
Signature · 2 lines
With Best Regards, Andy Shevchenko
Re: [PATCH 37/38] platform/x86: toshiba_acpi: drop assignment of iio_info.driver_module
In reply to Jonathan CameronSorry for being this late, been a bit busy.
2017-05-29 9:51 GMT-06:00 Jonathan Cameron <[email protected]>:
Quoted 5 lines
This is now handled by use of a macro for device registration. The field in
iio_infowill be going away shortly as it is no longer used.Cc Azael Avalos <[email protected]>Cc <[email protected]>
Quoted 20 lines
Signed-off-by Jonathan Cameron <[email protected]>--- drivers/platform/x86/toshiba_acpi.c | 1 - 1 file changed, 1 deletion(-)drivers/platform/x86/toshiba_acpi.c +0
-2@@ -2515,7 +2515,6 @@ static const struct iio_chan_spec toshiba_iio_accel_channels[] = { };static const struct iio_info toshiba_iio_accel_info = { - .driver_module =THIS_MODULE , .read_raw = &toshiba_iio_accel_read_raw, }; --2.13.0
Signature · 1 line
-- El mundo apesta y vosotros apestais tambien --
Jonathan Cameron
maintainerRe: [PATCH 37/38] platform/x86: toshiba_acpi: drop assignment of iio_info.driver_module
Quoted 1 line · On Wed, 7 Jun 2017 08:53:09 -0600 Azael Avalos <[email protected]> wrote:
Sorry for being this late, been a bit busy.
That's fine, I'm still waiting for reviews on the two core patches at the start of the series :(
Trying to avoid playing the maintainer game and applying loads of my own patches without review!
Thanks,
Jonathan
Quoted 33 lines
2017-05-29 9:51 GMT-06:00 Jonathan Cameron <[email protected]>:
Quoted 5 lines
This is now handled by use of a macro for device registration. The field in
iio_infowill be going away shortly as it is no longer used.Cc Azael Avalos <[email protected]>Cc <[email protected]>Acked-by Azael Avalos <[email protected]>Quoted 20 lines
Signed-off-by Jonathan Cameron <[email protected]>--- drivers/platform/x86/toshiba_acpi.c | 1 - 1 file changed, 1 deletion(-)drivers/platform/x86/toshiba_acpi.c +0
-2@@ -2515,7 +2515,6 @@ static const struct iio_chan_spec toshiba_iio_accel_channels[] = { };static const struct iio_info toshiba_iio_accel_info = { - .driver_module =THIS_MODULE , .read_raw = &toshiba_iio_accel_read_raw, }; --2.13.0
Jonathan Cameron
maintainerPATCH 38/38 iio: drop iio_info.driver_module and iio_trigger_ops.owner.
In reply to Jonathan CameronThe equivalents are now assigned automatically in the relevant registration calls and so are not needed in these operations structures.
--- include/linux/iio/iio.h | 3 --- include/linux/iio/trigger.h | 1 - 2 files changed, 4 deletions(-)
include/linux/iio/iio.h +0 -3
@@ -363,8 +363,6 @@ struct iio_dev;/** * struct iio_info - constant information about device -* @driver_module: module structure used to ensure correct -* ownership of chrdevs etc * @event_attrs: event control attributes * @attrs: general purpose device attributes * @read_raw: function to request a value from the device.
@@ -419,7 +417,6 @@ struct iio_dev;* were flushed and there was an error. **/ struct iio_info { -struct module *driver_module;const struct attribute_group *event_attrs;const struct attribute_group *attrs;
include/linux/iio/trigger.h +0 -1
@@ -34,7 +34,6 @@ struct iio_trigger;* instances of a given device. **/ struct iio_trigger_ops { -struct module *owner;int (*set_trigger_state)(struct iio_trigger *trig,bool state);int (*try_reenable)(struct iio_trigger *trig); int (*validate_device)(struct iio_trigger *trig,
Signature · 1 line
2.13.0
Re: [PATCH 38/38] iio: drop iio_info.driver_module and iio_trigger_ops.owner.
include/linux/iio/trigger.h struct iio_trigger;
Quoted 5 lines · Jonathan Cameron
include/linux/iio/trigger.h +0
-0@@ -34,7 +34,6 @@ struct iio_trigger;
Update to the kernel-doc is missing here.
Quoted 8 lines
include/linux/iio/trigger.h +0
-1* instances of a given device. **/ struct iio_trigger_ops { -struct module *owner;int (*set_trigger_state)(struct iio_trigger *trig,bool state);int (*try_reenable)(struct iio_trigger *trig); int (*validate_device)(struct iio_trigger *trig,
Jonathan Cameron
maintainerRe: [PATCH 38/38] iio: drop iio_info.driver_module and iio_trigger_ops.owner.
Quoted 8 lines · On Mon, 12 Jun 2017 18:16:56 +0200 Lars-Peter Clausen <[email protected]> wrote:
include/linux/iio/trigger.h struct iio_trigger;
Quoted 5 lines · Jonathan Cameron
include/linux/iio/trigger.h +0
-0@@ -34,7 +34,6 @@ struct iio_trigger;Update to the kernel-doc is missing here.
Just so I don't forget. This patch also needs to remove the bit of code that insists there is an iio_trigger_ops so that the owner field can be read.
Will do a new version, perhaps tomorrow.
Thanks,
Jonathan
Quoted 10 lines
Quoted 9 lines
include/linux/iio/trigger.h +0
-1* instances of a given device. **/ struct iio_trigger_ops { -struct module *owner;int (*set_trigger_state)(struct iio_trigger *trig,bool state);int (*try_reenable)(struct iio_trigger *trig); int (*validate_device)(struct iio_trigger *trig,