Re: [PATCH 2/3] pinctrl: mediatek: Add acpi support

From: Linus Walleij

Date: Wed Nov 26 2025 - 04:10:27 EST


On Tue, Nov 25, 2025 at 3:36 AM Lei Xue <lei.xue@xxxxxxxxxxxx> wrote:

> Add acpi support in the common part of pinctrl driver. Parsing
> hardware base addresses and irq number to initialize eint
> accroding to the acpi table data.
>
> Signed-off-by: Lei Xue <lei.xue@xxxxxxxxxxxx>

I'd ideally like Andy and the ARM64 ACPI maintainers look on
this. (Added to To:) and CC linux-acpi@xxxxxxxxxxxxxxx.

I'm not aware of the best way to deal with ACPI in combined drivers
but things like this:

> - hw->base[i] = devm_platform_ioremap_resource_byname(pdev,
> - hw->soc->base_names[i]);
> + hw->base[i] = is_of_node(fwnode)
> + ? devm_platform_ioremap_resource_byname(pdev, hw->soc->base_names[i])
> + : devm_platform_get_and_ioremap_resource(pdev, i, NULL);

Just look really quirky, I think there are better ways to go about
this and sometimes the ACPI maintainers give some good
pushback about the firmware as well.

Yours,
Linus Walleij