From patchwork Tue Sep 12 10:03:19 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Julien Grall X-Patchwork-Id: 112277 Delivered-To: patch@linaro.org Received: by 10.80.202.13 with SMTP id d13csp5674537edi; Tue, 12 Sep 2017 03:05:49 -0700 (PDT) X-Google-Smtp-Source: AOwi7QBzE33dfglCipg2q/klR8+7lZNa8mEBs+q7etNbL0n9WHwMhNgOtu7gQAxw6K+oXeq0cee2 X-Received: by 10.107.168.98 with SMTP id r95mr15572660ioe.158.1505210749590; Tue, 12 Sep 2017 03:05:49 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1505210749; cv=none; d=google.com; s=arc-20160816; b=HyStgKqE0tYBeDoKavG/1YBpqjkbwOk3mbPl2iipmgH5M8tsYoMtB4qoJSOxVKNygj vrt3rEHy3onJd0GD3l0S9agx/+C+uDmupq+5Va0HHcDRr6ZQGYqxo+YcOeZKw1r+Ze09 Lk6UOCODdqpa/7FuShH8ruHkCik7wljzbbxLMD9hcSn5tC8AwIgXWCAGpZ9s2TNDpkbM qStSEsvOhSaen7IJ361GZwp80EBv1RWwtdVgXOX+AyFWIzZA4Ew8pFSf3F7X7rM1Smhf hzNIx25T019Mo34D14IigymO1PvIvN20A8YdP64dC/2dW2ymc0+hcr79nRwrmz7j3Pq4 VBYA== 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:arc-authentication-results; bh=54xj2PYD+enQ3vNIqfGdZZvTw5y0UAHQzjSlvXIpV9A=; b=VBxCYHH8LCfATPfjxSGuQNSQS/rAJdaZK1u9pVwsMNy/PLSh1FY7bYJk6SNccqVg5U c6RNH2tO3wxVg/qui7JfOUgz28UwfhEhvd3Lhv3zMxFkwiy3NVIRSQ7aPYiYu2oSQMK1 UZCDIpJ8YurIH3bWmL3Rp4fXy9oyZep/gLGU8/bSKPWHRlWB2z6VIyffSUrb2Y++9Gi2 ZatbLB4kUrhQIqoM+AvVxlQFly7Ah2gdWbZHf6UDUgHwfFdXj7/MvXZsSP88n48yJzPS XnpjhDpQvgnL36o/K3uyGINOiGRGO2GNlfAPvgVBaY2hWf4ISGp2ubCQc9x989muo1ni Ijtw== ARC-Authentication-Results: i=1; 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 Return-Path: Received: from lists.xenproject.org (lists.xenproject.org. [192.237.175.120]) by mx.google.com with ESMTPS id w63si10901772itg.128.2017.09.12.03.05.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 12 Sep 2017 03:05:49 -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 1dri2x-00035C-GZ; Tue, 12 Sep 2017 10:03:59 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dri2v-00031r-LK for xen-devel@lists.xen.org; Tue, 12 Sep 2017 10:03:57 +0000 Received: from [85.158.139.211] by server-17.bemta-5.messagelabs.com id 7B/CA-01791-C01B7B95; Tue, 12 Sep 2017 10:03:56 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFnrMLMWRWlGSWpSXmKPExsVysyfVTZdn4/Z Igy0LBCyWfFzM4sDocXT3b6YAxijWzLyk/IoE1ozn39czFSzkq9h8+ghbA+MU7i5GLg4hgc2M Ej2n5jFBOKcZJRaePwDkcHKwCWhK3Pn8CcwWEZCWuPb5MiOIzSwQKXH4ww92EFtYIE7i8IppY DaLgKrEqc1PwOp5BSwl1k3/DhaXEJCX2NV2kRXE5gSKr/j4iw3EFhKwkPj+8gfjBEbuBYwMqx g1ilOLylKLdI3M9JKKMtMzSnITM3N0DQ1M9XJTi4sT01NzEpOK9ZLzczcxAj1cz8DAuIPx9mS /Q4ySHExKorxH1m+PFOJLyk+pzEgszogvKs1JLT7EKMPBoSTBex4kJ1iUmp5akZaZAww1mLQE B4+SCO9skDRvcUFibnFmOkTqFKMuR8fNu3+YhFjy8vNSpcR5M0CKBECKMkrz4EbAwv4So6yUM C8jAwODEE9BalFuZgmq/CtGcQ5GJWHeOyBTeDLzSuA2vQI6ggnoCJ5LW0COKElESEk1MKbVNf 9e/Ucp9aaftdAKf4Hc5U/XyfgFXLjE0Cj3ddekuFTeXfMNJOrmuB2T+No7Ifscp+//w7rz52i 8YFmqrbDvYPUZswR/DdbVT0/9mLqeXbBO/5nuVF1PsWsF/9j2963UNvfgevLv/jvWjwZTZipL pU7um6aSJB27/d/d8m3PFOJ+bDIx36HEUpyRaKjFXFScCAAoM3PrdgIAAA== X-Env-Sender: julien.grall@arm.com X-Msg-Ref: server-8.tower-206.messagelabs.com!1505210635!110981200!1 X-Originating-IP: [217.140.101.70] X-SpamReason: No, hits=0.0 required=7.0 tests=UPPERCASE_25_50 X-StarScan-Received: X-StarScan-Version: 9.4.45; banners=-,-,- X-VirusChecked: Checked Received: (qmail 13431 invoked from network); 12 Sep 2017 10:03:56 -0000 Received: from foss.arm.com (HELO foss.arm.com) (217.140.101.70) by server-8.tower-206.messagelabs.com with SMTP; 12 Sep 2017 10:03:56 -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 7292F15A2; Tue, 12 Sep 2017 03:03:55 -0700 (PDT) Received: from e108454-lin.cambridge.arm.com (e108454-lin.cambridge.arm.com [10.1.206.53]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 8490B3F578; Tue, 12 Sep 2017 03:03:54 -0700 (PDT) From: Julien Grall To: xen-devel@lists.xen.org Date: Tue, 12 Sep 2017 11:03:19 +0100 Message-Id: <20170912100330.2168-14-julien.grall@arm.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170912100330.2168-1-julien.grall@arm.com> References: <20170912100330.2168-1-julien.grall@arm.com> Cc: andre.przywara@arm.com, Julien Grall , sstabellini@kernel.org Subject: [Xen-devel] [PATCH v2 13/24] xen/arm: page: Remove unused attributes DEV_NONSHARED and DEV_CACHED 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" They were imported from non-LPAE Linux, but Xen is LPAE only. It is time to do some clean-up in the memory attribute and keep only what make sense for Xen. Follow-up patch will do more clean-up. Also, update the comment saying our attribute matches Linux. Signed-off-by: Julien Grall Reviewed-by: Andre Przywara --- Changes in v2: - Add Andre's reviewed-by --- xen/include/asm-arm/page.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/xen/include/asm-arm/page.h b/xen/include/asm-arm/page.h index b8d641bfaf..d7939bb944 100644 --- a/xen/include/asm-arm/page.h +++ b/xen/include/asm-arm/page.h @@ -21,9 +21,9 @@ #define LPAE_SH_OUTER 0x2 #define LPAE_SH_INNER 0x3 -/* LPAE Memory region attributes, to match Linux's (non-LPAE) choices. - * Indexed by the AttrIndex bits of a LPAE entry; - * the 8-bit fields are packed little-endian into MAIR0 and MAIR1 +/* + * LPAE Memory region attributes. Indexed by the AttrIndex bits of a + * LPAE entry; the 8-bit fields are packed little-endian into MAIR0 and MAIR1. * * ai encoding * UNCACHED 000 0000 0000 -- Strongly Ordered @@ -35,9 +35,7 @@ * reserved 110 * WRITEALLOC 111 1111 1111 -- Write-back write-allocate * - * DEV_NONSHARED 100 (== DEV_SHARED) * DEV_WC 001 (== BUFFERABLE) - * DEV_CACHED 011 (== WRITEBACK) */ #define MAIR0VAL 0xeeaa4400 #define MAIR1VAL 0xff000004 @@ -57,9 +55,7 @@ #define WRITEBACK 0x3 #define DEV_SHARED 0x4 #define WRITEALLOC 0x7 -#define DEV_NONSHARED DEV_SHARED #define DEV_WC BUFFERABLE -#define DEV_CACHED WRITEBACK #define PAGE_HYPERVISOR (WRITEALLOC) #define PAGE_HYPERVISOR_NOCACHE (DEV_SHARED)