xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Julien Grall <julien.grall@arm.com>
To: xen-devel@lists.xen.org
Cc: Julien Grall <julien.grall@arm.com>,
	sstabellini@kernel.org, shannon.zhao@linaro.org
Subject: [for-4.7 v2 1/5] drivers/pl011: ACPI: The interrupt should always be high level triggered
Date: Mon, 11 Apr 2016 14:33:33 +0100	[thread overview]
Message-ID: <1460381617-5786-2-git-send-email-julien.grall@arm.com> (raw)
In-Reply-To: <1460381617-5786-1-git-send-email-julien.grall@arm.com>

The SPCR does not specify if the interrupt is edge or level triggered.
So the configuration needs to be hardcoded in the code.

Based on the PL011 TRM (see 2.2.8 in ARM DDI 0183G), the interrupt generated
will be active high. Whilst the wording may be interpreted differently,
the SBSA (section 4.3.2 in ARM-DEN-0029 v2.3) states the PL011 is
implemented with a level triggered interrupt.

So the driver should configure the interrupt as high level triggered.

Signed-off-by: Julien Grall <julien.grall@arm.com>

---
    Changes in v2:
        - Update the commit message
        - Effictively configure the interrupt high level triggered
---
 xen/drivers/char/pl011.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/drivers/char/pl011.c b/xen/drivers/char/pl011.c
index fa22edf..1212d5c 100644
--- a/xen/drivers/char/pl011.c
+++ b/xen/drivers/char/pl011.c
@@ -327,7 +327,7 @@ static int __init pl011_acpi_uart_init(const void *data)
     }
 
     /* trigger/polarity information is not available in spcr */
-    irq_set_type(spcr->interrupt, IRQ_TYPE_EDGE_BOTH);
+    irq_set_type(spcr->interrupt, IRQ_TYPE_LEVEL_HIGH);
 
     res = pl011_uart_init(spcr->interrupt, spcr->serial_port.address,
                           PAGE_SIZE);
-- 
1.9.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

  reply	other threads:[~2016-04-11 13:33 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-11 13:33 [for-4.7 v2 0/5] xen/arm: acpi: Bunch of fixes to use ACPI with SMP and PL011 Julien Grall
2016-04-11 13:33 ` Julien Grall [this message]
2016-04-11 14:07   ` [for-4.7 v2 1/5] drivers/pl011: ACPI: The interrupt should always be high level triggered Konrad Rzeszutek Wilk
2016-04-11 18:16     ` Stefano Stabellini
2016-04-12  1:00     ` Shannon Zhao
2016-04-12 13:34       ` Konrad Rzeszutek Wilk
2016-04-11 13:33 ` [for-4.7 v2 2/5] xen/arm: acpi: The boot CPU does not always match the first entry in the MADT Julien Grall
2016-04-11 14:09   ` Konrad Rzeszutek Wilk
2016-04-11 18:15   ` Stefano Stabellini
2016-04-11 13:33 ` [for-4.7 v2 3/5] xen/arm: acpi: Fix SMP support when booting with ACPI Julien Grall
2016-04-11 14:09   ` Konrad Rzeszutek Wilk
2016-04-11 13:33 ` [for-4.7 v2 4/5] xen/arm: acpi: Remove uncessary check in acpi_map_gic_cpu_interface Julien Grall
2016-04-11 14:09   ` Konrad Rzeszutek Wilk
2016-04-11 13:33 ` [for-4.7 v2 5/5] xen/arm: acpi: Print more error messages " Julien Grall
2016-04-11 14:10   ` Konrad Rzeszutek Wilk
2016-04-11 14:04 ` [for-4.7 v2 0/5] xen/arm: acpi: Bunch of fixes to use ACPI with SMP and PL011 Wei Liu

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=1460381617-5786-2-git-send-email-julien.grall@arm.com \
    --to=julien.grall@arm.com \
    --cc=shannon.zhao@linaro.org \
    --cc=sstabellini@kernel.org \
    --cc=xen-devel@lists.xen.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).