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
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 19 Nov 2006 09:08:47 -0800
From:	Roland Dreier <rdreier@...co.com>
To:	Olaf Hering <olaf@...fle.de>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: uml fails to compile due to missing offsetof

 > I fail to see how arch/um/sys-i386/user-offsets.c can compile since
 > offsetof() was declared __KERNEL__ only in include/linux/stddef.h.
 > Does it work for anyone else? If so, is linux/stddef.h or
 > /usr/include/linux/stddef.h used during compilation?
 > The x86_64 variant looks weird as well, linux/stddef.h is appearently
 > included via some other headers.

Yes, the

#include <linux/stddef.h>

looks weird to me.  AFAIK the C standard says that offsetof() comes
from plain old <stddef.h>.  Does the (untested) patch below fix the
build for you?

diff --git a/arch/um/sys-i386/user-offsets.c b/arch/um/sys-i386/user-offsets.c
index 6f4ef2b..447306b 100644
--- a/arch/um/sys-i386/user-offsets.c
+++ b/arch/um/sys-i386/user-offsets.c
@@ -2,7 +2,7 @@ #include <stdio.h>
 #include <signal.h>
 #include <asm/ptrace.h>
 #include <asm/user.h>
-#include <linux/stddef.h>
+#include <stddef.h>
 #include <sys/poll.h>
 
 #define DEFINE(sym, val) \
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