Add kcsan_md_unsupported from NetBSD.
It's used to ignore virtual addresses that may have a different physical address depending on the CPU. Sponsored by: DARPA, AFRL
This commit is contained in:
parent
34537aa902
commit
e95c204297
@ -35,6 +35,12 @@
|
||||
#include <machine/stack.h>
|
||||
#include <machine/vmparam.h>
|
||||
|
||||
static inline bool
|
||||
kcsan_md_unsupported(vm_offset_t addr)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
static inline bool
|
||||
kcsan_md_is_avail(void)
|
||||
{
|
||||
|
@ -35,6 +35,12 @@
|
||||
#include <machine/stack.h>
|
||||
#include <machine/vmparam.h>
|
||||
|
||||
static inline bool
|
||||
kcsan_md_unsupported(vm_offset_t addr)
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
static inline bool
|
||||
kcsan_md_is_avail(void)
|
||||
{
|
||||
|
@ -151,6 +151,8 @@ kcsan_access(uintptr_t addr, size_t size, bool write, bool atomic, uintptr_t pc)
|
||||
|
||||
if (__predict_false(!kcsan_enabled))
|
||||
return;
|
||||
if (__predict_false(kcsan_md_unsupported((vm_offset_t)addr)))
|
||||
return;
|
||||
|
||||
new.addr = addr;
|
||||
new.size = size;
|
||||
|
Loading…
x
Reference in New Issue
Block a user