Re: [PATCH v5 1/2] pinctrl: sunxi: pass down flags to pinctrl routines

From: Chen-Yu Tsai

Date: Thu Mar 19 2026 - 13:54:54 EST


On Fri, Mar 20, 2026 at 1:19 AM <michal.piekos@xxxxxxxxxxxxx> wrote:
>
> From: Andre Przywara <andre.przywara@xxxxxxx>
>
> Recent changes in the Allwinner pinctrl/GPIO IP made us add some quirks,
> which the new SoCs (A523 family) need to use. We now have a comfortable
> "flags" field on the per-SoC setup side, to tag those quirks we need, but
> were translating those flag bits into specific fields for runtime use, in
> the init routine.
> Now the newest Allwinner GPIO IP adds even more quirks and exceptions,
> some of a boolean nature.
> To avoid inventing various new boolean flags for the runtime struct
> sunxi_pinctrl, let's just directly pass on the flags variable used by the
> setup code, so runtime can check for those various quirk bits directly.
>
> Rename the "variant" member to "flags", and directly copy the value from
> the setup code into there. Move the variant masking from the init
> routine to the functions which actually use the "variant" value.
>
> This mostly paves the way for the new A733 IP generation, which needs
> more quirks to be checked at runtime.
>
> Signed-off-by: Andre Przywara <andre.przywara@xxxxxxx>
> Signed-off-by: Michal Piekos <michal.piekos@xxxxxxxxxxxxx>

Reviewed-by: Chen-Yu Tsai <wens@xxxxxxxxxx>

Please carry tags forward if the patch is unchanged.