Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

T60/T61 series specific matters only
Message
Author
Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#61 Post by Uncle Joe » Wed Aug 26, 2009 10:04 am

Well, I've found what's causing grub2 to crash when running the CD in a VM. It's because I hard coded a e820 physical memory map that assumes there's 4gb. Grub uses the memory at the highest accessible address, so if the memory doesn't exist, it won't function. Since you have 4gb, I'm guessing the problem is Grub is trying to use memory reserved for GMA 950, since I didn't mark that region as reserved.

TOP OF RAM = 0xf0000000
SMRAM 1 Mb (below top)
FRAMEBUFFER 8 Mb (below SRAM)

I've created a new sysrescue_grub2.iso. If it still doesn't work, send me the dmesg dump so I can find out what your configuration really is.

Also, I've created a DOS boot disk for flashing http://www.cc.gatech.edu/~yzhang67/phlash.iso to save you some trouble.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#62 Post by jack_b_uta » Wed Aug 26, 2009 11:16 am

I did try using a Bootable Floppy (borrowed a USB external floppy drive from a buddy). I got to the point where I was able to get Phlash16.exe to run in Dos mode and it started up. (Had to rename NEW.WPH to BIOS.WPH. Phlash16.exe errored out saying "Models dont match" or something to that effect. I think the BIOS has a Header of some sorts, to identify what model it goes to. Maybe your mod is shifting that to a position where Phlash16 does not look.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#63 Post by Uncle Joe » Wed Aug 26, 2009 11:28 am

That is very strange. Can you try flashing the original 3.12 BIOS at http://www-307.ibm.com/pc/support/site. ... MIGR-67008. I assumed this should work for all 3000 N100s.

Actually, I think I know why it's not working. There are actually 2 BIOSes that come with that URL. I use DL01108A for my laptop. When you run AdRomLdr, does it choose DL00206A.WPH? If that's the case, then I would need to mod that BIOS instead.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#64 Post by Uncle Joe » Wed Aug 26, 2009 1:04 pm

I assume your laptop does use the other BIOS file. A most grievous mistake. Here's the modded DL00206A.WPH Image. I've also slipped it into phlash.iso, the DOS boot disk (execute "phlash16 DL00206A.WPH" or "phlash16 DL01108A.WPH"). Although I can't test the BIOS, I'm pretty sure it will work because I found and patched an identical instruction sequence.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#65 Post by jack_b_uta » Wed Aug 26, 2009 2:02 pm

That BIOS flash worked. Still see the Total Memory in BIOS as 3072, but the Version number has changed to V2.06. The system rescue CD still does not boot. It looks like it wants to boot, and the machine restarts. Standby works. I can click standby from Windows shutdown menu, or simply close the lid to put the system to standby.

I'll try sleep feature and report back

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#66 Post by Uncle Joe » Wed Aug 26, 2009 2:15 pm

Good, it works.
Still see the Total Memory in BIOS as 3072
This is expected, and doesn't mean much since I don't apply the fix ups until after BIOS initialization. All the BIOS patch does is disable locking the memory controller configuration.

Like I said earlier, I suspect the e820 memory map I semi hard-coded into the Grub boot loader is wrong and causing Grub to use invalid memory. Get the real systemrescuecd, run it, and send me dmesg so I can see the memory map and PCI devices:

1. At command prompt, "dmesg > /tmp/dmesg"
2. "mkdir /mnt1"
3. "mount /dev/sda1 /mnt1 -tntfs-3g" this should be your windows drive (try sda2, etc if doesn't work)
4. "cp /tmp/dmesg /mnt1"
5. "umount /mnt1"
6. Reboot and post dmesg here and delete it from C:\

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#67 Post by jack_b_uta » Thu Aug 27, 2009 2:20 pm

Sorry for the delay...I am having to do all the weekend chores during the week since I was out over the last weekend. Anyways here is the output of dmsg and I also listed lspci.
Since the output of dmesg is quite long I have pasted the PCI devices and memory map info below. Please let me know if you need more.

--------------DMESG Begin----------------------
Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Linux version 2.6.29.06-std123 (root@catalyst) (gcc version 4.3.3 (Gentoo 4.3.3-r2 p1.1, pie-10.1.5) ) #1 SMP Thu Aug 6 19:24:58 UTC 2009
KERNEL supported cpus:
Intel GenuineIntel
AMD AuthenticAMD
NSC Geode by NSC
Cyrix CyrixInstead
Centaur CentaurHauls
Transmeta GenuineTMx86
Transmeta TransmetaCPU
UMC UMC UMC UMC
BIOS-provided physical RAM map:
BIOS-e820: 0000000000000000 - 000000000009f800 (usable)
BIOS-e820: 000000000009f800 - 00000000000a0000 (reserved)
BIOS-e820: 00000000000dc000 - 0000000000100000 (reserved)
BIOS-e820: 0000000000100000 - 00000000bf690000 (usable)
BIOS-e820: 00000000bf690000 - 00000000bf700000 (ACPI NVS)
BIOS-e820: 00000000bf700000 - 00000000c0000000 (reserved)
BIOS-e820: 00000000e0000000 - 00000000f0000000 (reserved)
BIOS-e820: 00000000fec00000 - 00000000fec10000 (reserved)
BIOS-e820: 00000000fed00000 - 00000000fed00400 (reserved)
BIOS-e820: 00000000fed14000 - 00000000fed1a000 (reserved)
BIOS-e820: 00000000fed1c000 - 00000000fed90000 (reserved)
BIOS-e820: 00000000fee00000 - 00000000fee01000 (reserved)
BIOS-e820: 00000000ff000000 - 0000000100000000 (reserved)
DMI present.
last_pfn = 0xbf690 max_arch_pfn = 0x100000
x86 PAT enabled: cpu 0, old 0x7040600070406, new 0x7010600070106
kernel direct mapping tables up to 373fe000 @ 7000-d000
RAMDISK: 7f35a000 - 7ffff304
Allocated new RAMDISK: 00c89000 - 0192e304
Move RAMDISK from 000000007f35a000 - 000000007ffff303 to 00c89000 - 0192e303
ACPI: RSDP 000F6540, 0024 (r2 LENOVO)
ACPI: XSDT BF693BAE, 0084 (r1 PTLTD XSDT 37 LTP 0)
ACPI: FACP BF699D6E, 00F4 (r3 INTEL CALISTGA 37 ALAN 1)
FADT: X_PM1a_EVT_BLK.bit_width (16) does not match PM1_EVT_LEN (4)
ACPI: DSDT BF69598D, 436D (r1 LENOVO TP-61 37 INTL 20050624)
ACPI: FACS BF69AFC0, 0040
ACPI: APIC BF699E62, 0068 (r1 INTEL CALISTGA 37 LOHR 5A)
ACPI: HPET BF699ECA, 0038 (r1 INTEL CALISTGA 37 LOHR 5A)
ACPI: MCFG BF699F02, 003C (r1 INTEL CALISTGA 37 LOHR 5A)
ACPI: TCPA BF699F3E, 0032 (r1 Phoeni x 37 TL 0)
ACPI: APIC BF699F70, 0068 (r1 PTLTD APIC 37 LTP 0)
ACPI: BOOT BF699FD8, 0028 (r1 PTLTD $SBFTBL$ 37 LTP 1)
ACPI: SSDT BF69533E, 064F (r1 SataRe SataPri 1000 INTL 20050624)
ACPI: SSDT BF694CAC, 0692 (r1 SataRe SataSec 1000 INTL 20050624)
ACPI: SSDT BF6941E0, 025F (r1 PmRef Cpu0Tst 3000 INTL 20050624)
ACPI: SSDT BF69413A, 00A6 (r1 PmRef Cpu1Tst 3000 INTL 20050624)
ACPI: SSDT BF693C32, 0508 (r1 PmRef CpuPm 3000 INTL 20050624)
ACPI: BIOS bug: multiple APIC/MADT found, using 0
ACPI: If "acpi_apic_instance=2" works better, notify linux-acpi@vger.kernel.org
ACPI: Local APIC address 0xfee00000
2178MB HIGHMEM available.
883MB LOWMEM available.
mapped low ram: 0 - 373fe000
low ram: 00000000 - 373fe000
bootmap 00008000 - 0000ee80
(9 early reservations) ==> bootmem [0000000000 - 00373fe000]
#0 [0000000000 - 0000001000] BIOS data page ==> [0000000000 - 0000001000]
#1 [0000001000 - 0000002000] EX TRAMPOLINE ==> [0000001000 - 0000002000]
#2 [0000006000 - 0000007000] TRAMPOLINE ==> [0000006000 - 0000007000]
#3 [0000400000 - 0000c83d2c] TEXT DATA BSS ==> [0000400000 - 0000c83d2c]
#4 [0000c84000 - 0000c89000] INIT_PG_TABLE ==> [0000c84000 - 0000c89000]
#5 [000009f800 - 0000100000] BIOS reserved ==> [000009f800 - 0000100000]
#6 [0000007000 - 0000008000] PGTABLE ==> [0000007000 - 0000008000]
#7 [0000c89000 - 000192e304] NEW RAMDISK ==> [0000c89000 - 000192e304]
#8 [0000008000 - 000000f000] BOOTMAP ==> [0000008000 - 000000f000]
found SMP MP-table at [c00f65d0] 000f65d0
Zone PFN ranges:
DMA 0x00000000 -> 0x00001000
Normal 0x00001000 -> 0x000373fe
HighMem 0x000373fe -> 0x000bf690
Movable zone start PFN for each node
early_node_map[2] active PFN ranges
0: 0x00000000 -> 0x0000009f
0: 0x00000100 -> 0x000bf690
On node 0 totalpages: 783919
free_area_init_node: node 0, pgdat c0aebb00, node_mem_map c192f000
DMA zone: 32 pages used for memmap
DMA zone: 0 pages reserved
DMA zone: 3967 pages, LIFO batch:0
Normal zone: 1736 pages used for memmap
Normal zone: 220470 pages, LIFO batch:31
HighMem zone: 4358 pages used for memmap
HighMem zone: 553356 pages, LIFO batch:31
Using APIC driver default
ACPI: PM-Timer IO Port: 0x1008
ACPI: Local APIC address 0xfee00000
ACPI: LAPIC (acpi_id[0x00] lapic_id[0x00] enabled)
ACPI: LAPIC (acpi_id[0x01] lapic_id[0x01] enabled)
ACPI: LAPIC_NMI (acpi_id[0x00] high edge lint[0x1])
ACPI: LAPIC_NMI (acpi_id[0x01] high edge lint[0x1])
ACPI: IOAPIC (id[0x01] address[0xfec00000] gsi_base[0])
IOAPIC[0]: apic_id 1, version 32, address 0xfec00000, GSI 0-23
ACPI: INT_SRC_OVR (bus 0 bus_irq 0 global_irq 2 dfl dfl)
ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level)
ACPI: IRQ0 used by override.
ACPI: IRQ2 used by override.
ACPI: IRQ9 used by override.
Enabling APIC mode: Flat. Using 1 I/O APICs
Using ACPI (MADT) for SMP configuration information
ACPI: HPET id: 0x8086a201 base: 0xfed00000
SMP: Allowing 2 CPUs, 0 hotplug CPUs
nr_irqs_gsi: 24
PM: Registered nosave memory: 000000000009f000 - 00000000000a0000
PM: Registered nosave memory: 00000000000a0000 - 00000000000dc000
PM: Registered nosave memory: 00000000000dc000 - 0000000000100000
Allocating PCI resources starting at c2000000 (gap: c0000000:20000000)
NR_CPUS:32 nr_cpumask_bits:32 nr_cpu_ids:2 nr_node_ids:1
PERCPU: Allocating 40960 bytes of per cpu data
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 777793
Kernel command line: initrd=initram.igz BOOT_IMAGE=rescuecd
Enabling fast FPU save and restore... done.
Enabling unmasked SIMD FPU exception support... done.
Initializing CPU#0
CPU 0 irqstacks, hard=c0bc0000 soft=c0ba0000
PID hash table entries: 4096 (order: 12, 16384 bytes)
Extended CMOS year: 2000
Fast TSC calibration using PIT
Detected 1995.216 MHz processor.
Console: colour VGA+ 80x25
console [tty0] enabled
Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
allocated 15680320 bytes of page_cgroup
please try cgroup_disable=memory option if you don't want
Memory: 3072084k/3136064k available (4958k kernel code, 62744k reserved, 2368k data, 436k init, 2230856k highmem)
virtual kernel memory layout:
fixmap : 0xffc56000 - 0xfffff000 (3748 kB)
pkmap : 0xff400000 - 0xff800000 (4096 kB)
vmalloc : 0xf7bfe000 - 0xff3fe000 ( 120 MB)
lowmem : 0xc0000000 - 0xf73fe000 ( 883 MB)
.init : 0xc0b30000 - 0xc0b9d000 ( 436 kB)
.data : 0xc08d7a94 - 0xc0b27cc8 (2368 kB)
.text : 0xc0400000 - 0xc08d7a94 (4958 kB)
Checking if this processor honours the WP bit even in supervisor mode...Ok.
SLUB: Genslabs=12, HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
hpet clockevent registered
HPET: 3 timers in total, 0 timers will be used for per-cpu timer
Calibrating delay loop (skipped), value calculated using timer frequency.. 3990.43 BogoMIPS (lpj=1995216)
Security Framework initialized
--------------DMESG End------------------------

------------lspci BEGIN--------------------------
00:00.0 Host bridge: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller (rev 03)
00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS/GME, 943/940GML Express Integrated Graphics Controller (rev 03)
00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 02)
00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 02)
00:1c.1 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 2 (rev 02)
00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #1 (rev 02)
00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #2 (rev 02)
00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #3 (rev 02)
00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI Controller #4 (rev 02)
00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 02)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2)
00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 02)
00:1f.2 IDE interface: Intel Corporation 82801GBM/GHM (ICH7 Family) SATA IDE Controller (rev 02)
00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 02)
03:00.0 Network controller: Broadcom Corporation BCM4328 802.11a/b/g/n (rev 01)
05:01.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL-8139/8139C/8139C+ (rev 10)
05:04.0 CardBus bridge: ENE Technology Inc CB1410 Cardbus Controller (rev 01)
05:06.0 FireWire (IEEE 1394): Ricoh Co Ltd R5C832 IEEE 1394 Controller
05:06.1 SD Host controller: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 19)
05:06.2 System peripheral: Ricoh Co Ltd R5C843 MMC Host Controller (rev 0a)
05:06.3 System peripheral: Ricoh Co Ltd R5C592 Memory Stick Bus Host Adapter (rev 05)
05:06.4 System peripheral: Ricoh Co Ltd xD-Picture Card Controller (rev ff)
------------lspci END----------------------------

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#68 Post by Uncle Joe » Fri Aug 28, 2009 2:56 am

