Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

iio: pressure: bmp280-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 <u.kleine-koenig@baylibre.com>
Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Tested-By: Vasileios Amoiridis <vassilisamir@gmail.com>
Acked-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com>
Link: https://patch.msgid.link/20240617-review-v3-35-88d1338c4cca@baylibre.com
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>

authored by

Trevor Gamblin and committed by
Jonathan Cameron
c470071e 3b6f6e57

+2 -2
+2 -2
drivers/iio/pressure/bmp280-core.c
··· 1645 1645 goto exit; 1646 1646 1647 1647 /* Disable programming mode bit */ 1648 - ret = regmap_update_bits(data->regmap, BMP580_REG_NVM_ADDR, 1649 - BMP580_NVM_PROG_EN, 0); 1648 + ret = regmap_clear_bits(data->regmap, BMP580_REG_NVM_ADDR, 1649 + BMP580_NVM_PROG_EN); 1650 1650 if (ret) { 1651 1651 dev_err(data->dev, "error resetting nvm write\n"); 1652 1652 goto exit;