Re: [PATCH] gpio: uniphier: add UniPhier GPIO controller driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Thu, Aug 3, 2017 at 1:06 PM, Masahiro Yamada
<yamada.masahiro@xxxxxxxxxxxxx> wrote:

> This GPIO controller device is used on UniPhier SoCs.
>
> Signed-off-by: Masahiro Yamada <yamada.masahiro@xxxxxxxxxxxxx>
(...)
> +static const u32 uniphier_gpio_irq_parent_hwirqs[] = {
> +       80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95,
> +       186, 187, 188, 189, 190, 249, 250, 251,
> +};
(..)
> +               /* parent is UniPhier AIDET */
> +               parent_fwspec.fwnode = domain->parent->fwnode;
> +               parent_fwspec.param_count = 2;
> +               parent_fwspec.param[0] = uniphier_gpio_irq_parent_hwirqs[hwirq];
> +               parent_fwspec.param[1] = type;
> +
> +               ret = irq_domain_alloc_irqs_parent(domain, virq, 1,
> +                                                  &parent_fwspec);

This is not right.

That parent IRQ needs to come from the device tree, not from a static array
like this, and it is definately to use hierarchical irqdomain.

Please look at similar drivers merged recently for inspiration:
gpio/gpio-xgene-sb.c
pinctrl/stm32/pinctrl-stm32.c

Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux