Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp955263pxb; Wed, 3 Mar 2021 22:24:46 -0800 (PST) X-Google-Smtp-Source: ABdhPJzeKDhyvnvGZVrnDM6i4NuhkwRRun4Byh+LBN4mmCBGR2sLhyFC5Bpnx/dSY7Y0YhFw9OHu X-Received: by 2002:a17:906:eb89:: with SMTP id mh9mr2651039ejb.122.1614839086622; Wed, 03 Mar 2021 22:24:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614839086; cv=none; d=google.com; s=arc-20160816; b=l5jGgbKEzSNDlkHmgZS/rdEOPGUhJp6gxK5L4XWm3M+GOQOsFOwLxF+bU7A8KLyJyk z5y3J3U8Kh908pTXFbQEnO9CysJzuKCoQqU8f3y8YGhdhs3pgYspbO/Rm6H+9F4b3j60 kr+J+0PdHroRxR2DEMazcjbjRrvXxBsDfrbQb39g5Z3K3EL+Kz8CmbgjAAE/ErwIVoyF rsPaiM4++fJTzll73JsuOEvCRwZnAKoKDrHl1sjWgr+wpvFDfSLk+hb0+dh5urBh/zKG vDBdrmeRiYJ45DuTt5k9xvuHikiHWmsCtLJDKCrzjWI5yJ7JdsOqn+SdSJQ2UvPaWUaa mDdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from; bh=dhl+CrbcypFISFQ06Pnte+BvANoC1JFuz5OSnJjAlUM=; b=HczeeOUnkBhpmLza+xkmI8W4LRp+553cUPiVEtHoaWZgjMa4K/xsJ5UYhq6IRNiLd0 Tv9DgfNtFi67MIQ9j6aSMxfwNo1+e0Y3dPYrlBo0GIUkly7pvCCskgfteyz5nQibNboT Ocy8UY9u/PP3BLZQY8jKWy4wsjkELEB2jvNsElaPB22w7hcJUDWrUYlA4LSDUsMcmAeu wLttiGba8byyjLqrEAAbHM4s/i6UOa25Dsru2jdvE8gskZA8K3W+Fsb4JZZ9RHyJgfHj 0/mHRNXMPNie/biRQjQPP3uBfhCl7wIqx7EOQsZgZV4NWtDOPN/9nlYo0ASj6owcXhq7 Ao0g== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z15si16863768ejr.734.2021.03.03.22.24.24; Wed, 03 Mar 2021 22:24:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1384625AbhCBPas (ORCPT + 99 others); Tue, 2 Mar 2021 10:30:48 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:13835 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1350923AbhCBM7Y (ORCPT ); Tue, 2 Mar 2021 07:59:24 -0500 Received: from DGGEMS412-HUB.china.huawei.com (unknown [172.30.72.60]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4DqcZd3Bsdz7sRQ; Tue, 2 Mar 2021 20:56:25 +0800 (CST) Received: from DESKTOP-TMVL5KK.china.huawei.com (10.174.187.128) by DGGEMS412-HUB.china.huawei.com (10.3.19.212) with Microsoft SMTP Server id 14.3.498.0; Tue, 2 Mar 2021 20:57:54 +0800 From: Yanan Wang To: , , CC: Paolo Bonzini , Ben Gardon , "Sean Christopherson" , Vitaly Kuznetsov , Andrew Jones , Peter Xu , Marc Zyngier , Ingo Molnar , Adrian Hunter , Jiri Olsa , "Arnaldo Carvalho de Melo" , Arnd Bergmann , Michael Kerrisk , Thomas Gleixner , , , , Yanan Wang Subject: [RFC PATCH v4 1/9] tools headers: sync headers of asm-generic/hugetlb_encode.h Date: Tue, 2 Mar 2021 20:57:43 +0800 Message-ID: <20210302125751.19080-2-wangyanan55@huawei.com> X-Mailer: git-send-email 2.8.4.windows.1 In-Reply-To: <20210302125751.19080-1-wangyanan55@huawei.com> References: <20210302125751.19080-1-wangyanan55@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.174.187.128] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch syncs contents of tools/include/asm-generic/hugetlb_encode.h and include/uapi/asm-generic/hugetlb_encode.h. Arch powerpc supports 16KB hugepages and ARM64 supports 32MB/512MB hugepages. The corresponding mmap flags have already been added in include/uapi/asm-generic/hugetlb_encode.h, but not tools/include/asm-generic/hugetlb_encode.h. Cc: Ingo Molnar Cc: Adrian Hunter Cc: Jiri Olsa Cc: Arnaldo Carvalho de Melo Signed-off-by: Yanan Wang Reviewed-by: Ben Gardon --- tools/include/asm-generic/hugetlb_encode.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tools/include/asm-generic/hugetlb_encode.h b/tools/include/asm-generic/hugetlb_encode.h index e4732d3c2998..4f3d5aaa11f5 100644 --- a/tools/include/asm-generic/hugetlb_encode.h +++ b/tools/include/asm-generic/hugetlb_encode.h @@ -20,13 +20,16 @@ #define HUGETLB_FLAG_ENCODE_SHIFT 26 #define HUGETLB_FLAG_ENCODE_MASK 0x3f +#define HUGETLB_FLAG_ENCODE_16KB (14 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_64KB (16 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_512KB (19 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_1MB (20 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_2MB (21 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_8MB (23 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_16MB (24 << HUGETLB_FLAG_ENCODE_SHIFT) +#define HUGETLB_FLAG_ENCODE_32MB (25 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_256MB (28 << HUGETLB_FLAG_ENCODE_SHIFT) +#define HUGETLB_FLAG_ENCODE_512MB (29 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_1GB (30 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_2GB (31 << HUGETLB_FLAG_ENCODE_SHIFT) #define HUGETLB_FLAG_ENCODE_16GB (34 << HUGETLB_FLAG_ENCODE_SHIFT) -- 2.23.0