From patchwork Wed Jan 16 18:00:41 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoffer Dall X-Patchwork-Id: 1992681 Return-Path: X-Original-To: patchwork-kvm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 55DA2DF2A2 for ; Wed, 16 Jan 2013 18:00:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755864Ab3APSAp (ORCPT ); Wed, 16 Jan 2013 13:00:45 -0500 Received: from mail-vb0-f45.google.com ([209.85.212.45]:37581 "EHLO mail-vb0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753176Ab3APSAo (ORCPT ); Wed, 16 Jan 2013 13:00:44 -0500 Received: by mail-vb0-f45.google.com with SMTP id p1so1630650vbi.32 for ; Wed, 16 Jan 2013 10:00:43 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:subject:to:from:cc:date:message-id:in-reply-to :references:user-agent:mime-version:content-type :content-transfer-encoding:x-gm-message-state; bh=g/YgUmqWZlwErjzF4T9O1k2/47WhotgP9b/a9ZWKW4o=; b=Z9z+CAqiTByEfwBoAHEOHXlEj476lNuyzzlnmfxj2TGlC8CLLqucPP7xvvvp91F4zC nbOcEOjNPZIcDrXX1bLgxHM6K8HHrFtMOpT+mQ11khH5B+qXx3JtfRH0U6P6yaOq4us3 UvJXY3azzFrZTJu11+xWTuBpbsX1FnJ/YKKSiahMkVb/3NPS8oF/lLrH7Z73SEHGFg8P ZNjSjm19UREyKmaBuIOKKQjHmF3M8SQFS3nLenx48BCF4iqEGC0BxpoS2YKoIgTB/tpF KZq6YaME30fG93OEdgPe8p2OcgZXc2ko0IILquC/HEI60YYwpJo/H8hXwN0GUveRxxck /U2w== X-Received: by 10.52.68.4 with SMTP id r4mr1968139vdt.15.1358359243248; Wed, 16 Jan 2013 10:00:43 -0800 (PST) Received: from [127.0.1.1] (pool-72-80-83-148.nycmny.fios.verizon.net. [72.80.83.148]) by mx.google.com with ESMTPS id v12sm9738138vem.13.2013.01.16.10.00.42 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 16 Jan 2013 10:00:42 -0800 (PST) Subject: [PATCH v6 04/13] ARM: gic: define GICH offsets for VGIC support To: kvm@vger.kernel.org, linux-arm-kernel@lists.infradead.org, kvmarm@lists.cs.columbia.edu From: Christoffer Dall Cc: Marc Zyngier , Will Deacon Date: Wed, 16 Jan 2013 13:00:41 -0500 Message-ID: <20130116180041.29393.48988.stgit@ubuntu> In-Reply-To: <20130116180013.29393.49165.stgit@ubuntu> References: <20130116180013.29393.49165.stgit@ubuntu> User-Agent: StGit/0.15 MIME-Version: 1.0 X-Gm-Message-State: ALoCoQk8i8lgmmgOvyhr6ld5n9sbyrFldaZpUfA8n39a8XLS3UQEZ17Xe77mG0gUcvy6Q7ZF/kAw Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org From: Marc Zyngier The GICH_* constants are defined by the GIC HW spec, and even though they only be used by KVM to begin with, define them generically in gic.h. Reviewed-by: Will Deacon Signed-off-by: Marc Zyngier Signed-off-by: Christoffer Dall --- arch/arm/include/asm/hardware/gic.h | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/arch/arm/include/asm/hardware/gic.h b/arch/arm/include/asm/hardware/gic.h index caf5df3..6cad421 100644 --- a/arch/arm/include/asm/hardware/gic.h +++ b/arch/arm/include/asm/hardware/gic.h @@ -34,6 +34,31 @@ #define GIC_DIST_CONFIG 0xc00 #define GIC_DIST_SOFTINT 0xf00 +#define GICH_HCR 0x0 +#define GICH_VTR 0x4 +#define GICH_VMCR 0x8 +#define GICH_MISR 0x10 +#define GICH_EISR0 0x20 +#define GICH_EISR1 0x24 +#define GICH_ELRSR0 0x30 +#define GICH_ELRSR1 0x34 +#define GICH_APR 0xf0 +#define GICH_LR0 0x100 + +#define GICH_HCR_EN (1 << 0) +#define GICH_HCR_UIE (1 << 1) + +#define GICH_LR_VIRTUALID (0x3ff << 0) +#define GICH_LR_PHYSID_CPUID_SHIFT (10) +#define GICH_LR_PHYSID_CPUID (7 << GICH_LR_PHYSID_CPUID_SHIFT) +#define GICH_LR_STATE (3 << 28) +#define GICH_LR_PENDING_BIT (1 << 28) +#define GICH_LR_ACTIVE_BIT (1 << 29) +#define GICH_LR_EOI (1 << 19) + +#define GICH_MISR_EOI (1 << 0) +#define GICH_MISR_U (1 << 1) + #ifndef __ASSEMBLY__ #include struct device_node;