Re: [PATCH] Revert "pinctrl: devicetree: Fix dt_to_map_one_config handling of hogs"

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

 



Hi Richard,

On Thu, Jun 7, 2018 at 1:17 PM, Richard Fitzgerald
<rf@xxxxxxxxxxxxxxxxxxxxx> wrote:

> I see the bug. If the hog node isn't a 1st level child of the pinctrl
> parent node it will go around the for(;;) loop again but on the first
> pass I overwrite pctldev with the result of
> get_pinctrl_dev_from_of_node() so it doesn't point to the pinctrl driver
> any more.
>
> It's end of the day here, I'll do a patch tomorrow to stash the original
> pctldev so it doesn't get overwritten.
>
> Something like this should work.
>
> 1) Rename the "pctldev" argument to the function to "hog_pctldev"
> 2) Add a local variable
>         struct pinctrl_dev *pctldev = NULL;
>
> 3) Change the if statement to:
>
>                 if (hog_pctldev && (np_pctldev == p->dev->of_node)) {
>                         pctrldev = hog_pctldev;
>                         break;
>                 }
>

Yes, this works fine. Thanks.

Will send your suggested fix.

Thanks for your help!
--
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