Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern kthread(9): Attribute uarea to caller for kmsan.



details:   https://anonhg.NetBSD.org/src/rev/90223e8e5471
branches:  trunk
changeset: 370038:90223e8e5471
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Tue Sep 13 09:37:49 2022 +0000

description:
kthread(9): Attribute uarea to caller for kmsan.

diffstat:

 sys/kern/kern_kthread.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (34 lines):

diff -r 17e9b024177a -r 90223e8e5471 sys/kern/kern_kthread.c
--- a/sys/kern/kern_kthread.c   Tue Sep 13 09:35:31 2022 +0000
+++ b/sys/kern/kern_kthread.c   Tue Sep 13 09:37:49 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_kthread.c,v 1.46 2020/08/01 02:04:55 riastradh Exp $      */
+/*     $NetBSD: kern_kthread.c,v 1.47 2022/09/13 09:37:49 riastradh Exp $      */
 
 /*-
  * Copyright (c) 1998, 1999, 2007, 2009, 2019 The NetBSD Foundation, Inc.
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_kthread.c,v 1.46 2020/08/01 02:04:55 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_kthread.c,v 1.47 2022/09/13 09:37:49 riastradh Exp $");
 
 #include <sys/param.h>
 #include <sys/cpu.h>
@@ -41,6 +41,7 @@
 #include <sys/mutex.h>
 #include <sys/sched.h>
 #include <sys/kmem.h>
+#include <sys/msan.h>
 
 #include <uvm/uvm_extern.h>
 
@@ -76,6 +77,7 @@
        if (uaddr == 0) {
                return ENOMEM;
        }
+       kmsan_orig((void *)uaddr, USPACE, KMSAN_TYPE_POOL, __RET_ADDR);
        if ((flag & KTHREAD_TS) != 0) {
                lc = SCHED_OTHER;
        } else {



Home | Main Index | Thread Index | Old Index