summaryrefslogtreecommitdiff
path: root/drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
diff options
context:
space:
mode:
authorAdriana Reus <adriana.reus@intel.com>2016-02-12 13:44:45 +0200
committerJonathan Cameron <jic23@kernel.org>2016-02-13 20:54:07 +0000
commitfd64df16f40e367c393bf372fb67017301d701c2 (patch)
tree489cc8466452a86da107f7832e5b79b3b62c050b /drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
parentb3eea8dacfb758baa0fe78e0cf24d5e5d288c5fe (diff)
iio: imu: inv_mpu6050: Add SPI support for MPU6000
The only difference between the MPU6000 and the MPU6050 is that the first also supports SPI. Add SPI driver for this chip. Signed-off-by: Adriana Reus <adriana.reus@intel.com> Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com> Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Diffstat (limited to 'drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h')
-rw-r--r--drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h b/drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
index 1bf65a0fd323..fcc2f3dfdfa8 100644
--- a/drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
+++ b/drivers/iio/imu/inv_mpu6050/inv_mpu_iio.h
@@ -62,6 +62,7 @@ struct inv_mpu6050_reg_map {
enum inv_devices {
INV_MPU6050,
INV_MPU6500,
+ INV_MPU6000,
INV_NUM_PARTS
};
@@ -154,6 +155,7 @@ struct inv_mpu6050_state {
#define INV_MPU6050_BIT_I2C_MST_EN 0x20
#define INV_MPU6050_BIT_FIFO_EN 0x40
#define INV_MPU6050_BIT_DMP_EN 0x80
+#define INV_MPU6050_BIT_I2C_IF_DIS 0x10
#define INV_MPU6050_REG_PWR_MGMT_1 0x6B
#define INV_MPU6050_BIT_H_RESET 0x80
@@ -258,6 +260,8 @@ int inv_mpu6050_write_reg(struct inv_mpu6050_state *st, int reg, u8 val);
int inv_mpu6050_set_power_itg(struct inv_mpu6050_state *st, bool power_on);
int inv_mpu_acpi_create_mux_client(struct i2c_client *client);
void inv_mpu_acpi_delete_mux_client(struct i2c_client *client);
-int inv_mpu_core_probe(struct regmap *regmap, int irq, const char *name);
+int inv_mpu_core_probe(struct regmap *regmap, int irq, const char *name,
+ int (*inv_mpu_bus_setup)(struct iio_dev *));
int inv_mpu_core_remove(struct device *dev);
+int inv_mpu6050_set_power_itg(struct inv_mpu6050_state *st, bool power_on);
extern const struct dev_pm_ops inv_mpu_pmops;