From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753475Ab1IVSL7 (ORCPT ); Thu, 22 Sep 2011 14:11:59 -0400 Received: from cantor2.suse.de ([195.135.220.15]:52182 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753007Ab1IVSL6 (ORCPT ); Thu, 22 Sep 2011 14:11:58 -0400 Date: Thu, 22 Sep 2011 20:11:56 +0200 Message-ID: From: Takashi Iwai To: Yinghai Lu Cc: "Rafael J. Wysocki" , linux-kernel@vger.kernel.org, "H. Peter Anvin" , oneukum@suse.de, x86@kernel.org, Linux PM mailing list , Ingo Molnar Subject: Re: S4 resume broken since 2.6.39 (3.1, too) In-Reply-To: References: <201109212048.23074.rjw@sisk.pl> User-Agent: Wanderlust/2.15.6 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL/10.7 Emacs/23.3 (x86_64-suse-linux-gnu) MULE/6.0 (HANACHIRUSATO) MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Content-Type: text/plain; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org At Thu, 22 Sep 2011 07:33:17 -0700, Yinghai Lu wrote: > > On Wed, Sep 21, 2011 at 11:48 AM, Rafael J. Wysocki wrote: > > It looks like init_memory_mapping() is sometimes called with "end" > > beyond the last mapped PFN and it explodes when we try to write stuff to > > that address during image restoration. > > > > IOW, the Yinghai's assumption that init_memory_mapping() would always be > > called with a "good end" on x86_64 was overomptimistic. > > for 64bit x86, kernel_physical_mapping_init() will use > map_low_page()/call early_memmap() to access ram for page_table that is above > rather last mapped PFN. > > the point is: > on system with 64g, usable ram will be [0,2048m), [4g, 64g) > init_memory_mapping will be called two times for them. > before putting page_table high, > page table will be two parts: one is just below 512M, and one below 2048m. > after putting page_table high, > page table will be two parts: one is just below 2048M, and one below 64G. So, how can this change break S4 resume? Any hint for further debugging? thanks, Takashi