From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from e8.ny.us.ibm.com (e8.ny.us.ibm.com [32.97.182.138]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "e8.ny.us.ibm.com", Issuer "GeoTrust SSL CA" (verified OK)) by ozlabs.org (Postfix) with ESMTPS id AB226B6F62 for ; Thu, 13 Oct 2011 01:15:41 +1100 (EST) Received: from d01relay05.pok.ibm.com (d01relay05.pok.ibm.com [9.56.227.237]) by e8.ny.us.ibm.com (8.14.4/8.13.1) with ESMTP id p9CE0CIq022989 for ; Wed, 12 Oct 2011 10:00:12 -0400 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d01relay05.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p9CEFV7c219456 for ; Wed, 12 Oct 2011 10:15:32 -0400 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p9CEF5op007611 for ; Wed, 12 Oct 2011 08:15:06 -0600 Subject: Re: [PATCH 2/3] [44x] Enable CONFIG_RELOCATABLE for PPC44x From: Dave Hansen To: Suzuki Poulose In-Reply-To: <4E943C70.4030106@in.ibm.com> References: <20111010094627.16589.52367.stgit@suzukikp.in.ibm.com> <20111010095514.16589.85241.stgit@suzukikp.in.ibm.com> <4E9332AA.1050307@freescale.com> <4E943C70.4030106@in.ibm.com> Content-Type: text/plain; charset="UTF-8" Date: Wed, 12 Oct 2011 07:15:02 -0700 Message-ID: <1318428902.3782.9.camel@nimitz> Mime-Version: 1.0 Cc: Michal Simek , tmarri@apm.com, Mahesh Jagannath Salgaonkar , David Laight , Paul Mackerras , Scott Wood , linux ppc dev , Vivek Goyal List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , On Tue, 2011-10-11 at 18:24 +0530, Suzuki Poulose wrote: > On 10/10/11 23:30, Scott Wood wrote: > > On 10/10/2011 04:56 AM, Suzuki K. Poulose wrote: > >> #if defined(CONFIG_RELOCATABLE)&& defined(CONFIG_44x) > >> #define __va(x) ((void *)(unsigned long)((phys_addr_t)(x) - PHYSICAL_START + (KERNELBASE + RELOC_OFFSET))) > >> #define __pa(x) ((unsigned long)(x) + PHYSICAL_START - (KERNELBASE + RELOC_OFFSET)) > >> #endif > > > > Why is this 44x-specific? > > As of now, we compile with relocations only for the 44x. We could make this > generic once the approach is accepted by everyone and implemented on the other > platforms. This is not the place to enforce that kind of thing. If CONFIG_RELOCATABLE is only supported on one platform, then do: config RELOCATABLE depends on 44x and take the 44x reference out of the #ifdef. -- Dave