[Letux-kernel] Regression in v4.20 with omap_hsmmc GPIO CD and WP

Linus Walleij linus.walleij at linaro.org
Sun Dec 30 20:17:08 CET 2018


On Sun, Dec 30, 2018 at 10:35 AM H. Nikolaus Schaller <hns at goldelico.com> wrote:
> > Am 30.12.2018 um 10:24 schrieb Andreas Kemnade <andreas at kemnade.info>:

> >> Any ideas what might be causing this on boot? Are we maybe missing
> >> a call on boot to mmc_gpio_get_cd() somewhere?
> >>
> > it hides some bogous cd gpio defines in dtb. At least on some pyra
> > models. We had wrong polarity there.
>
> Before this patch cd gpios were not really being used. With correct code
> it uses bad definitions.

This makes a lot of sense, can you folks confirm that fixing the device
tree fixes the issue?

If there are old device trees deployed (and I am thinking about mass
production here, not prototype boards) we might have to insert quirks
to the GPIO core to account for their erroneous polarity flags.

If that is necessary we can patch drivers/gpio/gpiolib-of.c with a quirk
to deal with it, this is where I collect all GPIO DT quirk business.
We would then use something like
if (of_machine_is_compatible("funny-board")) && !strcmp(name, "cd"))
etc.

Yours,
Linus Walleij


More information about the Letux-kernel mailing list