From patchwork Mon Apr 11 13:33:33 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 65518 Delivered-To: patch@linaro.org Received: by 10.112.43.237 with SMTP id z13csp1477318lbl; Mon, 11 Apr 2016 06:35:31 -0700 (PDT) X-Received: by 10.176.64.227 with SMTP id i90mr11581298uad.62.1460381715878; Mon, 11 Apr 2016 06:35:15 -0700 (PDT) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id 53si5857355uaf.151.2016.04.11.06.35.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 11 Apr 2016 06:35:15 -0700 (PDT) Received-SPF: neutral (google.com: 192.237.175.120 is neither permitted nor denied by best guess record for domain of xen-devel-bounces@lists.xen.org) client-ip=192.237.175.120; Authentication-Results: mx.google.com; spf=neutral (google.com: 192.237.175.120 is neither permitted nor denied by best guess record for domain of xen-devel-bounces@lists.xen.org) smtp.mailfrom=xen-devel-bounces@lists.xen.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1apbyN-0004w0-2q; Mon, 11 Apr 2016 13:33:47 +0000 Received: from mail6.bemta14.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1apbyL-0004vY-T0 for xen-devel@lists.xen.org; Mon, 11 Apr 2016 13:33:45 +0000 Received: from [193.109.254.147] by server-12.bemta-14.messagelabs.com id FE/B5-13115-9B7AB075; Mon, 11 Apr 2016 13:33:45 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrCLMWRWlGSWpSXmKPExsVysyfVTXfHcu5 wg1u7dSyWfFzM4sDocXT3b6YAxijWzLyk/IoE1oypa7exFnzhrPi4mrOBsYuji5GLQ0hgE6PE gn93mSGc04wS3b2H2boYOTnYBDQl7nz+xARiiwhIS1z7fJkRxGYWiJJYv6mbFcQWFkiS+HXzO VgNi4CqxO8dP8BsXgFniQXzLrOD2BICchInj00Gq+cUcJFYeP4TkM0BtMxZonlW8ARG7gWMDK sY1YtTi8pSi3SN9JKKMtMzSnITM3N0DQ1N9HJTi4sT01NzEpOK9ZLzczcxAn3LAAQ7GFvmOB9 ilORgUhLl3TmfO1yILyk/pTIjsTgjvqg0J7X4EKMMB4eSBK8WMFSEBItS01Mr0jJzgEEGk5bg 4FES4b25DCjNW1yQmFucmQ6ROsWoKCXO+w4kIQCSyCjNg2uDBfYlRlkpYV5GoEOEeApSi3IzS 1DlXzGKczAqCfNKg2znycwrgZv+CmgxE9DiZ/84QRaXJCKkpBoYuZMX/In9/3kyx4weo2XVlu ff1e3g9VuavuDqg5XMV2bceryaKU1ows6rrru3J8jPeCyZ8iXz5LzcqS8k3ywWcjHNuz2P0+J 59cs91WwdM0OtZ7x5O6M6TEf01jPtqBppy6klwnN2f3op3PvYXOrDvCeHQnZN004RznBwMbtV FCT76lFf2IlpakosxRmJhlrMRcWJALhif2hnAgAA X-Env-Sender: julien.grall@arm.com X-Msg-Ref: server-8.tower-27.messagelabs.com!1460381624!31126928!1 X-Originating-IP: [217.140.101.70] X-SpamReason: No, hits=0.0 required=7.0 tests= X-StarScan-Received: X-StarScan-Version: 8.28; banners=-,-,- X-VirusChecked: Checked Received: (qmail 37618 invoked from network); 11 Apr 2016 13:33:44 -0000 Received: from foss.arm.com (HELO foss.arm.com) (217.140.101.70) by server-8.tower-27.messagelabs.com with SMTP; 11 Apr 2016 13:33:44 -0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id BDC9046B; Mon, 11 Apr 2016 06:32:30 -0700 (PDT) Received: from e108454-lin.cambridge.arm.com (e108454-lin.cambridge.arm.com [10.1.215.28]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id E35FC3F21A; Mon, 11 Apr 2016 06:33:42 -0700 (PDT) From: Julien Grall To: xen-devel@lists.xen.org Date: Mon, 11 Apr 2016 14:33:33 +0100 Message-Id: <1460381617-5786-2-git-send-email-julien.grall@arm.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1460381617-5786-1-git-send-email-julien.grall@arm.com> References: <1460381617-5786-1-git-send-email-julien.grall@arm.com> Cc: Julien Grall , sstabellini@kernel.org, shannon.zhao@linaro.org Subject: [Xen-devel] [for-4.7 v2 1/5] drivers/pl011: ACPI: The interrupt should always be high level triggered X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" 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 --- 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);