From patchwork Wed May 12 15:45:16 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Egger X-Patchwork-Id: 52391 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail-wy0-f184.google.com (mail-wy0-f184.google.com [74.125.82.184]) by ozlabs.org (Postfix) with ESMTP id 4CFBCB7DF4 for ; Thu, 13 May 2010 01:45:20 +1000 (EST) Received: by wyi11 with SMTP id 11sf74869wyi.11 for ; Wed, 12 May 2010 08:45:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=beta; h=domainkey-signature:received:x-beenthere:received:received:received :received:received-spf:received:received:date:from:to:cc:subject :message-id:references:mime-version:in-reply-to:user-agent :x-original-authentication-results:x-original-sender:reply-to :precedence:mailing-list:list-id:list-post:list-help:list-archive :sender:list-subscribe:list-unsubscribe:content-type :content-disposition; bh=KKsVqW6UBEFHIehTBsbJwLNYVybyB2iANWfpyS5p6tM=; b=hyGVLV5r+7LENg/kV1AlqMu3iE7bOI6ADKK15t/0rTdoM1BGGntacgvJ7Yoqb99Lrb CFWppbpvNkbUoCBDEH9LbkEH40LJLIjBevDlb/mnH+zgpvN3Pq10gVYhe5pSfKTXRuT8 1nD50QWmlvhF4af4QS3JlqdhOK6qHHUc59qrA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlegroups.com; s=beta; h=x-beenthere:received-spf:date:from:to:cc:subject:message-id :references:mime-version:in-reply-to:user-agent :x-original-authentication-results:x-original-sender:reply-to :precedence:mailing-list:list-id:list-post:list-help:list-archive :sender:list-subscribe:list-unsubscribe:content-type :content-disposition; b=RR734ffWAF6cNqpJP8wqUG7PzdEpp8/RuGf7/RGkvmyK6dzL23zCWoqvZNuH9h2nOh 8lfIxlg6hxzxfsbXF5rgwGeM22JNV9z5roJYqb761ceo6L7+/2T55PcGgZWRH3frghuX rs17SqkuEdOdcXyXBwwb/1jmF9pQ9fAkhN95s= Received: by 10.223.58.16 with SMTP id e16mr885337fah.6.1273679118615; Wed, 12 May 2010 08:45:18 -0700 (PDT) X-BeenThere: rtc-linux@googlegroups.com Received: by 10.223.32.71 with SMTP id b7ls26167987fad.0.p; Wed, 12 May 2010 08:45:17 -0700 (PDT) Received: by 10.223.5.84 with SMTP id 20mr481718fau.15.1273679116961; Wed, 12 May 2010 08:45:16 -0700 (PDT) Received: by 10.223.5.84 with SMTP id 20mr481717fau.15.1273679116929; Wed, 12 May 2010 08:45:16 -0700 (PDT) Received: from faui40.informatik.uni-erlangen.de (faui40.informatik.uni-erlangen.de [131.188.34.40]) by gmr-mx.google.com with ESMTP id g17si234809fai.6.2010.05.12.08.45.16; Wed, 12 May 2010 08:45:16 -0700 (PDT) Received-SPF: pass (google.com: domain of siccegge@faui48a.informatik.uni-erlangen.de designates 131.188.34.40 as permitted sender) client-ip=131.188.34.40; Received: from faui48a.informatik.uni-erlangen.de (faui48a.informatik.uni-erlangen.de [131.188.34.55]) by faui40.informatik.uni-erlangen.de (Postfix) with ESMTP id 9301D5F1C3; Wed, 12 May 2010 17:45:16 +0200 (MEST) Received: by faui48a.informatik.uni-erlangen.de (Postfix, from userid 31996) id 82C2D7753DF; Wed, 12 May 2010 17:45:16 +0200 (CEST) Date: Wed, 12 May 2010 17:45:16 +0200 From: Christoph Egger To: Alessandro Zummo , Paul Gortmaker , Andrew Morton , maltesch@gmx.de, Ralf Baechle , Herton Ronaldo Krzesinski , rtc-linux@googlegroups.com, linux-kernel@vger.kernel.org Cc: vamos@i4.informatik.uni-erlangen.de Subject: [rtc-linux] Re: [PATCH] Un(de)selectable block for DISCONTIGMEM/64BIT on parisc Message-ID: <20100512154516.GB722@faui48a.informatik.uni-erlangen.de> References: <20100512153229.GA3379@faui49.informatik.uni-erlangen.de> MIME-Version: 1.0 In-Reply-To: <20100512153229.GA3379@faui49.informatik.uni-erlangen.de> User-Agent: Mutt/1.5.18 (2008-05-17) X-Original-Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of siccegge@faui48a.informatik.uni-erlangen.de designates 131.188.34.40 as permitted sender) smtp.mail=siccegge@faui48a.informatik.uni-erlangen.de X-Original-Sender: siccegge@cs.fau.de Reply-To: rtc-linux@googlegroups.com Precedence: list Mailing-list: list rtc-linux@googlegroups.com; contact rtc-linux+owners@googlegroups.com List-ID: List-Post: , List-Help: , List-Archive: Sender: rtc-linux@googlegroups.com List-Subscribe: , List-Unsubscribe: , Content-Disposition: inline Hi all! Seems I messed up the logic a bit -- reading the ifndef for an ifdef reversing the actual behaviour of the code when applying the patch. Below the corrected variant. Regards Christoph On Wed, May 12, 2010 at 05:32:29PM +0200, Christoph Egger wrote: > Hi all! > > As part of the VAMOS[0] research project at the University of > Erlangen we are looking at multiple integrity errors in linux' > configuration system. > > When considering the restrictions inposed in kconfig 64BIT > will *always* be set when DISCONTIGMEM is present on parisc so the > code path depending on !64BIT is actually unreachable and the whole > check unnecessary. > > Please keep me informed of this patch getting confirmed / > merged so we can keep track of it. > > Regards > > Christoph Egger > > [0] http://vamos1.informatik.uni-erlangen.de/ ---- From 5eeae9c56e2602a68b62b21691e6756fb5198dd7 Mon Sep 17 00:00:00 2001 From: Christoph Egger Date: Wed, 12 May 2010 16:59:24 +0200 Subject: [PATCH] on parisc CONFIG_DISCONTIGMEM always depends on CONFIG_64BIT Removing a conditional on 64BIT inside a DISCONTIGMEM block inside arch/parisc. DISCONTIGMEM depends on ARCH_DISCONTIGMEM_ENABLE either directly or through DISCONTIGMEM_MANUAL which in turn depends on 64BIT inside Kconfig so the check and the else case isn't needed at all (the else case can't ever be reached) Signed-off-by: Christoph Egger --- arch/parisc/include/asm/mmzone.h | 5 ----- 1 files changed, 0 insertions(+), 5 deletions(-) diff --git a/arch/parisc/include/asm/mmzone.h b/arch/parisc/include/asm/mmzone.h index 9608d2c..dbddcac 100644 --- a/arch/parisc/include/asm/mmzone.h +++ b/arch/parisc/include/asm/mmzone.h @@ -35,12 +35,8 @@ extern struct node_map_data node_data[]; #define PFNNID_MAP_MAX 512 /* support 512GB */ extern unsigned char pfnnid_map[PFNNID_MAP_MAX]; -#ifndef CONFIG_64BIT -#define pfn_is_io(pfn) ((pfn & (0xf0000000UL >> PAGE_SHIFT)) == (0xf0000000UL >> PAGE_SHIFT)) -#else /* io can be 0xf0f0f0f0f0xxxxxx or 0xfffffffff0000000 */ #define pfn_is_io(pfn) ((pfn & (0xf000000000000000UL >> PAGE_SHIFT)) == (0xf000000000000000UL >> PAGE_SHIFT)) -#endif static inline int pfn_to_nid(unsigned long pfn) {