stm32f7 serial:Add SINGLEWIRE PUSHPULL option
This commit is contained in:
parent
156024671e
commit
d61f14dd3c
@ -2437,7 +2437,9 @@ static int up_ioctl(struct file *filep, int cmd, unsigned long arg)
|
||||
|
||||
if ((arg & SER_SINGLEWIRE_ENABLED) != 0)
|
||||
{
|
||||
uint32_t gpio_val = GPIO_OPENDRAIN;
|
||||
uint32_t gpio_val = (arg & SER_SINGLEWIRE_PUSHPULL) ==
|
||||
SER_SINGLEWIRE_PUSHPULL ?
|
||||
GPIO_PUSHPULL : GPIO_OPENDRAIN;
|
||||
gpio_val |= (arg & SER_SINGLEWIRE_PULL_MASK) ==
|
||||
SER_SINGLEWIRE_PULLUP ? GPIO_PULLUP : GPIO_FLOAT;
|
||||
gpio_val |= (arg & SER_SINGLEWIRE_PULL_MASK) ==
|
||||
|
Loading…
Reference in New Issue
Block a user