summaryrefslogtreecommitdiffstats
path: root/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c
diff options
context:
space:
mode:
authorJonathan Cameron <Jonathan.Cameron@huawei.com>2022-06-04 17:12:23 +0100
committerJonathan Cameron <Jonathan.Cameron@huawei.com>2022-06-15 22:07:09 +0100
commit2b059449b5a3d24cc3ce760f90a15a0e3052af25 (patch)
tree8263ea22c55bd3330e0625dccef3ac985333a175 /drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c
parentacc416ff7d405d9d3a8c90b3a78a0fb87f2979eb (diff)
downloadlinux-stable-2b059449b5a3d24cc3ce760f90a15a0e3052af25.tar.gz
linux-stable-2b059449b5a3d24cc3ce760f90a15a0e3052af25.tar.bz2
linux-stable-2b059449b5a3d24cc3ce760f90a15a0e3052af25.zip
iio: imu: lsm6dsx: Move exported symbols to the IIO_LSM6DSX namespace
Avoid unnecessary pollution of the global symbol namespace by moving library functions in to a specific namespace and import that into the drivers that make use of the functions. For more info: https://lwn.net/Articles/760045/ Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20220220181522.541718-9-jic23@kernel.org Acked-by: Lorenzo Bianconi <lorenzo@kernel.org> Link: https://lore.kernel.org/r/20220604161223.461847-6-jic23@kernel.org
Diffstat (limited to 'drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c')
-rw-r--r--drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c
index 9e4aa5c1c8d6..6b268f1c5fc3 100644
--- a/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c
+++ b/drivers/iio/imu/st_lsm6dsx/st_lsm6dsx_core.c
@@ -2289,7 +2289,7 @@ int st_lsm6dsx_probe(struct device *dev, int irq, int hw_id,
return 0;
}
-EXPORT_SYMBOL(st_lsm6dsx_probe);
+EXPORT_SYMBOL_NS(st_lsm6dsx_probe, IIO_LSM6DSX);
static int st_lsm6dsx_suspend(struct device *dev)
{
@@ -2366,8 +2366,8 @@ static int st_lsm6dsx_resume(struct device *dev)
return err;
}
-EXPORT_SIMPLE_DEV_PM_OPS(st_lsm6dsx_pm_ops, st_lsm6dsx_suspend,
- st_lsm6dsx_resume);
+EXPORT_NS_SIMPLE_DEV_PM_OPS(st_lsm6dsx_pm_ops, st_lsm6dsx_suspend,
+ st_lsm6dsx_resume, IIO_LSM6DSX);
MODULE_AUTHOR("Lorenzo Bianconi <lorenzo.bianconi@st.com>");
MODULE_AUTHOR("Denis Ciocca <denis.ciocca@st.com>");