- 14 Jun, 2022 20 commits
-
-
Gwendal Grignou authored
Allow setting the internal resistor used for compensation. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Acked-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220429220144.1476049-6-gwendal@chromium.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gwendal Grignou authored
Add ability to set the precharge internal resistance from the device tree. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Link: https://lore.kernel.org/r/20220429220144.1476049-5-gwendal@chromium.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gwendal Grignou authored
Allow configure the resistance used during precharge. Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Acked-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220429220144.1476049-4-gwendal@chromium.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Gwendal Grignou authored
Field for PROX_CTRL4 should contain PROX_CTRL4. Fixes: 4c18a890 ("iio:proximity:sx9324: Add SX9324 support") Signed-off-by: Gwendal Grignou <gwendal@chromium.org> Reviewed-by: Stephen Boyd <swboyd@chromium.org> Link: https://lore.kernel.org/r/20220429220144.1476049-3-gwendal@chromium.orgSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Jonathan Cameron authored
Using this approach as opposed to CONFIG_PM guards allows the compiler to remove the unused code instead of doing it manually. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20220220175149.503495-3-jic23@kernel.org
-
Jonathan Cameron authored
This driver is built as a single module. There is an note in the makefile about SPI support being a reason to split the build in future. That support has never arrived so drop these symbol exports. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Linus Walleij <linus.walleij@linaro.org> Reviewed-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20220220175149.503495-2-jic23@kernel.org
-
Jonathan Cameron authored
Avoid unnecessary pollution of the global symbol namespace by moving library functions in to a specific namespace and import that into the drivers that make use of the functions. For more info: https://lwn.net/Articles/760045/Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Cc: Nuno Sá <nuno.sa@analog.com> Reviewed-by: Nuno Sá <nuno.sa@analog.com> Link: https://lore.kernel.org/r/20220220173701.502331-5-jic23@kernel.org
-
Jonathan Cameron authored
This function was introduced with the ability to pick a clock. There are no upstream users so presumably it isn't as obviously useful as it seemed at the time. Hence drop it. Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> Link: https://lore.kernel.org/r/20220220163327.424696-1-jic23@kernel.org
-
Cosmin Tanislav authored
The starting bit is always zero, it doesn't make much sense to use for_each_set_bit_from. Replace it with for_each_set_bit which doesn't start from a particular bit. Signed-off-by: Cosmin Tanislav <cosmin.tanislav@analog.com> Reviewed-by: Andy Shevchenko <andy.shevchenko@gmail.com> Link: https://lore.kernel.org/r/20220111074703.3677392-3-cosmin.tanislav@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Xiang wangx authored
Delete the redundant word 'via'. Signed-off-by: Xiang wangx <wangxiang@cdjrlc.com> Link: https://lore.kernel.org/r/20220604040541.8470-1-wangxiang@cdjrlc.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Different from SCA3300, SCL3300 can output inclination angles. Angles are formed from acceleration with following equations: ANG_X = atan2(accx , sqrt(pow(accy , 2) + pow(accz , 2))) ANG_Y = atan2(accy , sqrt(pow(accx , 2) + pow(accz , 2))) ANG_Z = atan2(accz , sqrt(pow(accx , 2) + pow(accy , 2))) The commit adds the output of the raw value, scale and scale_available of angles. New interfaces: in_incli_scale in_incli_scale_available in_incli_x_raw in_incli_y_raw in_incli_z_raw Data converted by application of scale to degrees. Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Reviewed-by: Tomas Melin <tomas.melin@vaisala.com> Link: https://lore.kernel.org/r/20220529061853.3044893-6-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Add support for Murata SCL3300, a 3-axis MEMS accelerometer. Same as SCA3300, it has the accelerometer and temperature output. Datasheet: www.murata.com/en-us/products/sensor/inclinometer/overview/lineup/scl3300 Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Reviewed-by: Tomas Melin <tomas.melin@vaisala.com> Link: https://lore.kernel.org/r/20220529061853.3044893-5-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Prepare the way for multiple chips and additional channels: - Modify the driver to read the device ID and load the corresponding sensor information from the table to support multiple chips - Add prepares for the addition of extra channels - Prepare for handling the operation modes for multiple chips Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Reviewed-by: Tomas Melin <tomas.melin@vaisala.com> Link: https://lore.kernel.org/r/20220529061853.3044893-4-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Add define of SCA3300_TEMP_CHANNEL for reuse. Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Reviewed-by: Tomas Melin <tomas.melin@vaisala.com> Link: https://lore.kernel.org/r/20220529061853.3044893-3-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Add DT bindings for Murata scl3300 inclinometer. Reviewed-by: Rob Herring <robh@kernel.org> Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Reviewed-by: Tomas Melin <tomas.melin@vaisala.com> Link: https://lore.kernel.org/r/20220529061853.3044893-2-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
Convert the module to be property provider agnostic and allow it to be used on non-OF platforms. Add mod_devicetable.h include. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220531213922.72992-2-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
Use the ->probe_new() callback. The driver does not use const struct i2c_device_id * argument, so convert it to utilise the simplified I²C driver registration. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220531213922.72992-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
Convert the module to be property provider agnostic and allow it to be used on non-OF platforms. Add mod_devicetable.h include. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220531142353.64925-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
Use dev_fwnode() instead of direct OF node dereference when checking for regulator API error code. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220531135320.63096-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
There is nothing directly using of specific interfaces in this driver, so lets not include the headers. While at it, drop dependency to OF, which currently makes no sense. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220531212218.72189-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
- 11 Jun, 2022 20 commits
-
-
Andy Shevchenko authored
Nothing in this driver depends on OF so drop the dependency to remove the false impression such a dependency exists. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220530181313.2789-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Andy Shevchenko authored
Nothing in this driver depends on OF so drop the dependency to remove the false impression such a dependency exists. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Link: https://lore.kernel.org/r/20220530181706.3045-1-andriy.shevchenko@linux.intel.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
keliu authored
Use ida_alloc()/ida_free() instead of deprecated ida_simple_get()/ida_simple_remove() . Signed-off-by: keliu <liuke94@huawei.com> Link: https://lore.kernel.org/r/20220527091739.2949426-1-liuke94@huawei.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Adds the device-tree bindings for the Bosch BMI085 and BMI090L IMU, the accelerometer part. Datasheet: https://www.bosch-sensortec.com/media/boschsensortec/downloads/datasheets/bst-bmi085-ds001.pdf Datasheet: https://media.digikey.com/pdf/Data%20Sheets/Bosch/BST-BMI090L-DS000-00.pdfSigned-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Acked-by: Rob Herring <robh@kernel.org> Link: https://lore.kernel.org/r/20220526133359.2261928-7-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Add supports for BMI090L, it's a high-performance Inertial Measurement Unit, with an accelerometer and gyroscope. The commit adds the accelerometer driver for the SPI interface. The gyroscope part is already supported by the BMG160 driver. Same as BMI088, BMI090L have the range of +/-3, 6, 12, and 24g. Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com> Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Link: https://lore.kernel.org/r/20220526133359.2261928-6-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
Add supports for BMI085, an Inertial Measurement Unit, with an accelerometer and gyroscope. The commit adds the accelerometer driver for the SPI interface. The gyroscope part is already supported by the BMG160 driver. Unlike BMI088, the BMI085 accelerometer ranges are +/-2, 4, 6, and 8g, the scales are calculated as 9.8/32768*pow(2,reg41+1). Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com> Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Link: https://lore.kernel.org/r/20220526133359.2261928-5-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
iio: accel: bmi088: modified the device name It is possible to have multiple sensors connected on the same platform. For support of different sensors, making it possible to obtain the device name by reading the chip id. If the device was found in the table but the device tree binding is different, the driver will carry on with a warning. If no matching device was found, the driver load the binding chip info. Tested case, test with bmi085 and bmi090 patches applied: connect 3 bmi090l to the system, and set device tree compatible: spi2.0: compatible = "bosch,bmi090l-accel"; spi2.2: compatible = "bosch,bmi088-accel"; spi2.4: compatible = "bosch,bmi085-accel"; Get a warning for the mismatched devices: bmi088_accel_spi spi2.2: unexpected chip id 0x1A bmi088_accel_spi spi2.4: unexpected chip id 0x1A Get the real present device name: /sys/bus/iio/devices/iio:device1/name:bmi090l-accel /sys/bus/iio/devices/iio:device3/name:bmi090l-accel /sys/bus/iio/devices/iio:device5/name:bmi090l-accel Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Link: https://lore.kernel.org/r/20220526133359.2261928-4-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
The sensor can set the scales by writing the range register 0x41, The current driver has no interface to configure it. The commit adds the interface for config the scales. Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com> Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Link: https://lore.kernel.org/r/20220526133359.2261928-3-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
LI Qingwu authored
The units after application of scale are 100*m/s^2, The scale calculation is only for the device with the range of 3, 6, 12, and 24g, but some other chips have a range of 2, 4, 6, and 8g. Modified the scales from formula to a list, the scales in the list are calculated as 9.8/32768*pow(2,reg41+1)*1.5, refer to datasheet 5.3.4. The new units after the application of scale are m/s^2. Reviewed-by: Alexandru Ardelean <ardeleanalex@gmail.com> Signed-off-by: LI Qingwu <Qing-wu.Li@leica-geosystems.com.cn> Link: https://lore.kernel.org/r/20220526133359.2261928-2-Qing-wu.Li@leica-geosystems.com.cnSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Alexandru Tachici authored
Update bindings maintainerns section. Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com> Acked-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/20220526134603.75216-6-alexandru.tachici@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Alexandru Tachici authored
Update bindings maintainerns section. Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com> Acked-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/20220526134603.75216-5-alexandru.tachici@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Alexandru Tachici authored
Update bindings maintainerns section. Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com> Acked-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/20220526134603.75216-4-alexandru.tachici@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Alexandru Tachici authored
Update bindings maintainerns section. Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com> Acked-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/20220526134603.75216-3-alexandru.tachici@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Alexandru Tachici authored
Update bindings maintainerns section. Signed-off-by: Alexandru Tachici <alexandru.tachici@analog.com> Acked-by: Alexandru Ardelean <ardeleanalex@gmail.com> Link: https://lore.kernel.org/r/20220526134603.75216-2-alexandru.tachici@analog.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Markuss Broks authored
Handle the GPIO connected to the XSHUT/RST_N pin of VL53L0X. Signed-off-by: Markuss Broks <markuss.broks@gmail.com> Link: https://lore.kernel.org/r/20220523175344.5845-5-markuss.broks@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Markuss Broks authored
Handle the regulator supplying the VDD pin of VL53L0X. Signed-off-by: Markuss Broks <markuss.broks@gmail.com> Link: https://lore.kernel.org/r/20220523175344.5845-4-markuss.broks@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Markuss Broks authored
On some boards interrupt type might be different than falling edge, like hardcoded in driver. Leave interrupt flags as they were pre-configured from the device-tree. If they're not provided, default to falling edge interrupts. Signed-off-by: Markuss Broks <markuss.broks@gmail.com> Link: https://lore.kernel.org/r/20220523175344.5845-3-markuss.broks@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Markuss Broks authored
Add the optional properties for the VL53L0X ToF sensor to the device-tree binding. Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Signed-off-by: Markuss Broks <markuss.broks@gmail.com> Link: https://lore.kernel.org/r/20220523175344.5845-2-markuss.broks@gmail.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Li Zhengyu authored
(!val) has been checked outside the loop, remove redundant (val &&) from loop. Signed-off-by: Li Zhengyu <lizhengyu3@huawei.com> Acked-by: Andreas Klinger <ak@it-klinger.de> Link: https://lore.kernel.org/r/20220523122755.90638-1-lizhengyu3@huawei.comSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-
Peter Rosin authored
It fits right in as a single 12-bit DAC. Reviewed-by: Sean Nyekjaer <sean@geanix.com> Signed-off-by: Peter Rosin <peda@axentia.se> Link: https://lore.kernel.org/r/a09a49a5-3d01-21f7-02ed-b191d70e7609@axentia.seSigned-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
-