diff options
| author | Trevor Gamblin <[email protected]> | 2024-06-17 09:50:01 -0400 |
|---|---|---|
| committer | Jonathan Cameron <[email protected]> | 2024-06-25 21:04:46 +0100 |
| commit | e5757bd8ceed272d133bdb79c8094b400a0743e5 (patch) | |
| tree | 49871d631936620f007105741ff4d3d48ba6100d | |
| parent | c1cf171365dcf383042cbea3e1c3475375c1e496 (diff) | |
iio: gyro: bmg160_core: make use of regmap_clear_bits()
Instead of using regmap_update_bits() and passing val = 0, use
regmap_clear_bits().
Suggested-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Trevor Gamblin <[email protected]>
Acked-by: Uwe Kleine-König <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Jonathan Cameron <[email protected]>
| -rw-r--r-- | drivers/iio/gyro/bmg160_core.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/iio/gyro/bmg160_core.c b/drivers/iio/gyro/bmg160_core.c index 0e2eb0e98235..10728d5ccae3 100644 --- a/drivers/iio/gyro/bmg160_core.c +++ b/drivers/iio/gyro/bmg160_core.c @@ -285,8 +285,8 @@ static int bmg160_chip_init(struct bmg160_data *data) data->slope_thres = val; /* Set default interrupt mode */ - ret = regmap_update_bits(data->regmap, BMG160_REG_INT_EN_1, - BMG160_INT1_BIT_OD, 0); + ret = regmap_clear_bits(data->regmap, BMG160_REG_INT_EN_1, + BMG160_INT1_BIT_OD); if (ret < 0) { dev_err(dev, "Error updating bits in reg_int_en_1\n"); return ret; |