Here's a new CD http://www.cc.gatech.edu/~yzhang67/sysrescue_grub2.iso. I've added some debug messages that you need to press a key to get past. If it crashes before you get to the menu, tell me the last message you see.
Sorry for the delay
Quite the opposite for me. If you're wondering why I have nothing better to do, I'm waiting to start my job with 3M in 2 weeks.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#69 Post by jack_b_uta » Fri Aug 28, 2009 7:51 am

Uncle Joe wrote:Here's a new CD http://www.cc.gatech.edu/~yzhang67/sysrescue_grub2.iso. I've added some debug messages that you need to press a key to get past. If it crashes before you get to the menu, tell me the last message you see.
Sorry for the delay
Quite the opposite for me. If you're wondering why I have nothing better to do, I'm waiting to start my job with 3M in 2 weeks.
:) Lol. I see you posted this at 3:23 am today. Thanks for all your efforts!! I am on my way to work, but will give this a shot and post back.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#70 Post by jack_b_uta » Fri Aug 28, 2009 10:13 am

No luck. The display gets all messed up, and it leaves a snow field on the screen.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#71 Post by Uncle Joe » Fri Aug 28, 2009 7:09 pm

Sorry about that. Doing this system level programming on my own machine was already difficult to debug, so you can imagine the difficulty of doing it remotely.

