From patchwork Thu Sep 24 07:16:53 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Herrenschmidt X-Patchwork-Id: 34209 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from bilbo.ozlabs.org (localhost [127.0.0.1]) by ozlabs.org (Postfix) with ESMTP id 2EF3FB81AA for ; Thu, 24 Sep 2009 17:22:13 +1000 (EST) Received: by ozlabs.org (Postfix) id 841A8B7EEB; Thu, 24 Sep 2009 17:22:07 +1000 (EST) Delivered-To: linuxppc-dev@ozlabs.org Received: from gate.crashing.org (gate.crashing.org [63.228.1.57]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id EC2C6B7EA5 for ; Thu, 24 Sep 2009 17:22:06 +1000 (EST) Received: from [127.0.0.1] (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.13.8) with ESMTP id n8O7GrHM022461; Thu, 24 Sep 2009 02:16:54 -0500 Subject: [PATCH-stable] powerpc: Fix incorrect setting of __HAVE_ARCH_PTE_SPECIAL From: Benjamin Herrenschmidt To: stable Date: Thu, 24 Sep 2009 17:16:53 +1000 Message-Id: <1253776613.7103.433.camel@pasglop> Mime-Version: 1.0 X-Mailer: Evolution 2.26.1 Cc: linuxppc-dev list , bernhard.weirich@riedel.net, RFeany@mrv.com X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org From: Weirich, Bernhard The test that decides whether to define __HAVE_ARCH_PTE_SPECIAL on powerpc is bogus and will end up always defining it, even when _PAGE_SPECIAL is not supported (in which case it's 0) such as on 8xx or 40x processors. Signed-off-by: Bernhard Weirich Signed-off-by: Benjamin Herrenschmidt --- arch/powerpc/include/asm/pte-common.h | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Greg: I'm going to fix upstream differently, by having all CPU types actually support _PAGE_SPECIAL, but I prefer the simple and obvious fix for -stable. This should apply to v2.6.30 and v2.6.31 diff --git a/arch/powerpc/include/asm/pte-common.h b/arch/powerpc/include/asm/pte-common.h index a7e210b..0cd2e34 100644 --- a/arch/powerpc/include/asm/pte-common.h +++ b/arch/powerpc/include/asm/pte-common.h @@ -176,7 +176,7 @@ extern unsigned long bad_call_to_PMD_PAGE_SIZE(void); #define HAVE_PAGE_AGP /* Advertise support for _PAGE_SPECIAL */ -#ifdef _PAGE_SPECIAL +#if _PAGE_SPECIAL != 0 #define __HAVE_ARCH_PTE_SPECIAL #endif