Re: [PATCH] pinctrl: freescale: avoid overwriting pin config when freeing GPIO

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

 



On Tue, Sep 27, 2016 at 2:26 AM, Stefan Agner <stefan@xxxxxxxx> wrote:

> +       /* Only change pad configuration if pad is still a GPIO */
> +       if (reg & (0x7 << 20))
> +               return;
> +
> +       /* Clear IBE/OBE/PUE to disable the pin (Hi-Z) */
>         reg &= ~0x7;
>         writel(reg, ipctl->base + pin_reg->mux_reg);

Please #define the magic 7 and 20 above so we see what is going
on if you choose this approach.

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-gpio" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[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