* [merged mm-nonmm-stable] kcov-load-acquire-coverage-count-in-user-space-code.patch removed from -mm tree
@ 2025-09-14 0:34 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2025-09-14 0:34 UTC (permalink / raw)
To: mm-commits, tglx, glider, elver, dvyukov, corbet, arnd,
andreyknvl, soham.bagchi, akpm
The quilt patch titled
Subject: kcov: load acquire coverage count in user-space code
has been removed from the -mm tree. Its filename was
kcov-load-acquire-coverage-count-in-user-space-code.patch
This patch was dropped because it was merged into the mm-nonmm-stable branch
of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
------------------------------------------------------
From: Soham Bagchi <soham.bagchi@utah.edu>
Subject: kcov: load acquire coverage count in user-space code
Date: Mon, 28 Jul 2025 12:43:18 -0600
Update the KCOV documentation to use a load-acquire operation for the
first element of the shared memory buffer between kernel-space and
user-space.
The load-acquire pairs with the write memory barrier used in
kcov_move_area().
[soham.bagchi@utah.edu: v2]
Link: https://lkml.kernel.org/r/20250803180558.2967962-1-soham.bagchi@utah.edu
Link: https://lkml.kernel.org/r/20250728184318.1839137-2-soham.bagchi@utah.edu
Signed-off-by: Soham Bagchi <soham.bagchi@utah.edu>
Reviewed-by: Marco Elver <elver@google.com>
Cc: Alexander Potapenko <glider@google.com>
Cc: Andrey Konovalov <andreyknvl@gmail.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Dmitriy Vyukov <dvyukov@google.com>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Thomas Gleinxer <tglx@linutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
Documentation/dev-tools/kcov.rst | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
--- a/Documentation/dev-tools/kcov.rst~kcov-load-acquire-coverage-count-in-user-space-code
+++ a/Documentation/dev-tools/kcov.rst
@@ -361,7 +361,12 @@ local tasks spawned by the process and t
*/
sleep(2);
- n = __atomic_load_n(&cover[0], __ATOMIC_RELAXED);
+ /*
+ * The load to the coverage count should be an acquire to pair with
+ * pair with the corresponding write memory barrier (smp_wmb()) on
+ * the kernel-side in kcov_move_area().
+ */
+ n = __atomic_load_n(&cover[0], __ATOMIC_ACQUIRE);
for (i = 0; i < n; i++)
printf("0x%lx\n", cover[i + 1]);
if (ioctl(fd, KCOV_DISABLE, 0))
_
Patches currently in -mm which might be from soham.bagchi@utah.edu are
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-09-14 0:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-14 0:34 [merged mm-nonmm-stable] kcov-load-acquire-coverage-count-in-user-space-code.patch removed from -mm tree Andrew Morton
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.