Commit 36086889 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Jonathan Cameron

iio: ak8975: fix AK09911 dependencies

ak8975 depends on I2C and GPIOLIB, so any symbols that selects
ak8975 must have the same dependency, or we get build errors:

drivers/iio/magnetometer/ak8975.c: In function 'ak8975_who_i_am':
drivers/iio/magnetometer/ak8975.c:393:2: error: implicit declaration of function 'i2c_smbus_read_i2c_block_data' [-Werror=implicit-function-declaration]
  ret = i2c_smbus_read_i2c_block_data(client, AK09912_REG_WIA1,
  ^
drivers/iio/magnetometer/ak8975.c: In function 'ak8975_set_mode':
drivers/iio/magnetometer/ak8975.c:431:2: error: implicit declaration of function 'i2c_smbus_write_byte_data' [-Werror=implicit-function-declaration]
  ret = i2c_smbus_write_byte_data(data->client,
Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Fixes: 57e73a42 ("iio: ak8975: add ak09911 and ak09912 support")
Signed-off-by: default avatarJonathan Cameron <jic23@kernel.org>
parent b841118e
...@@ -18,6 +18,8 @@ config AK8975 ...@@ -18,6 +18,8 @@ config AK8975
config AK09911 config AK09911
tristate "Asahi Kasei AK09911 3-axis Compass" tristate "Asahi Kasei AK09911 3-axis Compass"
depends on I2C
depends on GPIOLIB
select AK8975 select AK8975
help help
Deprecated: AK09911 is now supported by AK8975 driver. Deprecated: AK09911 is now supported by AK8975 driver.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment