From patchwork Tue Feb 6 17:08:56 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andre Przywara X-Patchwork-Id: 127057 Delivered-To: patch@linaro.org Received: by 10.46.124.24 with SMTP id x24csp3107634ljc; Tue, 6 Feb 2018 09:11:21 -0800 (PST) X-Google-Smtp-Source: AH8x224ceSV/Ghq2EV23K0H+6oQDZ5Zaq3S9a2X6N43nkjtHP+afBBdg5m5tOqZ71sx+ZhQZR+Lp X-Received: by 10.36.169.4 with SMTP id r4mr3762316ite.93.1517937080996; Tue, 06 Feb 2018 09:11:20 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517937080; cv=none; d=google.com; s=arc-20160816; b=0xWlz5RNP53l1slFYaGAOeo1iJuZktuWfK1hCQOE9KFdWb/rgo0k+gKasZkh5QqHAf qRcV7304NEBhndDNy1jUhnjam0LiDsm5IbBLNEZFV9y9Pm157P7yy223BCPHIawj0asM rY4IXHC67voHR3c/Hm3qME5owblfW7RiThkn20Dx6ISbkrL+K17A95FxN1eTNAoBzbJN 8YBZq67CvyV4CpW8Ly1rlhR0X8m0PV17lxldXKG6spxmRfYnBzo2/Zdpw0w5ob10RtSA /M2CMWtiVt/v0lE8BZR8e8S5L1MUchuSg03T5OxFr1H0ve7GYAOlgIDgZCx9Zrzao0u+ 9Meg== 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 :list-subscribe:list-help:list-post:list-unsubscribe:list-id :precedence:subject:cc:references:in-reply-to:message-id:date:to :from:dkim-signature:arc-authentication-results; bh=RfI/r7OXWKUYIygLaFgGliDYF/r/BwEZD5aCoBfc0Ek=; b=AE9ShHz249hHnjn//GzgZQkvTGhHm+zX78Qq6GesRkUsBJSYwuL+IPYJR/3VwcmKcS 9L13FFOVrjC1pWL7G1lWo0DXSw17dGPnWmpanM6giRIcHw8j+oWn3LDlXmpjVn+mYG1d obwriaz2iXyVFFWV3Te/I6h1WWK1M7ihwEn/Dvu5jUI8iD2A3WZUpc7VCitUrPVG/pFa qM7vzT88kvFM5VKOj4nPNWWnJzbLJJ2FiGhxflnfvBmR12+AhixjlaOkvYqpraTRLMyM ErZ3Lc5Vx2LAbgWY/NYihuFxmqqXLmWHQxxgBvCBFl/jgv1xeNknqjo8edANhmEdtD/x YLXQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=Aod0sxU2; 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 u185si8232012ioe.331.2018.02.06.09.11.20 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 06 Feb 2018 09:11:20 -0800 (PST) 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=Aod0sxU2; 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.84_2) (envelope-from ) id 1ej6k5-0003ln-Hz; Tue, 06 Feb 2018 17:09:13 +0000 Received: from us1-rack-dfw2.inumbo.com ([104.130.134.6]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ej6k4-0003lD-Jq for xen-devel@lists.xenproject.org; Tue, 06 Feb 2018 17:09:12 +0000 X-Inumbo-ID: 64eded88-0b60-11e8-ba59-bc764e045a96 Received: from mail-wr0-x242.google.com (unknown [2a00:1450:400c:c0c::242]) by us1-rack-dfw2.inumbo.com (Halon) with ESMTPS id 64eded88-0b60-11e8-ba59-bc764e045a96; Tue, 06 Feb 2018 18:08:48 +0100 (CET) Received: by mail-wr0-x242.google.com with SMTP id s5so2739013wra.0 for ; Tue, 06 Feb 2018 09:09:11 -0800 (PST) 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=3yiPzOkdGMsoROSLIUAGyb8fRfKOWy88pZwZOIGaNgs=; b=Aod0sxU2ISS5DpGzS2AIIr99ibY6185UNg0ufhhoahdXw2YkoghPaUAdlhTvtfJjek 8XWUxSWe5YF2Q01grdgu8HTXvaxLqzpt4MJIMUcYzvgbg7IFh2xBq1ZCkaEFHB4xES5b 4bCBwAGAaLSiSBtsu8ZQoKJDBhDdFu7dQ+tdU= 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=3yiPzOkdGMsoROSLIUAGyb8fRfKOWy88pZwZOIGaNgs=; b=EMkF9fylSpgnNlaw7YHnjE4tGaFvd0WKbIwKo5aYoiPyYUQcU+gQ0ATyBQVdrBEwF6 3voBTg2RdiKzhwK6sRaGVnur1Lovtx7Kab9bqIp/SDRRhIonHAFwFoZMn4hawSXygOp2 M5MUUH3gEdKYvC+XBE54/lvc6F1mtjx5AQ7tRJoaDGCzOqosntDctTKRaKvJnDkvaQlf P0DMNegfTiBfRRxLtTy21TZ4lS75eteCzj2JS0V7sdSTgfiQyR5ssE5i265QfmXEekzz cnnyIbx8pkuzHAWlBtaK6THJL5HSCAsZlH4YzKwxdap0zvNHsD9lVunFN+7re4VhrwtO tzcQ== X-Gm-Message-State: APf1xPBw57+k7hq8p1kQ7kR3/BxTSAdwPo8eOHsaDWvHhfr27Hy7C1nm R+s3a/wglkzQ57cRiv1GIGTe+A== X-Received: by 10.223.183.27 with SMTP id l27mr3052653wre.181.1517936950576; Tue, 06 Feb 2018 09:09:10 -0800 (PST) Received: from e104803-lin.lan (mail.andrep.de. [217.160.17.100]) by smtp.gmail.com with ESMTPSA id n2sm7885819wra.41.2018.02.06.09.09.09 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 06 Feb 2018 09:09:10 -0800 (PST) From: Andre Przywara To: Julien Grall , Stefano Stabellini Date: Tue, 6 Feb 2018 17:08:56 +0000 Message-Id: <20180206170903.30637-2-andre.przywara@linaro.org> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20180206170903.30637-1-andre.przywara@linaro.org> References: <20180206170903.30637-1-andre.przywara@linaro.org> Cc: xen-devel@lists.xenproject.org Subject: [Xen-devel] [PATCH v5 1/8] ARM: VGIC: drop unneeded gic_restore_pending_irqs() X-BeenThere: xen-devel@lists.xenproject.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.xenproject.org Sender: "Xen-devel" In gic_restore_pending_irqs() we push our pending virtual IRQs into the list registers. This function is called once from gic_inject(), just before we return to the guest, but also in gic_restore_state(), when we context-switch a VCPU. Having a closer look it turns out that the later call is not needed, since we will always call gic_inject() anyway. So remove that call (and the forward declaration) to streamline this interface and make separating the GIC from the VGIC world later. Signed-off-by: Andre Przywara Reviewed-by: Julien Grall Reviewed-by: Stefano Stabellini --- xen/arch/arm/gic.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/xen/arch/arm/gic.c b/xen/arch/arm/gic.c index bac8ada2bb..721a17a9d7 100644 --- a/xen/arch/arm/gic.c +++ b/xen/arch/arm/gic.c @@ -36,8 +36,6 @@ #include #include -static void gic_restore_pending_irqs(struct vcpu *v); - static DEFINE_PER_CPU(uint64_t, lr_mask); #define lr_all_full() (this_cpu(lr_mask) == ((1 << gic_hw_ops->info->nr_lrs) - 1)) @@ -91,8 +89,6 @@ void gic_restore_state(struct vcpu *v) gic_hw_ops->restore_state(v); isb(); - - gic_restore_pending_irqs(v); } /* desc->irq needs to be disabled before calling this function */