Skip to content
This repository has been archived by the owner on Jan 8, 2024. It is now read-only.

Commit

Permalink
iio:accel:adxl313: Move exports into IIO_ADXL313 namespace
Browse files Browse the repository at this point in the history
In order 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.

Signed-off-by: Jonathan Cameron <[email protected]>
Cc: Lucas Stankus <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
(cherry picked from commit fa4df5a)
  • Loading branch information
jic23 authored and nunojsa committed Apr 11, 2022
1 parent de84628 commit 6b62b86
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
6 changes: 3 additions & 3 deletions drivers/iio/accel/adxl313_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const struct regmap_access_table adxl313_readable_regs_table = {
.yes_ranges = adxl313_readable_reg_range,
.n_yes_ranges = ARRAY_SIZE(adxl313_readable_reg_range),
};
EXPORT_SYMBOL_GPL(adxl313_readable_regs_table);
EXPORT_SYMBOL_NS_GPL(adxl313_readable_regs_table, IIO_ADXL313);

static const struct regmap_range adxl313_writable_reg_range[] = {
regmap_reg_range(ADXL313_REG_SOFT_RESET, ADXL313_REG_SOFT_RESET),
Expand All @@ -41,7 +41,7 @@ const struct regmap_access_table adxl313_writable_regs_table = {
.yes_ranges = adxl313_writable_reg_range,
.n_yes_ranges = ARRAY_SIZE(adxl313_writable_reg_range),
};
EXPORT_SYMBOL_GPL(adxl313_writable_regs_table);
EXPORT_SYMBOL_NS_GPL(adxl313_writable_regs_table, IIO_ADXL313);

struct adxl313_data {
struct regmap *regmap;
Expand Down Expand Up @@ -325,7 +325,7 @@ int adxl313_core_probe(struct device *dev,

return devm_iio_device_register(dev, indio_dev);
}
EXPORT_SYMBOL_GPL(adxl313_core_probe);
EXPORT_SYMBOL_NS_GPL(adxl313_core_probe, IIO_ADXL313);

MODULE_AUTHOR("Lucas Stankus <[email protected]>");
MODULE_DESCRIPTION("ADXL313 3-Axis Digital Accelerometer core driver");
Expand Down
1 change: 1 addition & 0 deletions drivers/iio/accel/adxl313_i2c.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,4 @@ module_i2c_driver(adxl313_i2c_driver);
MODULE_AUTHOR("Lucas Stankus <[email protected]>");
MODULE_DESCRIPTION("ADXL313 3-Axis Digital Accelerometer I2C driver");
MODULE_LICENSE("GPL v2");
MODULE_IMPORT_NS(IIO_ADXL313);
1 change: 1 addition & 0 deletions drivers/iio/accel/adxl313_spi.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,3 +90,4 @@ module_spi_driver(adxl313_spi_driver);
MODULE_AUTHOR("Lucas Stankus <[email protected]>");
MODULE_DESCRIPTION("ADXL313 3-Axis Digital Accelerometer SPI driver");
MODULE_LICENSE("GPL v2");
MODULE_IMPORT_NS(IIO_ADXL313);

0 comments on commit 6b62b86

Please sign in to comment.