From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from sj-iport-1.cisco.com (sj-iport-1.cisco.com [171.71.176.70]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client CN "sj-iport-1.cisco.com", Issuer "Cisco SSCA" (not verified)) by ozlabs.org (Postfix) with ESMTPS id C81EADDEEF for ; Tue, 16 Sep 2008 08:51:52 +1000 (EST) From: Roland Dreier To: Kumar Gala Subject: Re: [PATCH] powerpc: Avoid integer overflow in page_is_ram() References: <18638.50702.962371.862911@cargo.ozlabs.ibm.com> Date: Mon, 15 Sep 2008 15:51:35 -0700 In-Reply-To: (Kumar Gala's message of "Mon, 15 Sep 2008 17:44:05 -0500") Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: linuxppc-dev@ozlabs.org, Paul Mackerras List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , > > #ifndef CONFIG_PPC64 /* XXX for now */ > > - return paddr < __pa(high_memory); > > + return pfn < max_pfn; > > #else > > + unsigned long paddr = (pfn << PAGE_SHIFT); > > seems like this could be a phys_addr_t Yes, it could I guess, but that would be an unrelated change, and I'm not sure there's much point given this is in 64-bit-only code. - R.