From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andy Lutomirski Subject: Re: [PATCH v4 2/3] mm: introduce MAP_VALIDATE a mechanism for adding new mmap flags Date: Tue, 15 Aug 2017 09:28:21 -0700 Message-ID: References: <150277752553.23945.13932394738552748440.stgit@dwillia2-desk3.amr.corp.intel.com> <150277753660.23945.11500026891611444016.stgit@dwillia2-desk3.amr.corp.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: In-Reply-To: <150277753660.23945.11500026891611444016.stgit@dwillia2-desk3.amr.corp.intel.com> Sender: linux-kernel-owner@vger.kernel.org To: Dan Williams Cc: "Darrick J. Wong" , Jan Kara , Arnd Bergmann , linux-nvdimm , Linux API , "linux-kernel@vger.kernel.org" , linux-xfs@vger.kernel.org, "linux-mm@kvack.org" , Andrew Lutomirski , Linux FS Devel , Andrew Morton , Christoph Hellwig List-Id: linux-api@vger.kernel.org On Mon, Aug 14, 2017 at 11:12 PM, Dan Williams wrote: > The mmap syscall suffers from the ABI anti-pattern of not validating > unknown flags. However, proposals like MAP_SYNC and MAP_DIRECT need a > mechanism to define new behavior that is known to fail on older kernels > without the feature. Use the fact that specifying MAP_SHARED and > MAP_PRIVATE at the same time is invalid as a cute hack to allow a new > set of validated flags to be introduced. While this is cute, is it actually better than a new syscall?