From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F1C372F0690 for ; Fri, 14 Nov 2025 21:39:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763156377; cv=none; b=DZJkSqr1wGz7NCb50VjKEHlZOdcYpudEyE9OByZ21u5vERHxMXFSsjRTenAA2Z9CsZyPaQL0F/HH5yCM6O2Aq8UbqOcny7mxpZlMEagbTo+PN+T5k3e50gTPvFajRX6dXuXLfCDulca+Th6GAaXNULXo+8MX0nx6uje6Ij93UeQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763156377; c=relaxed/simple; bh=+CpQ+UMnmBXgdQjJo6/hU2rUsL4j7qOY0MVx7GNiZU0=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=pHp734qV3yN6LF1XTKc/jm6uU9RT/Ue9t1IeFMpuOh133EkRYGqpHCzH0gTjqohksGOHUOICCM/0bQ6Sf6ON8m4nj/COiNfFCDuyZDVelPLYYVveMkoshkMru+VsYiqrdoBJ2o8U5DOCAUCSrgn1ezH/8EtDTZjdXlf8AYSq/JU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=iTkj1d7L; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="iTkj1d7L" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9CF97C4CEF5; Fri, 14 Nov 2025 21:39:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1763156376; bh=+CpQ+UMnmBXgdQjJo6/hU2rUsL4j7qOY0MVx7GNiZU0=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=iTkj1d7LUUOTcKpGB1JvfX/zdGa2H/zujUHfxtRKx1uSMr9Q9IkIrF+U68PTv4sAA 93vtvLyvRNnp1ub/gRaZ83s/mY2S1VU/b1lRD9UKLqPwmtBrcbbnBGomJ8KL6sji0l Dg1Gct9hh5r5zPbB3JVZT3B7y4YAMB76IUQMgn1kAUmkStk3XZISpnfROqiDsrLZjf xDvisWSacEwbQqDaxLeMCoXLcWToJSBK4XlXV8udnsSWVUAGwg9rSajOuc6ov7UWZS JhhpfGW3VhjT26cHNi7tBDE22VIFtM7EbiavJqL8RF3YjlO3n/2ew2eoQroU432kbJ RrmtEZ3hmVP0Q== Message-ID: Date: Fri, 14 Nov 2025 22:39:32 +0100 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 1/2] Remove the "FOLL_TOUCH" test code from gup_test.c. To: John Hubbard , peng8420.li@gmail.com, linux-mm@kvack.org, akpm@linux-foundation.org Cc: osalvador@suse.de, jgg@ziepe.ca, peterx@redhat.com, linux-kernel@vger.kernel.org, dan.j.williams@intel.com References: <20251114161127.193707-1-peng8420.li@gmail.com> <6869aee5-0093-489d-bac7-fa718bdcb362@nvidia.com> From: "David Hildenbrand (Red Hat)" Content-Language: en-US In-Reply-To: <6869aee5-0093-489d-bac7-fa718bdcb362@nvidia.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 14.11.25 21:24, John Hubbard wrote: > Hi, > > The diffs look good, but the commit log and your replies have many minor > issues that add up. So you'll want to avoid them in the future, and with > that in mind, I've listed all of them, along with suggested alternatives. > > On 11/14/25 8:11 AM, peng8420.li@gmail.com wrote: >> From: "peng8420.li" > > This should be your real name, such as (my first guess) > "Peng Li" . > > Also, if you are sending from the same email address as your "From:", > then the "From:" item shouldn't normally show up (it's harmless here, > but could be cleaner without it). Check your .gitconfig send-email > options and you can make it go away. > > Also, when replying, your email client is apparently using HTML, please > fix it to use text only! > > Please read the patch submitter guidelines, too: > > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst > https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submit-checklist.rst > >> Ever since commit 0f20bba1688b ("mm/gup: explicitly define and check >> internal GUP flags, disallow FOLL_TOUCH") we marked FOLL_TOUCH as a GUP-internal flag. > > Not "ever since", but simply: > > commit 0f20bba1688b ("mm/gup: explicitly define and check internal GUP > flags, disallow FOLL_TOUCH") marked FOLL_TOUCH as a GUP-internal flag. > > Also, it's best to keep the line length within about 72 columns for > commit messages. > >> >> Therefore, remove the "FOLL_TOUCH" test code from gup_test.c; > > Trailing semicolon. Should be a period. > >> >> Otherwise, executing the test command "./gup_test -L -r 100 -z" will report the following warning log: >> TAP version 13 >> 1..1 >> ENCHMARK: Time: [ 39.363371] WARNING: CPU: 1 PID: 117 at mm/gup.c:2512 is_valid_gup_args+0x66/0x8c >> get:2818 put:46 [ 39.364043] Modules linked in: >> us# , truncated [ 39.364311] CPU: 1 UID: 0 PID: 117 Comm: gup_test Not tainted 6.18.0-rc5-00324-gd09eaf415c87 #29 NONE >> (size: 0)# >> [ 39.364434] Hardware name: riscv-virtio,qemu (DT) >> [ 39.364546] epc : is_valid_gup_args+0x66/0x8c >> [ 39.364596] ra : pin_user_pages+0x38/0x78 >> [ 39.364630] epc : ffffffff802079e6 ra : ffffffff8020c214 sp : ff2000000041bd20 >> [ 39.364650] gp : ffffffff81a26068 tp : ff60000080b3b000 t0 : ff2000000041bdf8 >> [ 39.364678] t1 : 000000000000001e t2 : 0000000000000000 s0 : ff2000000041bd30 >> [ 39.364697] s1 : ff60000081300000 a0 : ff60000081300000 a1 : 0000000000000000 >> [ 39.364714] a2 : ff2000000041bd3c a3 : 0000000000080000 a4 : 0000000000000001 >> [ 39.364731] a5 : 0000000000010101 a6 : 0000000000000001 a7 : 0000000000000000 >> [ 39.364747] s2 : 00007fff7eeed000 s3 : 0000000000000001 s4 : 00007fff7eeee000 >> [ 39.364761] s5 : 00007fff7eeeb838 s6 : 0000000000000000 s7 : 00007fff7eeed000 >> [ 39.364825] s8 : ff60000081300000 s9 : 0000000000000000 s10: 0000000000000002 >> [ 39.364842] s11: 000000092869bfdc t3 : 2152ffffffffffc0 t4 : 00000000001fffff >> [ 39.364855] t5 : ffffffffffffffff t6 : 0000000000000000 >> [ 39.364867] status: 0000000200000120 badaddr: ffffffff802079e6 cause: 0000000000000003 >> [ 39.364949] [] is_valid_gup_args+0x66/0x8c >> [ 39.365036] [] pin_user_pages+0x38/0x78 >> [ 39.365049] [] gup_test_ioctl+0x2b4/0xc08 >> [ 39.365060] [] __riscv_sys_ioctl+0xba/0xc4 >> [ 39.365072] [] do_trap_ecall_u+0x296/0x370 >> [ 39.365093] [] handle_exception+0x146/0x152 >> [ 39.365220] ---[ end trace 0000000000000000 ]--- >> > > We don't need all of this output for such a simple case. Just the > warning will suffice, and even that is optional for this patch. > > >> Signed-off-by: peng8420.li > > Same rules for the Signed-off-by: real name needed here. > > Combining all of that, your commit message would look like this: > > > From: "Peng Li" > > commit 0f20bba1688b ("mm/gup: explicitly define and check internal GUP > flags, disallow FOLL_TOUCH") marked FOLL_TOUCH as a GUP-internal flag. > > This causes a warning to fire when running gup_test, for example: > > $ ./gup_test -L -r 100 -z > > dmesg: > WARNING: CPU: 1 PID: 117 at mm/gup.c:2512 is_valid_gup_args+0x66/0x8c > > Therefore, remove the "FOLL_TOUCH" test code from gup_test.c. > > Signed-off-by: Peng Li > > With the commit log fixed up, please feel free to add: > > Reviewed-by: John Hubbard Oh, one thing, subject should be something like "selftests/mm: gup_test: stop testing FOLL_TOUCH" -- Cheers David