Anyways, I've uploaded a new CD. It displays even more prompts and debugging info. It corrects 1 major mistake. Previously, I assumed the GMA950 only consumes 8Mb RAM and doesn't occupy any PCI address space. That's wrong. The 8Mb is only for the VGA frame buffer. It also occupies a 256Mb PCI range, so unfortunately, you can only use ~3584Mb RAM, unlike 3840Mb I said earlier :(

In my opinion, this is a bad design because the 256Mb PCI range is a waste - it's just an alias to main RAM instead of a separate RAM http://www.techpowerup.com/articles/ove ... vidcard/43. I guess the contiguous view provided by the 256Mb makes programming easier and allows the address translation to be off loaded to the GMA 950.

It might be possible to get more by reducing the 256Mb aperture (hinted in 945 documentation) or disabling other PCI ranges like the 64Mb PCIX configuration space.

This time, note that there's an option that asks you to press y to copy the 8Mb VGA frame buffer. If the display corrupts, you can try saying y. If things still don't work, send me (yzhang1985@gmail.com) the debug messages up to the point of failure. I'd recommend taking a picture.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#72 Post by jack_b_uta » Mon Aug 31, 2009 10:36 am

No luck. I sent you an email with the screenshots.

Uncle Joe wrote:Sorry about that. Doing this system level programming on my own machine was already difficult to debug, so you can imagine the difficulty of doing it remotely.
No need to explain dude. I know what this involves. Appreciate you taking the time to do it.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#73 Post by Uncle Joe » Mon Aug 31, 2009 9:35 pm

