mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-13 14:24:11 +08:00
iio:imu:adis: Move exports into IIO_ADISLIB namespace
[ Upstream commit6c9304d6af
] In order to avoid unneessary pollution of the global symbol namespace move the common/library functions into a specific namespace and import that into the various specific device drivers that use them. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Lars-Peter Clausen <lars@metafoo.de> Cc: Song Bao Hua (Barry Song) <song.bao.hua@hisilicon.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20220130205701.334592-9-jic23@kernel.org Stable-dep-of:99c05e4283
("iio: adis: add '__adis_enable_irq()' implementation") Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
83e321a2ec
commit
3feb8fd8bf
@ -304,3 +304,4 @@ MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16201 Dual-Axis Digital Inclinometer and Accelerometer");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_ALIAS("spi:adis16201");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -314,3 +314,4 @@ MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16209 Dual-Axis Digital Inclinometer and Accelerometer");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_ALIAS("spi:adis16209");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -599,3 +599,4 @@ module_spi_driver(adis16136_driver);
|
||||
MODULE_AUTHOR("Lars-Peter Clausen <lars@metafoo.de>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16133/ADIS16135/ADIS16136 gyroscope driver");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -438,3 +438,4 @@ module_spi_driver(adis16260_driver);
|
||||
MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16260/5 Digital Gyroscope Sensor");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -125,7 +125,7 @@ int __adis_write_reg(struct adis *adis, unsigned int reg, unsigned int value,
|
||||
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_write_reg);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_write_reg, IIO_ADISLIB);
|
||||
|
||||
/**
|
||||
* __adis_read_reg() - read N bytes from register (unlocked version)
|
||||
@ -222,7 +222,7 @@ int __adis_read_reg(struct adis *adis, unsigned int reg, unsigned int *val,
|
||||
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_read_reg);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_read_reg, IIO_ADISLIB);
|
||||
/**
|
||||
* __adis_update_bits_base() - ADIS Update bits function - Unlocked version
|
||||
* @adis: The adis device
|
||||
@ -247,7 +247,7 @@ int __adis_update_bits_base(struct adis *adis, unsigned int reg, const u32 mask,
|
||||
|
||||
return __adis_write_reg(adis, reg, __val, size);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_update_bits_base);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_update_bits_base, IIO_ADISLIB);
|
||||
|
||||
#ifdef CONFIG_DEBUG_FS
|
||||
|
||||
@ -269,7 +269,7 @@ int adis_debugfs_reg_access(struct iio_dev *indio_dev, unsigned int reg,
|
||||
|
||||
return adis_write_reg_16(adis, reg, writeval);
|
||||
}
|
||||
EXPORT_SYMBOL(adis_debugfs_reg_access);
|
||||
EXPORT_SYMBOL_NS(adis_debugfs_reg_access, IIO_ADISLIB);
|
||||
|
||||
#endif
|
||||
|
||||
@ -318,7 +318,7 @@ out_unlock:
|
||||
mutex_unlock(&adis->state_lock);
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL(adis_enable_irq);
|
||||
EXPORT_SYMBOL_NS(adis_enable_irq, IIO_ADISLIB);
|
||||
|
||||
/**
|
||||
* __adis_check_status() - Check the device for error conditions (unlocked)
|
||||
@ -350,7 +350,7 @@ int __adis_check_status(struct adis *adis)
|
||||
|
||||
return -EIO;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_check_status);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_check_status, IIO_ADISLIB);
|
||||
|
||||
/**
|
||||
* __adis_reset() - Reset the device (unlocked version)
|
||||
@ -374,7 +374,7 @@ int __adis_reset(struct adis *adis)
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_reset);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_reset, IIO_ADIS_LIB);
|
||||
|
||||
static int adis_self_test(struct adis *adis)
|
||||
{
|
||||
@ -465,7 +465,7 @@ int __adis_initial_startup(struct adis *adis)
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(__adis_initial_startup);
|
||||
EXPORT_SYMBOL_NS_GPL(__adis_initial_startup, IIO_ADISLIB);
|
||||
|
||||
/**
|
||||
* adis_single_conversion() - Performs a single sample conversion
|
||||
@ -513,7 +513,7 @@ err_unlock:
|
||||
mutex_unlock(&adis->state_lock);
|
||||
return ret;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(adis_single_conversion);
|
||||
EXPORT_SYMBOL_NS_GPL(adis_single_conversion, IIO_ADISLIB);
|
||||
|
||||
/**
|
||||
* adis_init() - Initialize adis device structure
|
||||
@ -550,7 +550,7 @@ int adis_init(struct adis *adis, struct iio_dev *indio_dev,
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(adis_init);
|
||||
EXPORT_SYMBOL_NS_GPL(adis_init, IIO_ADISLIB);
|
||||
|
||||
MODULE_LICENSE("GPL");
|
||||
MODULE_AUTHOR("Lars-Peter Clausen <lars@metafoo.de>");
|
||||
|
@ -1252,3 +1252,4 @@ module_spi_driver(adis16400_driver);
|
||||
MODULE_AUTHOR("Manuel Stahl <manuel.stahl@iis.fraunhofer.de>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16400/5 IMU SPI driver");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -447,3 +447,4 @@ module_spi_driver(adis16460_driver);
|
||||
MODULE_AUTHOR("Dragos Bogdan <dragos.bogdan@analog.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16460 IMU driver");
|
||||
MODULE_LICENSE("GPL");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -1324,3 +1324,4 @@ module_spi_driver(adis16475_driver);
|
||||
MODULE_AUTHOR("Nuno Sa <nuno.sa@analog.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16475 IMU driver");
|
||||
MODULE_LICENSE("GPL");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -1340,3 +1340,4 @@ module_spi_driver(adis16480_driver);
|
||||
MODULE_AUTHOR("Lars-Peter Clausen <lars@metafoo.de>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16480 IMU driver");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -120,7 +120,7 @@ int adis_update_scan_mode(struct iio_dev *indio_dev,
|
||||
|
||||
return 0;
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(adis_update_scan_mode);
|
||||
EXPORT_SYMBOL_NS_GPL(adis_update_scan_mode, IIO_ADISLIB);
|
||||
|
||||
static irqreturn_t adis_trigger_handler(int irq, void *p)
|
||||
{
|
||||
@ -202,5 +202,5 @@ devm_adis_setup_buffer_and_trigger(struct adis *adis, struct iio_dev *indio_dev,
|
||||
return devm_add_action_or_reset(&adis->spi->dev, adis_buffer_cleanup,
|
||||
adis);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(devm_adis_setup_buffer_and_trigger);
|
||||
EXPORT_SYMBOL_NS_GPL(devm_adis_setup_buffer_and_trigger, IIO_ADISLIB);
|
||||
|
||||
|
@ -92,5 +92,5 @@ int devm_adis_probe_trigger(struct adis *adis, struct iio_dev *indio_dev)
|
||||
|
||||
return devm_iio_trigger_register(&adis->spi->dev, adis->trig);
|
||||
}
|
||||
EXPORT_SYMBOL_GPL(devm_adis_probe_trigger);
|
||||
EXPORT_SYMBOL_NS_GPL(devm_adis_probe_trigger, IIO_ADISLIB);
|
||||
|
||||
|
@ -318,3 +318,4 @@ MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices ADIS16203 Programmable 360 Degrees Inclinometer");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_ALIAS("spi:adis16203");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
@ -445,3 +445,4 @@ MODULE_AUTHOR("Barry Song <21cnbao@gmail.com>");
|
||||
MODULE_DESCRIPTION("Analog Devices Programmable Impact Sensor and Recorder");
|
||||
MODULE_LICENSE("GPL v2");
|
||||
MODULE_ALIAS("spi:adis16240");
|
||||
MODULE_IMPORT_NS(IIO_ADISLIB);
|
||||
|
Loading…
Reference in New Issue
Block a user