]> git.baikalelectronics.ru Git - kernel.git/commit
pinctrl: sx150x: access the correct bits in the 4-bit regs of sx150[147]
authorPeter Rosin <peda@axentia.se>
Fri, 2 Dec 2016 10:51:14 +0000 (11:51 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 7 Dec 2016 14:27:02 +0000 (15:27 +0100)
commitfff82e5f42b6b24446ec3e41799af0d7cb82406a
treef3f5e3e3302205c38aac6874fb1e2603e05ab8e7
parent2d840b41b26efab9c495621e775a2f2fd89e6b5c
pinctrl: sx150x: access the correct bits in the 4-bit regs of sx150[147]

The code assumes 8-bit or 16-bit width registers, but three of the
chips (sx1501/sx1504/sx1507) are 4-bit. So, try to handle 4-bit chips as
well, they leave the high part of each register unused.

Signed-off-by: Peter Rosin <peda@axentia.se>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/pinctrl-sx150x.c