Re: [PATCH v4 05/13] pinctrl: eyeq5: Use match data
From: Linus Walleij
Date: Mon Mar 23 2026 - 05:28:59 EST
On Mon, Mar 16, 2026 at 4:26 PM Benoît Monin <benoit.monin@xxxxxxxxxxx> wrote:
> Instead of using the pin descriptions, pin functions and register offsets
> of the EyeQ5 directly, access those via a pointer to a newly introduced
> struct eq5p_match_data.
>
> This structure contains, in addition to the pin descriptions and pin
> functions, an array of pin banks. Each bank holds the number of pins
> and the register offsets.
>
> All functions accessing a pin now use a pointer to a bank structure and
> an offset inside that bank. The conversion from a pin number to a bank
> and an offset is done in the new function eq5p_pin_to_bank_offset(),
> which replace eq5p_pin_to_bank() and eq5p_pin_to_offset().
>
> All the data related to the EyeQ5 is declared with the eq5p_eyeq5_
> prefix to distinguish it from the common code.
>
> During the probe, we use the parent OF node to get the match data.
> We cannot directly use an OF node since pinctrl-eyeq5 is an auxiliary
> device of clk-eyeq.
>
> Signed-off-by: Benoît Monin <benoit.monin@xxxxxxxxxxx>
Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>
Yours,
Linus Walleij