[PATCH 2/3] pinctrl: export function get_pinctrl_dev_from_devname()

Linus Walleij linus.walleij at linaro.org
Thu Sep 15 01:43:52 PDT 2022


On Thu, Sep 15, 2022 at 4:13 AM Jianqun Xu <jay.xu at rock-chips.com> wrote:

> Export get_pinctrl_dev_from_devname() as GPL and add to pinctrl head file.
>
> Signed-off-by: Jianqun Xu <jay.xu at rock-chips.com>
> ---
>  drivers/pinctrl/core.c          | 1 +
>  include/linux/pinctrl/pinctrl.h | 1 +

If you add it to <linux/pinctrl/pinctrl.h> you need to remove it from
drivers/pinctrl/core.h.

I suggest you just include the local header instead.

#include "../pinctrl/pinctrl.h"

Maybe not the most elegant but it keeps the interface private to
pinctrl and GPIO and not broadcast to the entire kernel.

If it looks very ugly, well then it is probably because this driver
should move into drivers/pinctrl.

Yours,
Linus Walleij



More information about the Linux-rockchip mailing list