Re: [PATCH v6 04/15] spmi: pmic-arb: convert to v2 irq interfaces to support hierarchical IRQ chips

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

 



On Sat, 19 Jan 2019 20:42:41 +0000,
Brian Masney <masneyb@xxxxxxxxxxxxx> wrote:
> 
> Convert the spmi-pmic-arb IRQ code to use the version 2 IRQ interface
> in order to support hierarchical IRQ chips. This is necessary so that
> spmi-gpio can be setup as a hierarchical IRQ chip with pmic-arb as the
> parent. IRQ chips in device tree should be usable from the start without
> the consumer having to make an additional call to gpio[d]_to_irq() to
> get the proper IRQ on the parent.
> 
> The old qpnpint_irq_domain_map function would hardcode the handler as
> handle_level_irq, however qpnpint_irq_set_type would later override the
> handler. Properly set the handler when the IRQ is mapped. This new code
> doesn't return an error for IRQ_TYPE_NONE and preserves the existing
> behavior of using handle_level_irq since there are some broken device
> tree bindings that need to be corrected first.
> 
> Driver was tested on a LG Nexus 5 (hammerhead) phone.
> 
> Signed-off-by: Brian Masney <masneyb@xxxxxxxxxxxxx>
> ---
> The broken device tree bindings are corrected in this patch series and
> additional validation to the type field is added later in the series.
> 
> Changes since v5:
> - Properly set handler to edge or level when the IRQ is mapped.
> 
> Changes since v4:
> - None
> 
> Changes since v3:
> - None
> 
> Changes since v2:
> - Don't move pmic_gpio_of_match block. Use device_get_match_data instead
>   of of_match_device.
> - Correct build warning on arm64: warning: cast from pointer to integer
>   of different size
> 
>  drivers/spmi/spmi-pmic-arb.c | 67 +++++++++++++++++++++++++-----------
>  1 file changed, 47 insertions(+), 20 deletions(-)

Reviewed-by: Marc Zyngier <marc.zyngier@xxxxxxx>

Thanks,

	M.

-- 
Jazz is not dead, it just smell funny.



[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