linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Marc Zyngier <maz@kernel.org>
To: "Lad, Prabhakar" <prabhakar.csengg@gmail.com>
Cc: Geert Uytterhoeven <geert+renesas@glider.be>,
	LAK <linux-arm-kernel@lists.infradead.org>
Subject: Re: [QUERY]: Acknowledgment of edge triggered interrupts
Date: Mon, 02 May 2022 10:44:50 +0100	[thread overview]
Message-ID: <87levki7zh.wl-maz@kernel.org> (raw)
In-Reply-To: <CA+V-a8va6YCtjswPVZvwBxZigpHfFpGOi5C2R7e5H49LpNWCYw@mail.gmail.com>

On Sat, 30 Apr 2022 19:41:24 +0100,
"Lad, Prabhakar" <prabhakar.csengg@gmail.com> wrote:
> 
> Hi Marc,
> 
> I am currently working on the irq-sifive-plic.c driver. The
> irq-sifive-plic.c driver is currently implemented as a chained domain.
> On our SoC which uses this block for EDGE interrupts we need to first
> acknowledge the interrupt before handling it.

Isn't that what the CLAIM register does on the PLIC? AFAICT, this
interrupt controller is able to implement the whole flow, irrespective
of the trigger mechanism.

The spec strongly hints at that, see [1] ("Interrupt gateways"), and
the uniform handling that results of it. In a way, this is strikingly
similar to what the original ARM GIC does.

[1] https://github.com/riscv/riscv-plic-spec/blob/master/riscv-plic.adoc

> 
> I came across a similar situation on a different driver (patch [0])
> but it isn't a chained handler.
> 
> What approach should be taken for chained IRQ domains to handle such cases?

I don't think there is anything to change. At least, as long as the
Interrupt Gateway is doing its job correctly. How this gateway is
configured is unfortunately out of the scope of the architecture, it
seems, and I'd expect your HW to have some sort of knobs for the
trigger type to be configured. This would be dealt with in a separate
stacked driver.

Thanks,

	M.

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

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-05-02  9:45 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-30 18:41 [QUERY]: Acknowledgment of edge triggered interrupts Lad, Prabhakar
2022-05-02  9:44 ` Marc Zyngier [this message]
2022-05-06 11:24   ` Lad, Prabhakar
2022-05-06 12:18     ` Marc Zyngier
2022-05-07  5:31       ` Lad, Prabhakar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87levki7zh.wl-maz@kernel.org \
    --to=maz@kernel.org \
    --cc=geert+renesas@glider.be \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=prabhakar.csengg@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).