Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/x86/x86 Switch to __noubsan in x86_hotpatch()



details:   https://anonhg.NetBSD.org/src/rev/0651411e4f39
branches:  trunk
changeset: 454477:0651411e4f39
user:      kamil <kamil%NetBSD.org@localhost>
date:      Wed Sep 18 15:07:08 2019 +0000

description:
Switch to __noubsan in x86_hotpatch()

diffstat:

 sys/arch/x86/x86/patch.c |  10 +++-------
 1 files changed, 3 insertions(+), 7 deletions(-)

diffs (31 lines):

diff -r b0118c0235b3 -r 0651411e4f39 sys/arch/x86/x86/patch.c
--- a/sys/arch/x86/x86/patch.c  Wed Sep 18 15:06:03 2019 +0000
+++ b/sys/arch/x86/x86/patch.c  Wed Sep 18 15:07:08 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: patch.c,v 1.36 2019/05/28 13:20:23 kamil Exp $ */
+/*     $NetBSD: patch.c,v 1.37 2019/09/18 15:07:08 kamil Exp $ */
 
 /*-
  * Copyright (c) 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: patch.c,v 1.36 2019/05/28 13:20:23 kamil Exp $");
+__KERNEL_RCSID(0, "$NetBSD: patch.c,v 1.37 2019/09/18 15:07:08 kamil Exp $");
 
 #include "opt_lockdebug.h"
 #ifdef i386
@@ -133,11 +133,7 @@
 }
 
 /* The local variables have unknown alignment to UBSan */
-#if defined(__clang__)
-__attribute__((no_sanitize("undefined")))
-#else
-__attribute__((no_sanitize_undefined))
-#endif
+__noubsan
 void
 x86_hotpatch(uint32_t name, const uint8_t *bytes, size_t size)
 {



Home | Main Index | Thread Index | Old Index