Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp3473721rwb; Fri, 9 Dec 2022 15:15:05 -0800 (PST) X-Google-Smtp-Source: AA0mqf73P6DTDqAswsZmp83U+aAUtqlEq3nu5iq7fdtbiGiz8g3dQnZjkaWirxCMg4QRS00kW0UM X-Received: by 2002:a17:903:1341:b0:189:e4e:792c with SMTP id jl1-20020a170903134100b001890e4e792cmr7117915plb.64.1670627705659; Fri, 09 Dec 2022 15:15:05 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1670627705; cv=pass; d=google.com; s=arc-20160816; b=l4wgrDrnAVlikV7J2rEl/QlDJmV1FVXesWSei2lMhZwl0ZbpXXArFckkhf05MgOvsM VTlahizjTQaPkQAKk2wCo+nzbyJ7Zo4hv4rVYGvXByHgvMirec4X5SiMXeDTbrhc24Pn sgxXSJ9dYzr7MArz1TBq5c8AjG/10u+ttEvAjLfPHSAA3zGDMg1aP9nIsGOI3N1xFHQr G2zit8Wc/Fyi9uKvoxmC4PoXqAW3qaEfZHbe+8SfBAZgRIRf40CTlttTlBDUHvX4o+cY cSJuIhaCgqtLRV4OD5eq60/zb4xcswVfYRR6wCm5ARBzsUyruJHTl4G8wVvTU67VDK83 E7MA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:in-reply-to:content-disposition :references:message-id:subject:cc:to:from:date:dkim-signature :dkim-signature; bh=8yAX/UqxijgWR6eUlAP7v0mGuP3tWHRLlPIEDobQ8EE=; b=YDeLQX9krDXARBIw9KFahG7xEwResPL/yfNvjcP/1plDmWZCcHzGbgWYl03Kl+tQQw IaWsIwS1PrCSkRUJyjXofQL+7smH9GF4SnLdEay+noDnOdRjjrgUjnAAMzC+5bFFfe4p 5t3nHG3RUBv+sYH6n00zPBZQ6HXVR0A9xWbi+eEV9s64E/IBtsC6vu+Rp1qgOFLgjTL7 tx30g1k3L214QIlfbZJxbDK6OZl+dlQIkYhMeYrlk7+msVCayy8aHVeBS4hFrWsMj8Up n8t6cko+yDfD9C7CDV+5RVEjuorbtp66DCzhQBQuV4FV4Dusvavp9HcUlFLNAkzLKRD8 22Mg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2022-7-12 header.b=VmaBpglL; dkim=pass header.i=@oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=gad5hPxg; arc=pass (i=1 spf=pass spfdomain=oracle.com dkim=pass dkdomain=oracle.com dmarc=pass fromdomain=oracle.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k17-20020a170902c41100b001890fdf32c1si3100089plk.180.2022.12.09.15.14.53; Fri, 09 Dec 2022 15:15:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@oracle.com header.s=corp-2022-7-12 header.b=VmaBpglL; dkim=pass header.i=@oracle.onmicrosoft.com header.s=selector2-oracle-onmicrosoft-com header.b=gad5hPxg; arc=pass (i=1 spf=pass spfdomain=oracle.com dkim=pass dkdomain=oracle.com dmarc=pass fromdomain=oracle.com); spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=oracle.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229905AbiLIWu1 (ORCPT + 75 others); Fri, 9 Dec 2022 17:50:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47520 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229861AbiLIWt5 (ORCPT ); Fri, 9 Dec 2022 17:49:57 -0500 Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id ED283629B1 for ; Fri, 9 Dec 2022 14:48:43 -0800 (PST) Received: from pps.filterd (m0333521.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 2B9ME8XL004171; Fri, 9 Dec 2022 22:48:11 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=date : from : to : cc : subject : message-id : references : content-type : in-reply-to : mime-version; s=corp-2022-7-12; bh=8yAX/UqxijgWR6eUlAP7v0mGuP3tWHRLlPIEDobQ8EE=; b=VmaBpglL433L3bqTFmirGyLq9ux3GNve+7Am/BqpvmNpP/j/vE7GL5XaWKOvJZeWk2Qd Mb0DvUX+ZU7Us23PYu5PJsqoEdmMVMMNkI76swxQlX4qK/4nFhrlELYGR/VQrXiemc/Z DvRlL7Grs6xbwN6bxn3HoV6QUAjrwDOxLclgqcoiuZfBos0oa2lzq88vLKEs01MUTPIq kVYAJ98DKYS2jx8Nr+B63v0/M9BmUZz4ZjwwAjS2Nk3sLzj9grpu4M6lUZ75X/dSK6Eu 7ldqAot0rcUazuwP02KuQ2/WPubyq2sx0Y9t+Bij7Nc4Fy00wGKBrMQ0hpox0c0MLhBD 5w== Received: from phxpaimrmta03.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta03.appoci.oracle.com [138.1.37.129]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3maxeywftj-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 09 Dec 2022 22:48:11 +0000 Received: from pps.filterd (phxpaimrmta03.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta03.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.5/8.17.1.5) with ESMTP id 2B9KvVMV039815; Fri, 9 Dec 2022 22:48:10 GMT Received: from nam02-dm3-obe.outbound.protection.outlook.com (mail-dm3nam02lp2045.outbound.protection.outlook.com [104.47.56.45]) by phxpaimrmta03.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3maa8m9k8e-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 09 Dec 2022 22:48:10 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=X5fljBaPh2FErLPFWpLq9qZGGd2tfavhFhdLGUIpDm9g2fdvKjcYW0Ogy5iZKt+8xWiWMVO/73554CvM8OqSnyL80Aa//TaBmqISyL0Vo22XjNh0LgwNiJxtAX6iUOUafty6ro7CI/oo+IFupgDo9KolBH6LCwMZlIFQU2BjZydIhyLs4oGBi2qJAgv4dvniXAn67rodMYjpuZnvrjiCiBXmiVVXkOZwloe4acg+Kn3dBI4eOD9fqmlB+Fj0LfQ4CIpPgRgRIMXJYeiNSjhnhkOzpO0nDg1a8g7VjodhnRyNGjYtP0+Ta43wtoN8+PKpkcAcukuTwT8bEfpKi+VvNA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=8yAX/UqxijgWR6eUlAP7v0mGuP3tWHRLlPIEDobQ8EE=; b=E79uishBjykQ/UfEnCWCaGYvIKc+bSPy/dovJbm/yCGuAXji72FZUv8rQRkmjI+/uSh81kDD1MEixPzPony3BPVWljdijl6HT603Lg+QbxWH/+puebmR28/Kx8bnTIAUTS/OUb4W8gVxEBrGIeYGOoQ6JxlXmAu76pGZwnOM0rX4m9P+1yJwCXLyHVxSG+26SEpMDz4+In5qcilyDKQGYT7mOu3jzUBMcsW5wwFRe3Sano+2yQPW87mwU9F9Zu3mTXBPbucKlZqifz84EBnZ3eZrJokfNa5Z0wMXrBCOUUy4CtfhLJoGprrXCXc/8XM60J5Z9WLK/9/kVAQioiFuaA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=8yAX/UqxijgWR6eUlAP7v0mGuP3tWHRLlPIEDobQ8EE=; b=gad5hPxgmthc2KfSy9wtPMnWQg01HZE5nomy4Gy8Xs2+UfRBfvO/Jc4S/oxrVvgYyM+RB/gfKND0TF0b4hnuW1madl5vckBRYti3HjImmA2G+cGU5JgSTpEwwocKmmI2RZvuTHAxuTJGPRKJSW4HRpTMoOKYrStLrhQCVF/Ws0A= Received: from BY5PR10MB4196.namprd10.prod.outlook.com (2603:10b6:a03:20d::23) by DS7PR10MB7345.namprd10.prod.outlook.com (2603:10b6:8:eb::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5880.14; Fri, 9 Dec 2022 22:48:07 +0000 Received: from BY5PR10MB4196.namprd10.prod.outlook.com ([fe80::8d67:8c42:d124:3721]) by BY5PR10MB4196.namprd10.prod.outlook.com ([fe80::8d67:8c42:d124:3721%4]) with mapi id 15.20.5880.018; Fri, 9 Dec 2022 22:48:07 +0000 Date: Fri, 9 Dec 2022 14:48:04 -0800 From: Mike Kravetz To: Peter Xu Cc: James Houghton , Muchun Song , David Hildenbrand , David Rientjes , Axel Rasmussen , Mina Almasry , Zach O'Keefe , Manish Mishra , Naoya Horiguchi , "Dr . David Alan Gilbert" , "Matthew Wilcox (Oracle)" , Vlastimil Babka , Baolin Wang , Miaohe Lin , Yang Shi , Andrew Morton , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [RFC PATCH v2 06/47] hugetlb: extend vma lock for shared vmas Message-ID: References: <20221021163703.3218176-1-jthoughton@google.com> <20221021163703.3218176-7-jthoughton@google.com> Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-ClientProxiedBy: MW4PR04CA0101.namprd04.prod.outlook.com (2603:10b6:303:83::16) To BY5PR10MB4196.namprd10.prod.outlook.com (2603:10b6:a03:20d::23) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BY5PR10MB4196:EE_|DS7PR10MB7345:EE_ X-MS-Office365-Filtering-Correlation-Id: ca61597c-d204-41b9-2d28-08dada3770b1 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: YJk8dYY++3YOGUcTnmsI1Eyy22CgnX1ym/hf8H6/7vO9utE2ZQaVJsFqQfGE60as4ECk6DcstM7yZKqfyDdNKQ4NYCh1iIxkYOK74d2gcUgWpHxcZGmCXaH7secDKSWL9deJDPFT5nHg9Fjdf6bKvmnx7KTol44N9mEkDRSdhdSugNjXe8pkrdWxpOirqDVYYpinGDBsRMT8sicfV9nfoc5/GUlt9GbubrWPJZuCy6rhv7nL++AcswUh6H3+QZ6y0nMGXDP1haQlj5QxpgtCqxapVtzWcBS1Tfa3RmumMGIVX+K750iMKVtO5wDxgR0mNHV44ssYKqq0dxpXfRUg+NTKMfOZXSo3NvsrrbNaWFOUfMOegnMyzlQM+if2glJF19hXwXQsNqHR2ZhySs/TXoRApS6IHm98UYfRhKvvfMAZBGZVZzycJnQ5h7On0deUCYRLWeGLOELULQN6T2/lYq8T3f5hVj1oAbXdWpOeqLZkNMwNOss3l5mTt2Kf9jdSJU+Y2lmKPQtpnSkYEwJ92lg7atup4/izkjNKbrXxFzGWcb/eoG9GVtnu4O6vgbcnEptJTZZFHAumTIktjskUgJKgLrYQKJZIlcZnbBCYtXJyo7m+D7fa9KZjlfNMwF8Vz+5uByknvVFNie8jhUvwTA== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BY5PR10MB4196.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230022)(7916004)(346002)(136003)(366004)(396003)(376002)(39860400002)(451199015)(6486002)(38100700002)(53546011)(6506007)(478600001)(6666004)(186003)(33716001)(2906002)(6512007)(54906003)(9686003)(83380400001)(86362001)(26005)(316002)(66946007)(66476007)(8676002)(4326008)(41300700001)(6916009)(44832011)(8936002)(5660300002)(66556008)(7416002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?us-ascii?Q?mf5kigh+TSYT1lVlboo6/lNmTA1macw3FjdWOCeDuIzvCYoYJdRMZ4HG92Yh?= =?us-ascii?Q?Lv2UZP0opOyzjoZfz37jYf7kR5PgxH0HRRZvTSclhMb9KVEzuBfr2IAouHFV?= =?us-ascii?Q?81qfyNj0dMd9D3QPT74IPfQN9NFwjKL5RaqFSBkkaZG8B5N5VH0XZ+SIn60S?= =?us-ascii?Q?VmB6t+8/MvCTR6H+oF2gH2dedJWFnZlFZxyolK5xCs+mjDR6tkAfeLCNUpg5?= =?us-ascii?Q?ESoJ1CHRQWwPF/uMVeEjl32+zwkfxjtukOJPOarSRzgRxaRV4DOtmmCOlYlI?= =?us-ascii?Q?+2aWyLP1aD2h4EBERbEtjXn3JdCNBX8N0UnzFicZ90PN9rnNwvWcdqp3ZvjM?= =?us-ascii?Q?QgwzIwTBFtln0+bpX4PP4miaCapFwZOT8U8zSiyoDF1eSpgxlXWzA4q4ztas?= =?us-ascii?Q?AAsaMMxGvEGK1Od6pm+yxKHL/iRpsMms2ZQLGNt3dzaFFUvb9gKlDjRNNeYU?= =?us-ascii?Q?zLCDEQU1ZnwxmFicqqVIlV+k6XF3iMyotOWfP8HAiacZYqXFvZOi3MIPXglD?= =?us-ascii?Q?6gKQvnrbpXabv6iLZYKjGYNth3mgpThC0U8X9O1YJ8JEvtQ34qQ+FOBvUn72?= =?us-ascii?Q?4K4To+NNcAXu+oN+Ht+5iUJjUve7RBSv1/s7Kb5BISenL0a4py0vQTa9D4p9?= =?us-ascii?Q?STQhwmssSaHY1VKJt7rG2fjyHS3VES2c6I2uPBFa+WdRE3ftwLL3HkQIvi0M?= =?us-ascii?Q?msQGaZAWtAV+sqFQWnE8ILfn7sH84h3bZ3hy0El2fxI6ej+IVKavipGUyF5h?= =?us-ascii?Q?ebsq5skYsD36T6kwkdxJpUhWIJloUSMH3ifXJYTELF508E+YPjcNRFlw/Emc?= =?us-ascii?Q?XxwNsca22mIgDebszTgOlWnqr2HySMG+cEkJGuu5E8r3Nbw9XY/DH5B9QWLW?= =?us-ascii?Q?109ihJCBo9jNq72Slv9li59gc3Gc4vSGLSHjIuWBrLHKiCSQithdlXltvgwg?= =?us-ascii?Q?HAHoV3/GaTC2aS2Mf6VK2gFTKasHayNfJeN60djpu+metKjUW1SeeX3/uxCY?= =?us-ascii?Q?qLYOICSEiJqAQZaCuna/4SlNqDFn9aip2ADUUiQmhJ/DiWUQrJTMTs/h1shd?= =?us-ascii?Q?4QvkQkPXe1D3TcTeAxJpArSgiN4xFVY+otTqbQiJY7H0lSlyQLSmPAmAzldZ?= =?us-ascii?Q?J+QtfuXSec7gUhlxOhOPHq4hM1Vdp9uyGZr8gg7PDAry6ZcZeRDQUFrXTAOL?= =?us-ascii?Q?mpGpVpOF/q9P1PWdstxOq+EWrr9ArddwEe/F7F5YTFdqplmHSqPtXpZqhR2k?= =?us-ascii?Q?Kg+Fji9P6ieyfm/KUZ1E/VFtOA7vdNqOn4EwuzZbnY0rFZmVqC+Yebu9j+iO?= =?us-ascii?Q?pzCKFAuj206q5vkA4Pfjw4y63iMPUV2VVvhGAoEPYYSGj5+II87dfqVWLLwY?= =?us-ascii?Q?3pZYsFxniXrvbfCpzeaN7YDrzpyMaopGMYbm3drOBoqiLYdoZT0fM2U+TmXg?= =?us-ascii?Q?boqqs2GY+hLInlanzdDDIUaVE+zHYqu/sen6Xa18C2V75CheMxyzqeFToYsd?= =?us-ascii?Q?f7kLkzgpPgMUo2Zcu54quyB/xzxYPhKsQTjAi/ATs7UuPm++MoXZ4xRrbq/t?= =?us-ascii?Q?1AYU2dwpyIOjZJca5+9YU9njNgrCLfyYt23G0ty7NbcbhORtMbMbVNMdDOQG?= =?us-ascii?Q?+A=3D=3D?= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: ca61597c-d204-41b9-2d28-08dada3770b1 X-MS-Exchange-CrossTenant-AuthSource: BY5PR10MB4196.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Dec 2022 22:48:07.7406 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: YjPNGnHzKpKIfSkIKa6abXI7QV/k3ZEm6AUsZmDealyg1FFrOLhFqatuCLhEjjH0v16gHL8bmKjRzL5AFOAkRA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS7PR10MB7345 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.205,Aquarius:18.0.923,Hydra:6.0.545,FMLib:17.11.122.1 definitions=2022-12-09_13,2022-12-08_01,2022-06-22_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=870 bulkscore=0 suspectscore=0 phishscore=0 malwarescore=0 mlxscore=0 spamscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2210170000 definitions=main-2212090187 X-Proofpoint-GUID: 1fvIq3uRrk1GDMJaDHNmfTVTumvYb5eF X-Proofpoint-ORIG-GUID: 1fvIq3uRrk1GDMJaDHNmfTVTumvYb5eF X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/30/22 16:01, Peter Xu wrote: > On Fri, Oct 21, 2022 at 04:36:22PM +0000, James Houghton wrote: > > This allows us to add more data into the shared structure, which we will > > use to store whether or not HGM is enabled for this VMA or not, as HGM > > is only available for shared mappings. > > > > It may be better to include HGM as a VMA flag instead of extending the > > VMA lock structure. > > > > Signed-off-by: James Houghton > > --- > > include/linux/hugetlb.h | 4 +++ > > mm/hugetlb.c | 65 +++++++++++++++++++++-------------------- > > 2 files changed, 37 insertions(+), 32 deletions(-) > > > > diff --git a/include/linux/hugetlb.h b/include/linux/hugetlb.h > > index a899bc76d677..534958499ac4 100644 > > --- a/include/linux/hugetlb.h > > +++ b/include/linux/hugetlb.h > > @@ -121,6 +121,10 @@ struct hugetlb_vma_lock { > > struct vm_area_struct *vma; > > }; > > > > +struct hugetlb_shared_vma_data { > > + struct hugetlb_vma_lock vma_lock; > > +}; > > How about add a comment above hugetlb_vma_lock showing how it should be > used correctly? We lacked documents on the lock for pmd sharing > protections, now if to reuse the same lock for HGM pgtables I think some > doc will definitely help. > > To summarize, I think so far it means: > > - Read lock needed when one wants to stablize VM_SHARED pgtables (covers > both pmd shared pgtables or hgm low-level pgtables) > > - Write lock needed when one wants to release VM_SHARED pgtable pages > (covers both pmd unshare or releasing hgm low-level pgtables) Peter must have read ahead and knows that you plan to use the vma_lock for HGM. The commit message implies that a you only need some type of indication (a flag for instance) that HGM is enabled for the vma. No objections to expanding the structure as is done here. If this is the direction we take, and someday this is extended to private mappings we could used the same scheme to expand the reserve map structure. -- Mike Kravetz