From patchwork Wed Mar 21 16:32:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andre Przywara X-Patchwork-Id: 132238 Delivered-To: patch@linaro.org Received: by 10.46.84.29 with SMTP id i29csp2356177ljb; Wed, 21 Mar 2018 09:35:06 -0700 (PDT) X-Google-Smtp-Source: AG47ELtbs7k5xNNRZoAArwgiDAZ5/NmsX6Ouho0PaoGsD1pIpeo/V2WEGxk+6jfMqy/+iOMhzqoS X-Received: by 10.107.11.91 with SMTP id v88mr22805089ioi.28.1521650106013; Wed, 21 Mar 2018 09:35:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521650106; cv=none; d=google.com; s=arc-20160816; b=pMxQBJx+jkC3H+/cXsB/IzxbwR331uLTu2vioggExDJH3dHNxWrQ0OGGdQoIjFrpyy XqH2HJRkO3lTw2S5m5v39WFOsYYlW9zLNcHv5jznbymEGBmAXl6aomA1mNfCzDrGI4Xj 9pIoesJRa3DMvGGTWr79R1oNq3D+pH7fkpV4ju/2wjUXTDaz/h8qTrC2vmmayOZz0h4z DY8+ieq9p0xBwIt+zGs0bzG0OtguJ6RsO3MUp+ifi365G3AqRp+FvE+echq/ecWImkcn OOc/QiXDTp4Vk3ufPoOEURdv5LPkbN8r69grJK+OI3tL0cS84ITDi+dl4ucXLp7aHOHD 7n9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc :list-subscribe:list-help:list-post:list-unsubscribe:list-id :precedence:subject:references:in-reply-to:message-id:date:to:from :dkim-signature:arc-authentication-results; bh=w+ryh0V/sZt9hJGxrcEdh/i65PFc05E3EXj664gwD1c=; b=UlUgaAq/9ZixDYNwX7zF3C4xfAC02RH7+wYDGa/EnRoCLlpViJT646scraZ9kFONeR dIjI1hs8EZq+bdbZfQYXzt+D+5VD2ffae55YpQJfJL7x67K+vP/OMDx70WgDo4aubxr2 RBhkyIyzGDwB6U0RiswAZF5oIE894FXifqCH8E7xe4KmSgWaKB15w4Beo+IcBWeFjOCx rWT5dSl6avf5cBE0DJTXfxTKBNbscF6dl98MOm9xcbK+oiY5/Lv4fZyFHC65ZP9yC0uh hu/5i4eGMaOWj3HcQBbk+t5wKVDPj8STXZ3s0YSwzuZg6jX326b5levieIDqs40TCR/P r/cw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=WmXEdbYZ; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id l89si3521110iod.183.2018.03.21.09.35.05 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 21 Mar 2018 09:35:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=WmXEdbYZ; spf=pass (google.com: best guess record for domain of xen-devel-bounces@lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1eygfb-00025n-A0; Wed, 21 Mar 2018 16:32:59 +0000 Received: from us1-rack-dfw2.inumbo.com ([104.130.134.6]) by lists.xenproject.org with esmtp (Exim 4.89) (envelope-from ) id 1eygfa-00024L-4i for xen-devel@lists.xenproject.org; Wed, 21 Mar 2018 16:32:58 +0000 X-Inumbo-ID: 79904477-2d25-11e8-9728-bc764e045a96 Received: from mail-wm0-x241.google.com (unknown [2a00:1450:400c:c09::241]) by us1-rack-dfw2.inumbo.com (Halon) with ESMTPS id 79904477-2d25-11e8-9728-bc764e045a96; Wed, 21 Mar 2018 17:32:42 +0100 (CET) Received: by mail-wm0-x241.google.com with SMTP id i189so7155253wmf.0 for ; Wed, 21 Mar 2018 09:32:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=zEX0lJCp7L8dsul0/9low6LiAjaLb3uf5MoCHYTWjwM=; b=WmXEdbYZXeMuEPYxlk6jLO3MZrGNMNyr2RAS+OfM2xEPXw62vGnrto39gNh7a44ILM gudLGt6j3faKKWirM9tpgxDI2UQFUrfyCeR9sdsqKcJGg9siaZ2Fpy5sQHM3GebG3k1J zwL9qHkjlrDYCvJhb6Fki285yS+FiSCY7KHjs= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=zEX0lJCp7L8dsul0/9low6LiAjaLb3uf5MoCHYTWjwM=; b=uVmuGVS/E4EU4QuLVzmNz0VjMsYdOUuaMD8hsE06J+6kNd906HN0aDLb/gY9+FSyLs cgzNRsfP+T8bbHVyQBn0+8BDFTUuxnTzX1b5JnZUhsLOKNU6wFzay5AsJuspCdT0AUuN vPgxP4AH2eKNUZLjOidnl40Ty8UFj3DtYQPSQ2B0fvp+mQkgx/3cWTbAqgMf2jdNk/2u kyX9ljVidW8Qh37cHE0XxXzXBFbxpCj3j7ZE9dyr7HSLWwlKK7eUwAbVnldH/GCmxDIh G71m1+Zf/8G3KcZxfyHxSkk3dIKv1x2BXDBSgNAfz7/dlCUYSXqjmDGX7qrwVqXcZTtP yePQ== X-Gm-Message-State: AElRT7GmMebTRGSpAar4dLQtwdVXZEWvlMv7NeIDGkdlyqHenKt5vWhY uTIJFq6wh3QcTG7DigA84SfScvic8js= X-Received: by 10.28.114.20 with SMTP id n20mr1443490wmc.56.1521649975387; Wed, 21 Mar 2018 09:32:55 -0700 (PDT) Received: from e104803-lin.lan (mail.andrep.de. [217.160.17.100]) by smtp.gmail.com with ESMTPSA id n64sm4423724wmd.11.2018.03.21.09.32.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 21 Mar 2018 09:32:54 -0700 (PDT) From: Andre Przywara To: Julien Grall , Stefano Stabellini Date: Wed, 21 Mar 2018 16:32:03 +0000 Message-Id: <20180321163235.12529-8-andre.przywara@linaro.org> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180321163235.12529-1-andre.przywara@linaro.org> References: <20180321163235.12529-1-andre.przywara@linaro.org> Subject: [Xen-devel] [PATCH v3 07/39] ARM: vPL011: Use the VGIC's level triggered IRQs handling if available X-BeenThere: xen-devel@lists.xenproject.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Cc: xen-devel@lists.xenproject.org, Andre Przywara MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xenproject.org Sender: "Xen-devel" The emulated ARM SBSA UART is using level triggered IRQ semantics, however the current VGIC can only handle edge triggered IRQs, really. Disable the existing workaround for this problem in case we have the new VGIC in place, which can properly handle level triggered IRQs. Signed-off-by: Andre Przywara Reviewed-by: Julien Grall Acked-by: Stefano Stabellini --- xen/arch/arm/vpl011.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/xen/arch/arm/vpl011.c b/xen/arch/arm/vpl011.c index 5dcf4bec18..a281eabd7e 100644 --- a/xen/arch/arm/vpl011.c +++ b/xen/arch/arm/vpl011.c @@ -54,6 +54,7 @@ static void vpl011_update_interrupt_status(struct domain *d) */ ASSERT(spin_is_locked(&vpl011->lock)); +#ifndef CONFIG_NEW_VGIC /* * TODO: PL011 interrupts are level triggered which means * that interrupt needs to be set/clear instead of being @@ -71,6 +72,9 @@ static void vpl011_update_interrupt_status(struct domain *d) vgic_inject_irq(d, NULL, GUEST_VPL011_SPI, true); vpl011->shadow_uartmis = uartmis; +#else + vgic_inject_irq(d, NULL, GUEST_VPL011_SPI, uartmis); +#endif } static uint8_t vpl011_read_data(struct domain *d)