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-next>] [day] [month] [year] [list]
Message-ID: <CACysShg0WNk39ygO0gAdGmN8-SOHhnrL8cycNoWKxntx06Ov_Q@mail.gmail.com>
Date:	Tue, 10 Mar 2015 16:03:40 +0300
From:	Alexander Ivchenko <aivchenk@...il.com>
To:	linux-kernel@...r.kernel.org
Subject: [PATCH] Remove "#ifdef linux" from include/linux/a.out.h

Hi,

I'm resending the patch from here:
http://lkml.iu.edu/hypermail/linux/kernel/1502.3/00286.html

GCC fixincludes always change that header to comply with C standard.
Here is the comment from fixincludes code:
/* Fix for machine name #ifdefs that are not in the namespace reserved
   by the C standard.  They won't be defined if compiling with -ansi,
   and the headers will break.  We go to some trouble to only change
   #ifdefs where the macro is defined by GCC in non-ansi mode; this
   minimizes the number of headers touched.  */

So gcc build system will change "#ifdef linux" to "#ifdef __linux__".

After talking to Andi Kleen, I was proposed to remove that ifdef completely
(instead of changing linux to __linux__ in the header), since it does
not make much sense to include linux/a.out.h on a non linux system.

The following patch does that, is it ok?

From: Alexander Ivchenko <alexander.ivchenko@...el.com>
Date: Tue, 24 Feb 2015 11:28:20 +0300
Subject: [PATCH] Remove "ifdef linux" guard from include/linux/a.out.h.

Signed-off-by: Alexander Ivchenko <alexander.ivchenko@...el.com>
---
 include/linux/a.out.h | 2 --
 1 file changed, 2 deletions(-)

diff --git a/include/linux/a.out.h b/include/linux/a.out.h
index e86dfca..47e647f 100644
--- a/include/linux/a.out.h
+++ b/include/linux/a.out.h
@@ -129,7 +129,6 @@ enum machine_type {
 #define SEGMENT_SIZE PAGE_SIZE
 #endif

-#ifdef linux
 #ifdef __KERNEL__
 #include <asm/page.h>
 #else
@@ -146,7 +145,6 @@ enum machine_type {
 #endif
 #endif
 #endif
-#endif

 #define _N_SEGMENT_ROUND(x) ALIGN(x, SEGMENT_SIZE)

--
1.9.3



thanks,
Alexander
--
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