RE: [PATCH v3 2/2] irqchip/aspeed-intc: Add support for AST27XX INTC

From: Markus Elfring
Date: Tue Oct 15 2024 - 11:08:26 EST



> > > +static void aspeed_intc_ic_irq_handler(struct irq_desc *desc) {

> > > + guard(chained_irq)(desc);
> >
> > Using another macro call “scoped_guard(…) { … }”?
> Is it necessary to use scoped_guard(...) {...}?

It depends on corresponding case disintions.


> > > + scoped_guard(raw_spinlock, &intc_ic->gic_lock) {
> >
> > Would you like to reconsider the proposed macro mixture once more?
> Could I check the reason for once more?

Coding style concerns …?


> > > +++ b/include/linux/irqchip/chained_irq.h
> > > @@ -38,4 +38,6 @@ static inline void chained_irq_exit(struct irq_chip *chip,
> > > chip->irq_unmask(&desc->irq_data);
> > > }
> > >
> > > +DEFINE_GUARD(chained_irq, struct irq_desc *,
> > chained_irq_exit((_T->irq_data.chip), (_T)),
> > > + chained_irq_enter((_T->irq_data.chip), (_T)))
> >
> > Would you like to add a #include directive in this header file accordingly?
> Can you give me an example?

See also:
https://elixir.bootlin.com/linux/v6.12-rc3/source/include/linux/device.h#L33

Regards,
Markus