OK. I expected the screen was garbling when I set TOLUD since that switches the memory used for the VGA frame buffer to a new uninitialized location, which explains the garbage you see. I'm thinking maybe the computer is still functional and only the screen needs to be refreshed. Have you tried pressing enter a few more times to see if the screen goes back to normal or any disk activity from loading Windows (pressing enter several times should choose the Windows menu option)?

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#74 Post by jack_b_uta » Mon Aug 31, 2009 10:29 pm

Yup matter of fact I remember hitting enter quite a few times. Something was moving on the screen and I was trying to make out what it was. Could not figure it out though

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#75 Post by Uncle Joe » Wed Sep 02, 2009 5:50 pm

I've asked how to restore the display to text mode on the Mesa 3D (www.mesa3d.org) developer mailing list. Someone said to look at the i915 suspend/resume code, which contains code to save/restore the VGA palette, font memory, etc. I'll take a look at that.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#76 Post by jack_b_uta » Thu Sep 03, 2009 2:36 pm

Thanks!! Let me know if you need any information from me

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#77 Post by Uncle Joe » Thu Sep 03, 2009 3:57 pm

New CD uploaded. Now it sets the display to 80x25 text mode by calling a VGA BIOS function, followed by a call to grub_cls() (clear screen). Rather than mess with all those low level GMA950 configuration registers, I chose to use the higher level VGA BIOS functions.

