From: David Gibson <david@gibson.dropbear.id.au>
To: Greg Kurz <groug@kaod.org>
Cc: qemu-devel@nongnu.org, qemu-ppc@nongnu.org,
Cedric Le Goater <clg@kaod.org>
Subject: Re: [Qemu-devel] [PATCH v2] spapr: fix LSI interrupt specifiers in the device tree
Date: Wed, 6 Dec 2017 11:25:44 +1100 [thread overview]
Message-ID: <20171206002544.GQ3057@umbus.fritz.box> (raw)
In-Reply-To: <151239850618.30749.18071098158203257789.stgit@bahia.lan>
[-- Attachment #1: Type: text/plain, Size: 1877 bytes --]
On Mon, Dec 04, 2017 at 03:41:46PM +0100, Greg Kurz wrote:
> PAPR 2.7 C.6.9.1.2 describes the "#interrupt-cells" property of the
> PowerPC External Interrupt Source Controller node as follows:
>
> “#interrupt-cells”
>
> Standard property name to define the number of cells in an interrupt-
> specifier within an interrupt domain.
>
> prop-encoded-array: An integer, encoded as with encode-int, that denotes
> the number of cells required to represent an interrupt specifier in its
> child nodes.
>
> The value of this property for the PowerPC External Interrupt option shall
> be 2. Thus all interrupt specifiers (as used in the standard “interrupts”
> property) shall consist of two cells, each containing an integer encoded
> as with encode-int. The first integer represents the interrupt number the
> second integer is the trigger code: 0 for edge triggered, 1 for level
> triggered.
>
> This patch fixes the interrupt specifiers in the "interrupt-map" property
> of the PHB node, that were setting the second cell to 8 (confusion with
> IRQ_TYPE_LEVEL_LOW ?) instead of 1.
>
> VIO devices and RTAS event sources use the same format for interrupt
> specifiers: while here, we introduce a common helper to handle the
> encoding details.
>
> Signed-off-by: Greg Kurz <groug@kaod.org>
> Reviewed-by: Cédric Le Goater <clg@kaod.org>
> Tested-by: Cédric Le Goater <clg@kaod.org>
Looks good, but I'd request two minor changes.
1) Please reference LoPAPR instead of the internal PAPR, since other
people can't see it.
2) Change the helper's name to spapr_dt_xics_irq(), for both brevity
and specificity.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2017-12-06 0:25 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-04 14:41 [Qemu-devel] [PATCH v2] spapr: fix LSI interrupt specifiers in the device tree Greg Kurz
2017-12-06 0:25 ` David Gibson [this message]
2017-12-06 6:49 ` Greg Kurz
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=20171206002544.GQ3057@umbus.fritz.box \
--to=david@gibson.dropbear.id.au \
--cc=clg@kaod.org \
--cc=groug@kaod.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
/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).