Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7247645f authored by Cristina Moraru's avatar Cristina Moraru Committed by Jonathan Cameron
Browse files

iio: hmc5843: Move hmc5843 out of staging



This patch moves hmc5843 driver from staging/iio/magnetometer
to iio/magnetometer, updates the corresponding Makefiles and
moves the hmc5843* entries to the 'Industrial I/O support ->
Magnetometer sensors' menu.

Signed-off-by: default avatarCristina Moraru <cristina.moraru09@gmail.com>
Cc: Daniel Baluta <daniel.baluta@intel.com>
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent 7b7a1c38
Loading
Loading
Loading
Loading
+33 −0
Original line number Diff line number Diff line
@@ -105,4 +105,37 @@ config IIO_ST_MAGN_SPI_3AXIS
	depends on IIO_ST_MAGN_3AXIS
	depends on IIO_ST_SENSORS_SPI

config SENSORS_HMC5843
	tristate
	select IIO_BUFFER
	select IIO_TRIGGERED_BUFFER

config SENSORS_HMC5843_I2C
	tristate "Honeywell HMC5843/5883/5883L 3-Axis Magnetometer (I2C)"
	depends on I2C
	select SENSORS_HMC5843
	select REGMAP_I2C
	help
	  Say Y here to add support for the Honeywell HMC5843, HMC5883 and
	  HMC5883L 3-Axis Magnetometer (digital compass).

	  This driver can also be compiled as a set of modules.
	  If so, these modules will be created:
	  - hmc5843_core (core functions)
	  - hmc5843_i2c (support for HMC5843, HMC5883, HMC5883L and HMC5983)

config SENSORS_HMC5843_SPI
	tristate "Honeywell HMC5983 3-Axis Magnetometer (SPI)"
	depends on SPI_MASTER
	select SENSORS_HMC5843
	select REGMAP_SPI
	help
	  Say Y here to add support for the Honeywell HMC5983 3-Axis Magnetometer
	  (digital compass).

	  This driver can also be compiled as a set of modules.
	  If so, these modules will be created:
	  - hmc5843_core (core functions)
	  - hmc5843_spi (support for HMC5983)

endmenu
+4 −0
Original line number Diff line number Diff line
@@ -15,3 +15,7 @@ st_magn-$(CONFIG_IIO_BUFFER) += st_magn_buffer.o

obj-$(CONFIG_IIO_ST_MAGN_I2C_3AXIS) += st_magn_i2c.o
obj-$(CONFIG_IIO_ST_MAGN_SPI_3AXIS) += st_magn_spi.o

obj-$(CONFIG_SENSORS_HMC5843)		+= hmc5843_core.o
obj-$(CONFIG_SENSORS_HMC5843_I2C)	+= hmc5843_i2c.o
obj-$(CONFIG_SENSORS_HMC5843_SPI)	+= hmc5843_spi.o
+3 −4
Original line number Diff line number Diff line
@@ -18,7 +18,6 @@
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 */

#include <linux/module.h>
@@ -595,9 +594,9 @@ static int hmc5843_init(struct hmc5843_data *data)

static const struct iio_info hmc5843_info = {
	.attrs = &hmc5843_group,
	.read_raw = hmc5843_read_raw,
	.write_raw = hmc5843_write_raw,
	.write_raw_get_fmt = hmc5843_write_raw_get_fmt,
	.read_raw = &hmc5843_read_raw,
	.write_raw = &hmc5843_write_raw,
	.write_raw_get_fmt = &hmc5843_write_raw_get_fmt,
	.driver_module = THIS_MODULE,
};

Loading