One problem I forsee is the fonts might still be garbage, but you should see the same character on the entire screen since the screen is cleared. VGA has a memory for storing the pixels of each possible character, a character buffer, and a buffer for controlling the color,blinking,highlight of each character. If the set text mode BIOS function doesn't reload/fix the character bitmap memory, then you might see what I described. There's a BIOS function for reloading the character bitmaps from the VGA ROM, but I'm having problems calling it - crashes.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#78 Post by jack_b_uta » Fri Sep 04, 2009 10:52 am

Ok we might be getting somewhere. I have typed the screen output below. My actions are in ().

---------------------------------------
I get the debug screen followed by
about to set TOLUD,MTRR ..... Press another key (Hit enter at this point)
about to config PCI - Press key (Hit enter at this point)
about to patch ACPI - Press key (Hit enter at this point)
--------------fixups done-------------press key (Hit enter at this point)



At this point I get into the GRUB boot screen. (Selected the first one. )
It says booting windows and just sits there.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#79 Post by Uncle Joe » Fri Sep 04, 2009 3:46 pm

Glad to see it was solved this easily. One possibility why Windows isn't starting is because I hard coded the Windows partitions as (hd0,1) and (hd0,2) in grub.cfg. Maybe Grub numbers the disks differently depending on what you have plugged in. Let's verify that (hd0,1) really is where Windows is.

1. at grub boot menu, press c to enter console mode.
2. "ls" (you should see list of disks and partitions - partitionless drives appear as (hdx); disks numbered from 0, partitions from 1)
3. "ls (hd0,1)/" (lists files on partition 1 of hard disk 1)
4. If the contents look like c:\, then this is the correct device (partition/disk) and goto step 5. If they don't, repeat 3 for the other devices from #2.
5. "set root=(hdx,y)" (replace with Windows device)
6. "chainloader +1" (loads boot loader from sector 0 of Windows device into memory)
7. "boot"

If you see any errors, report them. If it gets stuck in #3, it's probably because grub doesn't recognize the file system - just reboot and skip that device.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#80 Post by jack_b_uta » Sat Sep 05, 2009 11:08 am

Something else might be going on. It found hd0 with 3 slices. 1,2,5. I have 3 partitions on the laptop, First has XP Pro, second has an eval Vista 64 and the third has all my VMs. Its for these VMs that I need the extra memory. I tried to boot using 1, and 2. At 1 it just hangs. At 2 it says bootloader not found. At the first opportunity, I plan to blow the Vista away, since it is getting close to expiration any way. That will probably break my boot record, since Vista was installed after XP. I'll do the fixboot thing and try your fixups at that point. Do you see any problems if I try booting off of a USB flash drive, just to confirm if the fixups worked?

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#81 Post by Uncle Joe » Sat Sep 05, 2009 2:25 pm

