Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752717AbdFNPOi (ORCPT ); Wed, 14 Jun 2017 11:14:38 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:33995 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751990AbdFNPOf (ORCPT ); Wed, 14 Jun 2017 11:14:35 -0400 Date: Wed, 14 Jun 2017 08:14:28 -0700 From: Christoph Hellwig To: Zack Weinberg Cc: Linus Torvalds , Christoph Hellwig , Linux Kernel Mailing List Subject: Re: [PATCH] uapi/linux/a.out.h: don't use deprecated system-specific predefines. Message-ID: <20170614151428.GA21134@infradead.org> References: <20170601210045.8638-1-zackw@panix.com> <20170602071014.GA16118@infradead.org> <3c311c8b-e8a3-0cbe-1c7e-b336c4c0f894@panix.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.8.0 (2017-02-23) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2637 Lines: 82 On Wed, Jun 14, 2017 at 08:43:08AM -0400, Zack Weinberg wrote: > Christoph's patch doesn't seem to have been applied yet. Is there > anything I can do to help? A formal submission usually helps. I didn't want to post it under my name as it's mostly your work. How about this: --- From: Zack Weinberg Subject: uapi/linux/a.out.h: don't use deprecated system-specific predefines. uapi/linux/a.out.h uses a number of predefined macros that are deprecated because they're in the application namespace (e.g. '#ifdef linux' instead of '#ifdef __linux__'). This patch either corrects or just removes them if they are not applicable to Linux. The primary reason this is worth bothering to fix, considering how obsolete a.out binary support is, is that the GCC build process considers this such a severe error that it will copy the header into a private directory and change the macro names, which causes future updates to the header to be masked. This header probably doesn't get updated very often anymore, but it is the _only_ uapi header that gets this treatment, so IMHO it is worth patching just to drive that number all the way to zero. Signed-off-by: Zack Weinberg [hch: removed dead conditionals] Signed-off-by: Christoph Hellwig diff --git a/include/uapi/linux/a.out.h b/include/uapi/linux/a.out.h index 7caf44c7fa51..295cd3ef6330 100644 --- a/include/uapi/linux/a.out.h +++ b/include/uapi/linux/a.out.h @@ -112,24 +112,7 @@ enum machine_type { #define N_TXTADDR(x) (N_MAGIC(x) == QMAGIC ? PAGE_SIZE : 0) #endif -/* Address of data segment in memory after it is loaded. - Note that it is up to you to define SEGMENT_SIZE - on machines not listed here. */ -#if defined(vax) || defined(hp300) || defined(pyr) -#define SEGMENT_SIZE page_size -#endif -#ifdef sony -#define SEGMENT_SIZE 0x2000 -#endif /* Sony. */ -#ifdef is68k -#define SEGMENT_SIZE 0x20000 -#endif -#if defined(m68k) && defined(PORTAR) -#define PAGE_SIZE 0x400 -#define SEGMENT_SIZE PAGE_SIZE -#endif - -#ifdef linux +/* Address of data segment in memory after it is loaded. */ #ifndef __KERNEL__ #include #endif @@ -142,7 +125,6 @@ enum machine_type { #endif #endif #endif -#endif #define _N_SEGMENT_ROUND(x) ALIGN(x, SEGMENT_SIZE) @@ -260,13 +242,7 @@ struct relocation_info unsigned int r_extern:1; /* Four bits that aren't used, but when writing an object file it is desirable to clear them. */ -#ifdef NS32K - unsigned r_bsr:1; - unsigned r_disp:1; - unsigned r_pad:2; -#else unsigned int r_pad:4; -#endif }; #endif /* no N_RELOCATION_INFO_DECLARED. */