lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 2 Sep 2020 08:52:24 -0400 From: Qian Cai <cai@....pw> To: Uriel Guajardo <urielguajardojr@...il.com> Cc: brendanhiggins@...gle.com, urielguajardo@...gle.com, linux-kernel@...r.kernel.org, linux-kselftest@...r.kernel.org, kunit-dev@...glegroups.com, sfr@...b.auug.org.au, linux-next@...r.kernel.org Subject: Re: [PATCH 2/2] kunit: ubsan integration On Thu, Aug 06, 2020 at 05:43:26PM +0000, Uriel Guajardo wrote: > Integrates UBSAN into the KUnit testing framework. It fails KUnit tests > whenever it reports undefined behavior. > > Signed-off-by: Uriel Guajardo <urielguajardo@...gle.com> It looks like this patch had been merged into linux-next but the "[PATCH 1/2] kunit: support failure from dynamic analysis tools" did not. Hence, it caused a compiling failure. lib/ubsan.c: In function ‘ubsan_prologue’: lib/ubsan.c:141:2: error: implicit declaration of function ‘kunit_fail_current_test’; did you mean ‘kunit_init_test’? [-Werror=implicit-function-declaration] kunit_fail_current_test(); ^~~~~~~~~~~~~~~~~~~~~~~ kunit_init_test cc1: some warnings being treated as errors > --- > lib/ubsan.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/lib/ubsan.c b/lib/ubsan.c > index cb9af3f6b77e..1460e2c828c8 100644 > --- a/lib/ubsan.c > +++ b/lib/ubsan.c > @@ -14,6 +14,7 @@ > #include <linux/types.h> > #include <linux/sched.h> > #include <linux/uaccess.h> > +#include <kunit/test.h> > > #include "ubsan.h" > > @@ -137,6 +138,7 @@ static void ubsan_prologue(struct source_location *loc, const char *reason) > { > current->in_ubsan++; > > + kunit_fail_current_test(); > pr_err("========================================" > "========================================\n"); > pr_err("UBSAN: %s in %s:%d:%d\n", reason, loc->file_name, > -- > 2.28.0.163.g6104cc2f0b6-goog >
Powered by blists - more mailing lists