Re: [PATCH 1/3] pinctrl: at91-pio4: Enable Push-Pull configuration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Wed, May 17, 2023 at 01:54:04PM +0200, Ryan.Wanner@xxxxxxxxxxxxx kirjoitti:
> From: Ryan Wanner <Ryan.Wanner@xxxxxxxxxxxxx>
> 
> 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





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux