diff options
author | Pho Tran <pho.tran@silabs.com> | 2021-06-10 16:28:44 +0300 |
---|---|---|
committer | Johan Hovold <johan@kernel.org> | 2021-06-16 18:40:01 +0300 |
commit | 8051334e901f2f7ab9fa30a15b74cdc8e58dfde2 (patch) | |
tree | 5161e885ec057792b2d41dc47a7d027589f00dd4 /drivers/platform/x86/hp_accel.c | |
parent | 17cd3a106e9762cd97883cce884a8bfcf5a476ad (diff) | |
download | linux-8051334e901f2f7ab9fa30a15b74cdc8e58dfde2.tar.xz |
USB: serial: cp210x: add support for GPIOs on CP2108
Similar to some other CP210x device types, CP2108 has a number of GPIO
pins that can be exposed through gpiolib.
CP2108 has four serial interfaces but only one set of GPIO pins, which
is modelled as a single gpio chip and registered as a child of the first
interface.
CP2108 has 16 GPIOs so the width of the state variables needs to be
extended to 16 bits and this is also reflected in the control requests.
Like CP2104, CP2108 have GPIO pins with configurable alternate
functions and pins unavailable for GPIO use are determined and reported
to gpiolib at probe.
Signed-off-by: Pho Tran <pho.tran@silabs.com>
Co-developed-by: Tung Pham <tung.pham@silabs.com>
Signed-off-by: Tung Pham <tung.pham@silabs.com>
[ johan: rewrite gpio get() and set(); misc cleanups; amend commit
message ]
Link: https://lore.kernel.org/r/20210610132844.25495-1-johan@kernel.org
Signed-off-by: Johan Hovold <johan@kernel.org>
Diffstat (limited to 'drivers/platform/x86/hp_accel.c')
0 files changed, 0 insertions, 0 deletions