Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp7260434imm; Tue, 28 Aug 2018 08:56:55 -0700 (PDT) X-Google-Smtp-Source: ANB0VdaTXRCckm9duLICBrpvCQfCRufc3XWfZC//cIYJykgc0DoDEMf2K45al9VVALSTNgqp2kX8 X-Received: by 2002:a17:902:4906:: with SMTP id u6-v6mr2138915pld.44.1535471814993; Tue, 28 Aug 2018 08:56:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535471814; cv=none; d=google.com; s=arc-20160816; b=mMkaN3HTMqjInFFX3ouKZ5a6d4j+83dROjNCR3qrDcEePCcWldZF4EhPIF6N8zUD4P fnKpub3lA4C/L3dUPUk8HPxASRxQ+55+9erYNTXJq4uVdt2cVwc1v5x4Wc9yqvwygrnR pPQtoFEPrhOT/37QBVzj5RknWxTSaii6lfW9Kr7QE5jKFztA9wjVK8PZFwRvmTmTYbpn kZjsS6eEZmxYAbNBQgVNjb8IqZmKiqTU88TIDY1t1GTtpiNQvqFiz3bwf/bKt4bl0OTK 9sQ3Ivy5b4chvxSz7Ou7LFCBEVM41oLr1Ntkn6skAjnQ5xD3OVmWNThbV1J4+eOVUeFy KQCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=X85yYEixutf36SFN/BrrI1iD6SljCd5eSNXIiF4kkWw=; b=XnMyooHpt/6l0foe0e+j1BVP6M/oeMFWRAdgvWz97d/arEGM57v8OYtO2CwrdLdkwe 2TwU09QNC2x318ng12ZPouzVIsOYB5HB6cm4D62hSeYjPs3NBqJmivl05MvpPhPORYmI 1EfTOrDkzQ7ArtIenEUhZpoezqdQQlZjsg6yawUrWVGdygpTBBaSS6LhrMyBZwVO8pX6 FSMJn4JBnBUSp9aIgfa+8Cv2z1Q2csL4VbrB3qTZsUBsjGAAFZyaxvrJGC4ByWkIliYT V4XRReSWmWYQVuUJHYgsOwlKLCPSog47FStEK+YNhU98LzyHGS0ru8phZjQ4TVWrsq93 4Vzw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d5-v6si1183839pgq.316.2018.08.28.08.56.39; Tue, 28 Aug 2018 08:56:54 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727524AbeH1ToZ (ORCPT + 99 others); Tue, 28 Aug 2018 15:44:25 -0400 Received: from foss.arm.com ([217.140.101.70]:40990 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726383AbeH1ToX (ORCPT ); Tue, 28 Aug 2018 15:44:23 -0400 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 5F40015BF; Tue, 28 Aug 2018 08:52:07 -0700 (PDT) Received: from e112298-lin.Emea.Arm.com (usa-sjc-imap-foss1.foss.arm.com [10.72.51.249]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPA id 4D5E33F557; Tue, 28 Aug 2018 08:52:05 -0700 (PDT) From: Julien Thierry To: linux-arm-kernel@lists.infradead.org Cc: linux-kernel@vger.kernel.org, daniel.thompson@linaro.org, joel@joelfernandes.org, marc.zyngier@arm.com, mark.rutland@arm.com, christoffer.dall@arm.com, james.morse@arm.com, catalin.marinas@arm.com, will.deacon@arm.com, Julien Thierry , Thomas Gleixner , Jason Cooper Subject: [PATCH v5 08/27] irqchip/gic: Unify GIC priority definitions Date: Tue, 28 Aug 2018 16:51:18 +0100 Message-Id: <1535471497-38854-9-git-send-email-julien.thierry@arm.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1535471497-38854-1-git-send-email-julien.thierry@arm.com> References: <1535471497-38854-1-git-send-email-julien.thierry@arm.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org LPIs use the same priority value as other GIC interrupts. Make the GIC default priority definition visible to ITS implementation and use this same definition for LPI priorities. Tested-by: Daniel Thompson Signed-off-by: Julien Thierry Cc: Thomas Gleixner Cc: Jason Cooper Cc: Marc Zyngier --- drivers/irqchip/irq-gic-v3-its.c | 2 +- include/linux/irqchip/arm-gic-common.h | 6 ++++++ include/linux/irqchip/arm-gic.h | 5 ----- 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/drivers/irqchip/irq-gic-v3-its.c b/drivers/irqchip/irq-gic-v3-its.c index 316a575..f5391f2 100644 --- a/drivers/irqchip/irq-gic-v3-its.c +++ b/drivers/irqchip/irq-gic-v3-its.c @@ -64,7 +64,7 @@ #define LPI_PROPBASE_SZ ALIGN(BIT(LPI_NRBITS), SZ_64K) #define LPI_PENDBASE_SZ ALIGN(BIT(LPI_NRBITS) / 8, SZ_64K) -#define LPI_PROP_DEFAULT_PRIO 0xa0 +#define LPI_PROP_DEFAULT_PRIO GICD_INT_DEF_PRI /* * Collection structure - just an ID, and a redistributor address to diff --git a/include/linux/irqchip/arm-gic-common.h b/include/linux/irqchip/arm-gic-common.h index 0a83b43..9a1a479 100644 --- a/include/linux/irqchip/arm-gic-common.h +++ b/include/linux/irqchip/arm-gic-common.h @@ -13,6 +13,12 @@ #include #include +#define GICD_INT_DEF_PRI 0xa0 +#define GICD_INT_DEF_PRI_X4 ((GICD_INT_DEF_PRI << 24) |\ + (GICD_INT_DEF_PRI << 16) |\ + (GICD_INT_DEF_PRI << 8) |\ + GICD_INT_DEF_PRI) + enum gic_type { GIC_V2, GIC_V3, diff --git a/include/linux/irqchip/arm-gic.h b/include/linux/irqchip/arm-gic.h index 6c4aaf0..6261790 100644 --- a/include/linux/irqchip/arm-gic.h +++ b/include/linux/irqchip/arm-gic.h @@ -65,11 +65,6 @@ #define GICD_INT_EN_CLR_X32 0xffffffff #define GICD_INT_EN_SET_SGI 0x0000ffff #define GICD_INT_EN_CLR_PPI 0xffff0000 -#define GICD_INT_DEF_PRI 0xa0 -#define GICD_INT_DEF_PRI_X4 ((GICD_INT_DEF_PRI << 24) |\ - (GICD_INT_DEF_PRI << 16) |\ - (GICD_INT_DEF_PRI << 8) |\ - GICD_INT_DEF_PRI) #define GICD_IIDR_IMPLEMENTER_SHIFT 0 #define GICD_IIDR_IMPLEMENTER_MASK (0xfff << GICD_IIDR_IMPLEMENTER_SHIFT) -- 1.9.1