Re: [PATCH v3 4/8] of: unittest: Test fw_devlink with GPIO nexus maps
From: Herve Codina
Date: Tue Oct 20 2026 - 10:28:11 EST
Hi Ernest,
On Tue, 20 Oct 2026 15:00:15 +0200
Ernest Van Hoecke <ernestvanhoecke@xxxxxxxxx> wrote:
> From: Ernest Van Hoecke <ernest.vanhoecke@xxxxxxxxxxx>
>
> Add OF unit tests that call the fw_devlink add_links operation for GPIOs
> routed through nexus maps. Verify that each mapped consumer has exactly
> one link to the final GPIO provider rather than to the nexus.
>
> Also cover direct references and all GPIO property spellings recognized
> by fw_devlink, including the deprecated singular and unprefixed forms.
>
> The gpio-map routes its entries to different providers so that selecting
> the wrong entry is caught as well.
>
> Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxxxxxxxx>
> Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>
> Signed-off-by: Ernest Van Hoecke <ernest.vanhoecke@xxxxxxxxxxx>
> ---
> v3: Route gpio-map entries to two providers, use a middle entry (Herve)
> v2: https://lore.kernel.org/r/20260910-fw-devlink-nexus-ready-v2-3-17ac82dbe226@xxxxxxxxxxx
> ---
> drivers/of/unittest-data/tests-phandle.dtsi | 39 +++++++++++++++
> drivers/of/unittest.c | 75 +++++++++++++++++++++++++++++
> 2 files changed, 114 insertions(+)
>
Reviewed-by: Herve Codina <herve.codina@xxxxxxxxxxx>
Best regards,
Hervé