At 2 it says bootloader not found
I didn't know that. I thought all Windows partitions have a bootloader in sector 1, but it seems XP and Vista are using the bootloader installed on the XP partition.
Do you see any problems if I try booting off of a USB flash drive
I assume you mean you install windows to a flash drive and boot it from Grub. I've never done that, but according to http://articles.techrepublic.com.com/51 ... 28902.html, it's doable, but doesn't seem easy.

I've never tested the Grub CD booting XP - only Vista. I'll go ahead and try that. When it hangs, is the hard disk or DVD light on?

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#82 Post by jack_b_uta » Sun Sep 06, 2009 7:04 pm

Something is still messed up as far as the graphics is concerned. I created a USB bootable drive using instructions found here

http://www.pendrivelinux.com/usb-kubunt ... l-windows/

Verified that the drive was working by booting to it on startup. I then booted up using your CD (had the USB drive plugged in) and let the fixups run. At GRUB menu I entered the command prompt, and determined that the USB drive was hd1.
Issued the following commands
set root=(hd1,1)
chainloader +1
boot

I was able to get the Kubuntu login prompt to show but when I tried to boot, the graphics were all messed up. It looked like it was booting but stopped a few seconds later and did not go any further.

To answer your earlier question, the cd drive access light is not on.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#83 Post by Uncle Joe » Sun Sep 06, 2009 11:32 pm

OK, I see what you're doing. Good idea - it will allow easier diagnosis. I don't know what's wrong with the display, but a display problem shouldn't cause the system to hang. Let's try to fix the hanging first. I suspect it's due to any one of these problems

1. e820 memory map contains memory region that shouldn't be used
2. PCI device has memory range that overlaps RAM
3. MTRR registers set incorrectly (on my machine, this causes programs to run extremely slowly)

I still don't have a list of the memory regions that your PCI devices originally use, nor the MTRR register settings. Here's how to report them:

1. boot the original systemrescue cd
2. "mkdir /mnt1"
3. "mount /dev/sda1 /mnt1 -t ntfs-3g"
4. "lspci -v > /mnt1/pci_list"
5. "cat /proc/mtrr > /mnt1/mtrrs"
6. "umount /mnt1"
7. reboot to windows and email me c:\pci_list and c:\mtrrs

Once I have these values, I'll inspect my fixup code. If I don't see anything wrong, we'll have to run the fixups, boot to a minimal Linux environment and do some sanity checks.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#84 Post by jack_b_uta » Thu Sep 10, 2009 10:34 pm

sent mail yesterday. Sorry for the delay... my 9 month old just learn't to crawl :)

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#85 Post by Uncle Joe » Fri Sep 11, 2009 12:45 am

Got it. I didn't see anything wrong with what I'm doing based on your data. I did disable another 8MiB region to be safe. We'll have to apply the fix ups and boot into a minimalistic Linux and debug now. Download and burn sysrescue_grub2.iso again and do the following:

1. boot cd; at grub menu, choose rescue
2. "mkdir /mnt1"
3. "ntfs-3g /dev/sda1 /mnt1"
4. "cat /proc/mtrr > /mnt1/mtrr"
5. "free" (check if total mem is ~3600000 KiB)
6. "lspci -v > /mnt1/pci_list"
7. "umount /mnt1"
8. "touchmem" this program allocates as much memory as possible (important that swap is disabled)
and writes to it. In my experience, if an unusable memory region is written, the OS
crashes, hangs, or runs very slowly.
9. "touchmem" do again to double check
10. reboot and send me c:\pci_list and c:\mtrr

If everything's well, try booting into Windows or Kubuntu again.
BTW, what timezone are you in? That will help me match your schedule.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#86 Post by jack_b_uta » Fri Sep 11, 2009 3:54 pm

Email sent. I am on Central time, but my schedule is set by my son these days. I do this stuff during his naps, or at work if I get a few minutes.

The display still gets messed up, but your fixups seem to be allocating about 3.5 GB. Running the free command in rescue cd gives "3548112" free. I have sent you the output of touchmem and free, in addition to the mtrr and the pci_list files.

Thanks

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#87 Post by Uncle Joe » Fri Sep 11, 2009 6:55 pm

