diff options
| author | saturneric <[email protected]> | 2025-10-16 21:50:56 +0000 |
|---|---|---|
| committer | saturneric <[email protected]> | 2025-10-16 21:50:56 +0000 |
| commit | 5293dcd7ffda472dbf326c81877bb63d2bfcbd10 (patch) | |
| tree | da3be05c4aa1646e5f26a84cd75d83fe866c5358 /drivers/gpio/gpio-wcove.c | |
| parent | Merge tag 'v6.16' (diff) | |
| parent | Linux 6.17 (diff) | |
| download | kernel-5293dcd7ffda472dbf326c81877bb63d2bfcbd10.tar.gz kernel-5293dcd7ffda472dbf326c81877bb63d2bfcbd10.zip | |
Merge tag 'v6.17'
Linux 6.17
Diffstat (limited to 'drivers/gpio/gpio-wcove.c')
| -rw-r--r-- | drivers/gpio/gpio-wcove.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/gpio/gpio-wcove.c b/drivers/gpio/gpio-wcove.c index 1ec24f6f9300..4a5e20e936a9 100644 --- a/drivers/gpio/gpio-wcove.c +++ b/drivers/gpio/gpio-wcove.c @@ -200,18 +200,15 @@ static int wcove_gpio_get(struct gpio_chip *chip, unsigned int gpio) return val & 0x1; } -static void wcove_gpio_set(struct gpio_chip *chip, unsigned int gpio, int value) +static int wcove_gpio_set(struct gpio_chip *chip, unsigned int gpio, int value) { struct wcove_gpio *wg = gpiochip_get_data(chip); int reg = to_reg(gpio, CTRL_OUT); if (reg < 0) - return; + return 0; - if (value) - regmap_set_bits(wg->regmap, reg, 1); - else - regmap_clear_bits(wg->regmap, reg, 1); + return regmap_assign_bits(wg->regmap, reg, 1, value); } static int wcove_gpio_set_config(struct gpio_chip *chip, unsigned int gpio, |
