Commit c8059930 authored by Mark Brown's avatar Mark Brown

ASoC: Accept any logical value WM8903 GPIO set()

Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: default avatarLiam Girdwood <lrg@slimlogic.co.uk>
parent d71bb810
...@@ -1702,7 +1702,8 @@ static void wm8903_gpio_set(struct gpio_chip *chip, unsigned offset, int value) ...@@ -1702,7 +1702,8 @@ static void wm8903_gpio_set(struct gpio_chip *chip, unsigned offset, int value)
struct snd_soc_codec *codec = wm8903->codec; struct snd_soc_codec *codec = wm8903->codec;
snd_soc_update_bits(codec, WM8903_GPIO_CONTROL_1 + offset, snd_soc_update_bits(codec, WM8903_GPIO_CONTROL_1 + offset,
WM8903_GP1_LVL_MASK, value << WM8903_GP1_LVL_SHIFT); WM8903_GP1_LVL_MASK,
!!value << WM8903_GP1_LVL_SHIFT);
} }
static struct gpio_chip wm8903_template_chip = { static struct gpio_chip wm8903_template_chip = {
......
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