iio: pressure: bmp280: split off an I2C Kconfig entry
This creates a separate BMP280_I2C Kconfig entry that gets selected
by BMP280 for I2C transport. As we currently only support I2C
transport there is not much practical change other than getting
a separate object file (or module) for the I2C driver part. The
old Kconfig symbol BMP280 will still select the stuff we need so
that oldconfig and old defconfigs works fine.
Tested-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
diff --git a/drivers/iio/pressure/bmp280-regmap.c b/drivers/iio/pressure/bmp280-regmap.c
index 3341189..6807113 100644
--- a/drivers/iio/pressure/bmp280-regmap.c
+++ b/drivers/iio/pressure/bmp280-regmap.c
@@ -1,4 +1,5 @@
#include <linux/device.h>
+#include <linux/module.h>
#include <linux/regmap.h>
#include "bmp280.h"
@@ -37,6 +38,7 @@
.writeable_reg = bmp180_is_writeable_reg,
.volatile_reg = bmp180_is_volatile_reg,
};
+EXPORT_SYMBOL(bmp180_regmap_config);
static bool bmp280_is_writeable_reg(struct device *dev, unsigned int reg)
{
@@ -79,3 +81,4 @@
.writeable_reg = bmp280_is_writeable_reg,
.volatile_reg = bmp280_is_volatile_reg,
};
+EXPORT_SYMBOL(bmp280_regmap_config);