Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

iio:accel:adxl372: Move exports into IIO_ADXL372 namespace

To avoid unnecessary pollution of the global symbol namespace move the
driver core exports into their own namespace and import that into the two
bus modules.

For more info see https://lwn.net/Articles/760045/

Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Link: https://lore.kernel.org/r/20220116180535.2367780-9-jic23@kernel.org

+4 -2
+2 -2
drivers/iio/accel/adxl372.c
··· 1176 1176 { 1177 1177 return (reg == ADXL372_FIFO_DATA); 1178 1178 } 1179 - EXPORT_SYMBOL_GPL(adxl372_readable_noinc_reg); 1179 + EXPORT_SYMBOL_NS_GPL(adxl372_readable_noinc_reg, IIO_ADXL372); 1180 1180 1181 1181 int adxl372_probe(struct device *dev, struct regmap *regmap, 1182 1182 int irq, const char *name) ··· 1260 1260 1261 1261 return devm_iio_device_register(dev, indio_dev); 1262 1262 } 1263 - EXPORT_SYMBOL_GPL(adxl372_probe); 1263 + EXPORT_SYMBOL_NS_GPL(adxl372_probe, IIO_ADXL372); 1264 1264 1265 1265 MODULE_AUTHOR("Stefan Popa <stefan.popa@analog.com>"); 1266 1266 MODULE_DESCRIPTION("Analog Devices ADXL372 3-axis accelerometer driver");
+1
drivers/iio/accel/adxl372_i2c.c
··· 67 67 MODULE_AUTHOR("Stefan Popa <stefan.popa@analog.com>"); 68 68 MODULE_DESCRIPTION("Analog Devices ADXL372 3-axis accelerometer I2C driver"); 69 69 MODULE_LICENSE("GPL"); 70 + MODULE_IMPORT_NS(IIO_ADXL372);
+1
drivers/iio/accel/adxl372_spi.c
··· 59 59 MODULE_AUTHOR("Stefan Popa <stefan.popa@analog.com>"); 60 60 MODULE_DESCRIPTION("Analog Devices ADXL372 3-axis accelerometer SPI driver"); 61 61 MODULE_LICENSE("GPL"); 62 + MODULE_IMPORT_NS(IIO_ADXL372);