From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 726BBC83F2F for ; Thu, 29 Aug 2024 15:30:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id CC8D36B007B; Thu, 29 Aug 2024 11:30:27 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id C79596B0083; Thu, 29 Aug 2024 11:30:27 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B67836B0085; Thu, 29 Aug 2024 11:30:27 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 965326B007B for ; Thu, 29 Aug 2024 11:30:27 -0400 (EDT) Received: from smtpin09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id 3866DA7A8D for ; Thu, 29 Aug 2024 15:30:27 +0000 (UTC) X-FDA: 82505669694.09.034C205 Received: from mail-oi1-f171.google.com (mail-oi1-f171.google.com [209.85.167.171]) by imf27.hostedemail.com (Postfix) with ESMTP id F0CA84002A for ; Thu, 29 Aug 2024 15:30:24 +0000 (UTC) Authentication-Results: imf27.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=JxQwR6nC; spf=pass (imf27.hostedemail.com: domain of jeffxu@chromium.org designates 209.85.167.171 as permitted sender) smtp.mailfrom=jeffxu@chromium.org; dmarc=pass (policy=none) header.from=chromium.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1724945354; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=GfirTw1c0aIcYb4weoxcT30+5e5JZv0jxRwuMnAz9/A=; b=yviMYdC0jPGWd2EZmh2m6a4kJHs5oLC5XL6+u77Mb+zn6JYPtgPMa72s9M+NrGoIBVI6ji nOzPXLNhX6sNYih0+jSfWPDSBsgUgr62qePGO20b/kPsQAOg5kivbvJ5dtOoxASNHDNKJx f4H+t8wHYUqK9CxQPV/13V0DLAw3Jfc= ARC-Authentication-Results: i=1; imf27.hostedemail.com; dkim=pass header.d=chromium.org header.s=google header.b=JxQwR6nC; spf=pass (imf27.hostedemail.com: domain of jeffxu@chromium.org designates 209.85.167.171 as permitted sender) smtp.mailfrom=jeffxu@chromium.org; dmarc=pass (policy=none) header.from=chromium.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1724945354; a=rsa-sha256; cv=none; b=6UEoBPOJlKI7tYF+bGrDGVomT/4N0JoiDstU5mpdoHu1586TVlnhq/cNyeFEXfHWPesaiL 1iNoXDOc3UXZ5II4wCEBraAUNEH9ygG0KQEoSXdFv8SJNNvpJMnrlNGFUbamR9EHZAt07L 6yycuXx1FalhwvTVOLBAt2JG9iMZwl4= Received: by mail-oi1-f171.google.com with SMTP id 5614622812f47-3df075ef43cso59421b6e.3 for ; Thu, 29 Aug 2024 08:30:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1724945424; x=1725550224; darn=kvack.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=GfirTw1c0aIcYb4weoxcT30+5e5JZv0jxRwuMnAz9/A=; b=JxQwR6nC2upYONOgCsGcucV+EkgO2xh05mmUTusVSayJ5SMXu+s+If0S6ExE+M65RI IeZctbSYo8YmSsn/Y3tNtRRFNnIKuo1YALPv4RDbJw6WhNp4Z1cuw93/IVVKU/QT8jJ5 P/nj3eC9bzKBO3h8MvpJU65/4kM/f+Mz1eNjo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724945424; x=1725550224; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=GfirTw1c0aIcYb4weoxcT30+5e5JZv0jxRwuMnAz9/A=; b=O8mVSgvgfbEHlFaf12cjm1V2JnCiyUieP2nyFRVz2doFs9o0Cv8wd9AKF+g0qK0gkY oxPegNjr5rh+GhKrHnSszSkSQmRbwSLw2gz9/s/GIxJd+aStL2eE0N9WMCSICUZpbPLK IzEPx8T83maRfvQfqIaf78uIZrJe+1VMyVXfKi9KqSWCwT4l/rrF+fnJ+JMa/pIE9Z66 k4Y2zLEUTMhE3zZt9chYTJEeCLHn+3MP/NyjeFMOYrwwne3sOHXWup8N9RB83EkbBBBK 7ZH66R9UlkYMcQ8IRMk1xU7H2bUYOHMkDFpvDa0zIkTQ5WF5G8FM+wZAKt+l/9ofYJ/E r4nQ== X-Forwarded-Encrypted: i=1; AJvYcCWZlYWxMCtFFjbreAIfs41WQVqpX4J3hRsS7GdpjU6UUgEKdIy3E5x1A1+Cq5fjTlx1HSI+dGj53Q==@kvack.org X-Gm-Message-State: AOJu0Yx0PfzP1IwHQtr6ZWfGkO2lp9Y7VFdlyi+M6lo3oetfxaJdwESS ajGCuqVykJUjSjdEYS/fKi9w7oGEIQJNPsZoHZYBX9pHTAbkJUun+Llr6+4BfTl7ODt1reE0nsy BBa9YI4CMczt7f/QKAqCaIu9j4PnQXTWlBdIC X-Google-Smtp-Source: AGHT+IGEUawEh3mfQp6LCKeSaw+tM4JS/Jg17r0MLTtyYvI0UVg00MKhSKv4na3gy4ai0yuC2fEh+dcYDGEE1VVcg80= X-Received: by 2002:a05:6808:34b:b0:3db:421c:1bce with SMTP id 5614622812f47-3df05c28735mr1735969b6e.1.1724945423657; Thu, 29 Aug 2024 08:30:23 -0700 (PDT) MIME-Version: 1.0 References: <20240828225522.684774-1-jeffxu@chromium.org> <20240828225522.684774-2-jeffxu@chromium.org> <097a3458-0126-48e3-ba0d-d7dc7b9069d2@lucifer.local> In-Reply-To: <097a3458-0126-48e3-ba0d-d7dc7b9069d2@lucifer.local> From: Jeff Xu Date: Thu, 29 Aug 2024 08:30:11 -0700 Message-ID: Subject: Re: [PATCH v1 2/2] selftests/mm: mseal_test add more tests To: Lorenzo Stoakes Cc: akpm@linux-foundation.org, linux-kselftest@vger.kernel.org, linux-mm@kvack.org, linux-hardening@vger.kernel.org, pedro.falcato@gmail.com, rientjes@google.com, keescook@chromium.org, "Liam R. Howlett" , Vlastimil Babka Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Stat-Signature: zcmniujgpyzpsfoaixo43zaycugjtygm X-Rspam-User: X-Rspamd-Queue-Id: F0CA84002A X-Rspamd-Server: rspam02 X-HE-Tag: 1724945424-359466 X-HE-Meta: U2FsdGVkX1/7vg76wg2LAUlgZ4nQmPsnNqGF4uSLVW5M1R0YTq2WDGDM5ec1MwWtGhipiFttDGeSXCx3dtpyz/XnBvcx/vObABlaMXjyPZaWNC2MpF93ydM3rz3E2AiKPqgaK0mSCvY7dww+a+VLg9DIB+Y2eq92KHDhepjOtXACgGxZ7q8OdafCUW9ryhXXcrvkhCNVzyYSp0rSqd508gInfZL5jt7mOK6DarFZUUr7jIm0RIw6KZpsPUcHUxBQ3lo+qCmOXff4SYHqJp3aB5q7Hez9CQPrTecRlZcabY1VfiFr2gq1e12sJxB8H+UrRA9haR2FrigaUWuk5U0qo8tZwEJor3hR/Z1OTyjOrCEE4Er8a0VCpNTBCJK6Gj8jkdA/rR1IpHcLmdYD/Qxrx7nQskvLReRor9gz3ii9++rpXSH1tfLxrBr8JAbX+014LkeuMoRkiNr5g6tJ1u6OryiQi7gLjBPccLACoyZK+qF/hZ+7F+YO22NeoUNpsZ0zQXygoWnTAChAMnYefvmrHWmV1g7pXJoKXh0daRMI8jgV0Q3/1ExNXz756XrxpVdGzoNzaHI68ILUMaQV155E1su9KIzIWS75i/SqHEf2i/jIkIlNaEgLJ6aeUwhkGDENRb840GYn0QzLQLRdoDUJuAQbaDfEBesw0i8eOqESqZeEDgXY54/Cnia+MKNR6jKO0VOgGZ5OHbjB1P8FflnmOX21YDhahhUwtkhI5B4bPkJaZqFUTtjQmzfe0dJCHwV3nxQn31dhcY3JtOcD+6JcLMS+Ucwn99yvEYcVl+DKtsD39ArjQGjQxkBU/2JbkmKuQPbCzofCJGO7Gzv+GQzjDXh/rlLZDWB1btmuE07CXjXOkpY1TveignHLFtC4uVq0W2BWjbKkgQUTkxVG3IBnV+dzCb7Dva3cahXVDD0d02LvFilIXW5LKuy2uZ4Y7cUG/173LT+yP6CYrZ2+3BL IOEW9tYh /UTJHHhXAyt9r4D+BIznHX7kKKixMBdmIhMw1IqADZcTDpQgD+SqxmmaDS7x003IUBv+DlBh+tE8sTxBl2WuvfquqjTc1g2e/hhPq/8Vqt2FeTnma9hbEJshJ75VoagWTvVt5RTuwQPzwmMWfMpOGHRbuAzNS/tNojHX3y6fJcOype7DNGP2Fv63WfE8Snj0SS/eXJal9blHq3Zw1nwACCbX5W+/uiE4Vi2fE4E+mKjaVkwTnGdmLH/QTM4h/Hg/UgtdfUkidq217S91Q/hU89wUdkoSBbxMJSqmFB600HWzG2uZ7oFsq3zICPAasdOzpPJAxwcOZIsCevEqxsMiS2/PKettfH3oV3vbp7KjNLadfib6iNRxO4vlvd6sueEKofDRyo8XVL/MvNMA= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: Hi Lorenzo On Thu, Aug 29, 2024 at 8:14=E2=80=AFAM Lorenzo Stoakes wrote: > > On Thu, Aug 29, 2024 at 07:45:56AM GMT, Jeff Xu wrote: > > HI Andrew > > > > On Wed, Aug 28, 2024 at 3:55=E2=80=AFPM wrote: > > > > > > From: Jeff Xu > > > > > > Add more testcases and increase test coverage, e.g. add > > > get_vma_size to check VMA size and prot bits. > > This commit message is ridiculously short for such a massive change, even= for > test code. > > > > > > > > Could you please pull the self-test part of this patch series to mm-uns= table ? > > It will help to prevent regression. > > No, please don't. > > This needs review. > > These tests establish a precedent as to how mseal should behave, this is > something that needs community review, not to just be taken. > > There's already been a great deal of confusion/contentious discussion > around mseal() and its implementation. > > Pushing in ~800 lines of test code asserting how mseal() should behave > without review isn't helping things. > > Also, this is a really unusual way to send a series - why is this a 2/2 i= n > reply to the 1/2 and no cover letter? Why is this change totally unrelate= d > to the other patch? > > Can you send this as a separate patch, preferably as an RFC so we can > ensure that we all agree on how mseal() should behave? > > Sorry to be contentious here, but I think we need to find a more > constructive, collaborative way forward with mseal() and to act with a > little more caution, given the problems that the original series has caus= ed > I'd think this is in the best interests of all. > > Thanks for understanding! > There have been two bugs I found recently on mseal. One during V2 of in-loop change and the other mentioned in 1/2 of this patc= h. These additional tests will increase the test coverage of mseal and ensure the functionality of in-loop change is correct, also help to detect future regression. If you feel it will take time to review the test case, please do so and comment on the tests itself directly, I will send V2 after that. Thanks -Jeff > > > > The first part ([PATCH v1 1/2] mseal: fix mmap(FIXED) error code) can > > be ignored as Liam proposed to fix it differently. > > > > Thanks > > -Jeff > > > > -Jeff > > > > > Signed-off-by: Jeff Xu > > > --- > > > tools/testing/selftests/mm/mseal_test.c | 826 ++++++++++++++++++++++= -- > > > 1 file changed, 759 insertions(+), 67 deletions(-) > > > > > > diff --git a/tools/testing/selftests/mm/mseal_test.c b/tools/testing/= selftests/mm/mseal_test.c > > > index e7991e5fdcf3..4b3f883aae17 100644 > > > --- a/tools/testing/selftests/mm/mseal_test.c > > > +++ b/tools/testing/selftests/mm/mseal_test.c