Hi, On Friday, 30 of September 2005 00:29, Siddha, Suresh B wrote: > On Fri, Sep 30, 2005 at 12:01:08AM +0200, Rafael J. Wysocki wrote: > > On Thursday, 29 of September 2005 02:00, Siddha, Suresh B wrote: > > > > > > My patch as such shouldn't change the behavior of the existing swsup > > > code. I am making only boot_level4_pgt as initdata. But not the > > > init_level4_pgt. > > > > Suresh, unfortunately the kernel does not boot with your patch, because > > Did you try just only my patch on top of 2.6.14-rc2? You can get that > patch from http://www.x86-64.org/lists/discuss/msg07313.html The patch that I tested is attached. I think it's the same one. I've just applied it on top of 2.6.14-rc2-git7, and it doesn't boot. > > it clears init_level4_pgt. > > what is wrong with zapping low mappings? Looks like someother change > you are trying assumes that low mappings are always present in init_level4_pgt, > which is wrong.. Nope. The problem (as I see it) is this: In x86_64_start_kernel() you copy boot_level4_pgt[] into init_level4_pgt[], and you make the latter your current PGD by loading cr3 with its address. Fine. With this PGD you call start_kernel() which calls setup_arch(), which calls zap_low_mappings(0) that fills init_level4_pgt[] (which at this moment is still your current PGD) with zeros ... > > +++ linux-2.6.14-rc2-git7/arch/x86_64/mm/init.c 2005-09-29 22:13:55.000000000 +0200 > > @@ -313,7 +313,7 @@ > > void __cpuinit zap_low_mappings(int cpu) > > { > > if (cpu == 0) { > > - pgd_t *pgd = pgd_offset_k(0UL); > > + pgd_t *pgd = boot_level4_pgt; > > pgd_clear(pgd); > > Don't do this. Its wrong. Perhaps it is. > Please send me your patch that you are having problems with. I can take > a look at it. I'll post it in a while to the list. I'm not touching the init code anyway and the box hangs before it has a chance to send anything to the serial console. Greetings, Rafael