|
Description
|
Solaris Nevada b92 fails to boot 64-bit on the Intel D945GCLF motherboard.
cpuid instruction returns 64-bit supported. Bit 29 of %edx is set in leaf 0x80000001.
Input %eax = 0x80000001
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000001
Output edx = 0x20100000
GRUB verbose output shows amd64 disabled due to lack of PSE support:
kernel$ /platform/i86pc/kernel/$ISADIR/unix -B $ZFS-BOOTFS -k
loading '/platform/i86pc/kernel/$ISADIR/unix -B $ZFS-BOOTFS -k' ...
cpu: 'GenuineIntel' family 6 model 12 step 2
amd64: CPU does NOT support PSE
amd64: CPU does not support amd64 executables.
[Multiboot-elf, <0xc00000:0xfa54:0x0>, <0x400000:0xb9e4c:0x0>, <0x800000:0x7
8bc:0x39c98>, shtab=0xc10370, entry=0xc00000]
'/platform/i86pc/kernel//unix -B zfs-bootfs=rpool/27 -k' is loaded
module$ /platform/i86pc/$ISADIR/boot_archive
loading '/platform/i86pc/$ISADIR/boot_archive' ...
grub/grub-0.95/stage2/builtins.c around line 3024:
if (!BITX(stdfeatures, 17, 17)) {
grub_printf("amd64: CPU does NOT support PSE\n");
isamd64--;
}
EDIT: PSE bit 17 is NOT set. The original incorrect description follows:
PSE bit 17 of edx = 0xbfe9fbff appears to be set (cpuid with eax=1) in the
CPUID output on atom booted Solaris supplied by Tim Bauer.
Any idea why the bit is not set in GRUB?
Input %eax = 0x00000000
Output eax = 0x0000000a
Output ebx = 0x756e6547
Output ecx = 0x6c65746e
Output edx = 0x49656e69
Input %eax = 0x00000001
Output eax = 0x000106c2
Output ebx = 0x01020800
Output ecx = 0x0040e31d
Output edx = 0xbfe9fbff
Input %eax = 0x00000002
Output eax = 0x4fba5901
Output ebx = 0x0e3080c0
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x00000003
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x00000004
Output eax = 0x00004121
Output ebx = 0x0140003f
Output ecx = 0x0000003f
Output edx = 0x00000001
Input %eax = 0x00000005
Output eax = 0x00000040
Output ebx = 0x00000040
Output ecx = 0x00000003
Output edx = 0x00000010
Input %eax = 0x00000006
Output eax = 0x00000001
Output ebx = 0x00000002
Output ecx = 0x00000001
Output edx = 0x00000000
Input %eax = 0x00000007
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x00000008
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x00000009
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x0000000a
Output eax = 0x07280203
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00002501
Input %eax = 0x80000000
Output eax = 0x80000008
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x80000001
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000001
Output edx = 0x20100000
Input %eax = 0x80000002
Output eax = 0x20202020
Output ebx = 0x20202020
Output ecx = 0x746e4920
Output edx = 0x52286c65
Input %eax = 0x80000003
Output eax = 0x74412029
Output ebx = 0x54286d6f
Output ecx = 0x4320294d
Output edx = 0x20205550
Input %eax = 0x80000004
Output eax = 0x20303332
Output ebx = 0x20402020
Output ecx = 0x30362e31
Output edx = 0x007a4847
Input %eax = 0x80000005
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x80000006
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x02008040
Output edx = 0x00000000
Input %eax = 0x80000007
Output eax = 0x00000000
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Input %eax = 0x80000008
Output eax = 0x00003020
Output ebx = 0x00000000
Output ecx = 0x00000000
Output edx = 0x00000000
Solaris also reports our atoms as family 6 model 28 step 2 clock 1600MHz.
Our atom systems are most likely identical to James' atom system.
GRUB incorrectly reports our cpus as family 6 model 12 step 2.
These are model 28 cpus. Perhaps GRUB is incorrectly detecting the
model + extended model?
Yes, the calculation of model is incorrect in grub.
grub/grub-0.95/stage2/builtins.c
2962 if ((model = BITX(vcr->r_eax, 7, 4)) == 0xf)
2963 model += BITX(vcr->r_eax, 19, 16) << 4;
2964 step = BITX(vcr->r_eax, 3, 0);
This method of calculating model is applicable only for AMD processors. The AMD CPUID Specification says...
Model is an 8-bit value and is defined as: Model[7:0] = {ExtendedModel[3:0],BaseModel[3:0]}. For example, if ExtendedModel[3:0] = 0Eh and BaseModel[3:0] = 08h, then Model[7:0] = E8h. If BaseFamily[3:0] is less than 0Fh then ExtendedModel[3:0] is reserved and Model is equal to BaseModel[3:0].
But for Intel processors, the SDM volume 2a says...
IF (Family_ID = 06H or Family_ID = 0FH)
THEN Displayed_Model = (Extended_Model_ID << 4) + Model_ID;
(* Right justify and zero-extend 4-bit field; display Model_ID as HEX field.*)
ELSE Displayed_Model = Model_ID;
FI;
The PSE bit check is not needed according to Joe Bonasera.
PSE bit has no relevance to long (ie. 64 bit) mode.
The current AMD manuals are much clearer about this than the
Intel docs. Back when Tim (or Todd) put the checks into vmx (which
got folded into multiboot, the AMD manuals weren't clear about
PSE and long mode, so it was included in the long mode checks.
The grub code, I assume, was just copied from multiboot.
I closed this as a duplicate of 6471548, since that's the earlier report
of the same code problem that has gone unfixed for a long time.
|