Re: [RFC PATCH v4 2/5] irqchip: Add RZ/G2L IA55 Interrupt Controller driver

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

 



On Fri, 18 Mar 2022 14:59:41 +0000,
"Lad, Prabhakar" <prabhakar.csengg@xxxxxxxxx> wrote:
> 
> Hi Marc,
> 
> Thank you for the review.
> 
> On Thu, Mar 17, 2022 at 4:13 PM Marc Zyngier <maz@xxxxxxxxxx> wrote:
> >
> > On Thu, 17 Mar 2022 01:24:01 +0000,
> > Lad Prabhakar <prabhakar.mahadev-lad.rj@xxxxxxxxxxxxxx> wrote:
> > >
> > > +static struct irq_chip irqc_chip = {
> > > +     .name                   = "rzg2l-irqc",
> > > +     .irq_eoi                = rzg2l_irqc_eoi,
> > > +     .irq_mask               = irq_chip_mask_parent,
> > > +     .irq_unmask             = irq_chip_unmask_parent,
> > > +     .irq_disable            = rzg2l_irqc_irq_disable,
> > > +     .irq_enable             = rzg2l_irqc_irq_enable,
> >
> > So this looks a bit odd. irq_mask only calls the parent and does nothing
> > locally, while irq_disable does something locally and calls into the
> > parent. If the parent is a GIC, this is turned into a mask (GIC has no
> > notion of disabled).
> >
> My understanding for enable callback is one time call during irq setup
> and for the disable callback it will be called during irq shutdown.
> During enable/disable callback we config the required registers.
> For mask callback this will be called when an interrupt occurs and for
> unmask we want to re-enable the interrupt. Since there are no specific
> registers to mask/unmask on RZ/G2L the callbacks point to
> irq_chip_mask_parent/irq_chip_unmask_parent.
> 
> I could move all the code from enable/disable callbacks to mask/unmask
> callbacks and drop setting irq_enable/irq_disable completely. Please
> let me know what should be the correct approach.

I'm OK with your current setup, but I just wanted to check that this
was your understanding as well.

	M.

-- 
Without deviation from the norm, progress is not possible.



[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