The PCI and MTRR configuration look sane. Touchmem runs without problems - another sign things are working. Does Kubuntu or Windows boot now without hanging - regardless of the screen (as long as it's legible)? Also, send me a picture of the screen problem you're describing. I was going to try to reload the VGA character bitmaps as I described earlier, but
that doesn't seem to be your problem.
I am on Central time,
Haha, I thought you're in Cairo until I found BFE has a figurative meaning.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#88 Post by jack_b_uta » Sat Sep 12, 2009 1:19 am

I am on Central time
Haha, I thought you're in Cairo until I found BFE has a figurative meaning.
Lol, the forum admin had a weird requirement for creating an account. For some reason, the location was mandatory. I was trying to hurry and create an account, and the thing kept kicking me back for not providing a location, hence the BFE. Meant no disrespect however, since Egypt is on my one of the places to visit before I kick the bucket.

Kubuntu looks like it will boot but then stops, windows does not even start to boot. I was going to start kubuntu to take a picture of the scrambled screen when I noticed they had a Memory Test utility. I ran that and some of the memory addresses showed as failed. The failed address look like it is in the forbidden territory beyond the 3074 MB range. Let me know if you still need the scrambled screen picture. It pretty much looks like the kubuntu font blew up to 72 points, and it has some ghosting.

Uncle Joe
Posts: 26
Joined: Thu Aug 13, 2009 1:58 am
Location: Vienna, VA

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#89 Post by Uncle Joe » Tue Sep 15, 2009 12:45 pm

Sorry for the wait - I've been on the Amtrak the last 2 days from Washington to St. Paul. Not a good experience

Congratulations - it looks like you've found the problem. I was suspecting using a conflicting memory region, but you're the 1st to find it with memtest86+. I tried to use memtest in the past, but was never able to boot it with grub2.

The region where the memory test failed was formerly used by the USB EHCI controller: d0644000 - d0645000. This is a mystery because
1. The memory access d0644024 shouldn't be forwarded to the USB controller at all because it's < e0000000. I definitely verified that TOLUD is set to e0, meaning only addresses >= e0000000 are forwarded to PCI devices.
2. I remapped the USB controller's memory range somewhere above f0000000 (as you can see from lspci).
3. Why doesn't this happen for other former PCI memory areas (memtest definitely tests memory in ascending order)?

The cheap, kludgy solution is to mark the region as reserved (check back later today). Although I really doubt it, maybe your RAM is faulty. Since memtest only tests 3Gb RAM without my mod, maybe you can try swapping* the SODIMMs and run memtest without my fixups and check for any errors (let it run for the same time you did earlier - e.g. 1/2 hour).

*Swapping will expose the error if the faulty stick is mapped to [2048, 4096) Mb. Personally, I don't think swapping helps because I think in dual channel mode, RAM addresses are interleaved: module1: {0, 16, 32, 48, ....} module2: {8, 24, 40, 56 ...} (each address spans 8 bytes) to allow nearby addresses to be accessed in parallel.

jack_b_uta
Posts: 19
Joined: Wed Aug 19, 2009 1:05 pm
Location: Enter your correct location ASAP

Re: Why 3.0GB, not 3.25 or even 3.5? [Updated with Answer]

#90 Post by jack_b_uta » Tue Sep 15, 2009 2:16 pm

Uncle Joe wrote:Sorry for the wait - I've been on the Amtrak the last 2 days from Washington to St. Paul. Not a good experience
Man I wanted to do a cross country rail trip just for the sake of old times (I like watching "I love Lucy" every so often). Maybe I'll stay away from Amtrak.

I was worried that you might not be able to get to my screenshots, since they dont show up any more. I'll try swapping the memory sticks. I dont think there is anything wrong with either stick, since when I first got it I did the following

Memory Stick 1 Memory Stick 2
-----------------------------------------------------------------------------------
Memory Slot 1) Worked 2GB visible (EMPTY)
Memory Slot 1) (EMPTY) Worked 2GB visible
Memory Slot 2) Worked 2GB visible (EMPTY)
Memory Slot 2) (EMPTY) Worked 2GB visible
-----------------------------------------------------------------------------------

Did that to make sure I did not have a bad stick, or slot. Will wait for the "cheap kludgy solution" since that is better then no solution at all.

Post Reply
  • Similar Topics
    Replies
    Views
    Last post

Return to “ThinkPad T6x Series”

Who is online

Users browsing this forum: No registered users and 3 guests