lkml.org 
[lkml]   [2023]   [May]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 1/3] pinctrl: at91-pio4: Enable Push-Pull configuration
Wed, May 17, 2023 at 01:54:04PM +0200, Ryan.Wanner@microchip.com kirjoitti:
> From: Ryan Wanner <Ryan.Wanner@microchip.com>
>
> Enable push-pull configuration. Remove integer value argument from
> open-drain configuration as it is discarded when pinconf function is
> called from gpiolib. Add push-pull do debug and get functions.

Right, thank you for fixing this!
Other comments below.

...

> + case PIN_CONFIG_DRIVE_PUSH_PULL:
> + conf &= (~ATMEL_PIO_OPD_MASK);

Parentheses are redundant.

> break;

...

> if (conf & ATMEL_PIO_OPD_MASK)
> seq_printf(s, "%s ", "open-drain");
> + if (!(conf & ATMEL_PIO_OPD_MASK))
> + seq_printf(s, "%s ", "push-pull");

As commented already by others, the else would be better.

--
With Best Regards,
Andy Shevchenko


\
 
 \ /
  Last update: 2023-05-23 18:28    [W:0.127 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site