On 9/17/06, Stuart Henderson <[EMAIL PROTECTED]> wrote:
Reboot may be easier. Looking at /usr/src/sys/arch/i386/i386/machdep.c,
there's a Geode-specific reset operation used, but there's a chance it
is an SC1100-only function that won't work on a plain Geode system.
If that's the case, and seeing as you appear to have a standard PC
keyboard controller (which is used to reset normal systems but is
absent from some Geode boards, notably WRAP, hence the alternative
function), you can try editing this file and commenting-out
"cpuresetfn = natsem6x86_cpureset;" from natsem6x86_cpu_setup()
and rebuilding the kernel; this way it will use the normal PC methods
instead.

If this does the trick, the outl/outb are probably hanging your
system, in which case the natsem6x86_cpu_setup needs to do additional
CPU detection and only use the alternative reset function on SC1100
systems.

As pointed out earlier, this does the trick. Now, I try to contribute
a proper patch which discriminates between Geode CPUs in Nokia and
WRAP & Soekris boards in order to call an appropriate reset function.

Using debug kernels customized with 'option CPUDEBUG' does not show an
obvious difference within the '/src/sys/arch/i386/i386/machdep.c'
module between a Nokia (booting from hard disk) and a WRAP (network
booting using PXEboot), see dmesg below.

Would it be acceptable to somehow use the 'bios0' string within
machdep.c to setup 'cpuresetfn' at boot time, or within 'cpu_reset()'
later "at run time" in order to discriminate Nokia motherboards from
WRAPs and Soekris' ?

Or, do I overlook some parameter that would allow to discriminate
those motherboards within machdep.c?

Or finally, more radical, should the setting of the global variable
'cpuresetfn' be postponed to where the motherboard / BIOS is detected,
and not prematurely in the CPU detection stage in machdep.c?

Thanks in advance for your guidance,
Rolf


dmesg from Nokia IP120, 'GENERIC' kernel built with 'option CPUDEBUG':

OpenBSD 4.0-current (GENERIC) #14: Fri Oct  6 13:34:12 CEST 2006
   [EMAIL PROTECTED]:/usr/src/sys/arch/i386/compile/GENERIC
cpu0: family 5 model 4 step 0
cpu0: cpuid level 2 cache eax 7001 ebx 0 ecx 0 edx 80
cpu0: Geode(TM) Integrated Processor by National Semi ("Geode by NSC"
586-class) 267 MHz
cpu0: FPU,TSC,MSR,CX8,CMOV,MMX
cpu0: TSC disabled
real mem  = 133787648 (130652K)
avail mem = 114634752 (111948K)
using 1658 buffers containing 6791168 bytes (6632K) of memory
mainbus0 (root)
bios0 at mainbus0: AT/286+(05) BIOS, date 07/17/00, BIOS32 rev. 0 @
0xeb0a0, SMBIOS rev. 2.3
@ 0xe
d2a8 (32 entries)
bios0: Jabil/Nokia IP110
pcibios0 at bios0: rev 2.1 @ 0xe8000/0x669
pcibios0: PCI IRQ Routing Table rev 1.0 @ 0xf4fb0/80 (3 entries)
pcibios0: no compatible PCI ICU found: ICU vendor 0x1078 product 0x0100
pcibios0: PCI bus #0 is the last bus
bios0: ROM list: 0xe8000/0x4000! 0xec000/0x4000!
cpu0 at mainbus0
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 "Cyrix GXm PCI" rev 0x00
fxp0 at pci0 dev 14 function 0 "Intel 82559ER" rev 0x09, i82559S: irq
11, address 00:a0:8e:21:88:98
...


dmesg from WRAP1C, PXE-booting over network 'RAMDISK_CD' kernel built
with 'option CPUDEBUG':


PC Engines WRAP.1C/1D/1E v1.11
640 KB Base Memory
130048 KB Extended Memory

01F0 - no drive found !
ROM segment 0xe000 length 0x8000 reloc 0x00000000
Etherboot 5.4.1 (GPL) http://etherboot.org
Drivers: NATSEMI   Images: NBI ELF PXE   Exports: PXE
Protocols: DHCP TFTP NFS TFTM HTTP DNS
Relocating _text from: [00088f80,0009fd60) to [07ee9220,07f00000)
Boot from (N)etwork or (Q)uit?

Probing pci nic...
[dp83815]
natsemi_probe: MAC addr 00:0D:B9:01:A0:A0 at ioaddr 0X1000
natsemi_probe: Vendor:0X100B Device:0X0020
dp83815: Transceiver default autoneg. enabled, advertise 100 full duplex.
dp83815: Transceiver status 7869 advertising 05E1
dp83815: Setting half-duplex based on negotiated link capability.
Searching for server (DHCP)...\
Me: 10.0.0.21, DHCP: 10.0.0.3, TFTP: 10.0.0.3, Gateway 10.0.0.1,
Nameserver 10.0.0.1
Loading 10.0.0.3:pxeboot XXXX(0049K done
probing: pc0 com0 pci pxe![2.1] mem[640K 125M a20=on]
disk:
net: mac 00:0d:b9:01:a0:a0, ip 10.0.0.21, server 10.0.0.3
OpenBSD/i386 PXEBOOT 1.07
switching console to com0
OpenBSD/i386 PXEBOOT 1.07
com0: changing speed to 38400 baud in 5 seconds, change your terminal to match!

com0: 38400 baud
booting tftp:/bsdCPUDEBUG.rd: 5034740+740164 [52+164384+150221]=0x5cecd0
dp83815: Setting half-duplex based on negotiated link capability.
entry point at 0x200120

Copyright (c) 1982, 1986, 1989, 1991, 1993
       The Regents of the University of California.  All rights reserved.
Copyright (c) 1995-2006 OpenBSD. All rights reserved.  http://www.OpenBSD.org

OpenBSD 4.0-current (RAMDISK_CD) #0: Fri Oct  6 13:54:24 CEST 2006
   [EMAIL PROTECTED]:/usr/src/sys/arch/i386/compile/RAMDISK_CD
cpu0: family 5 model 4 step 0
cpu0: cpuid level 2 cache eax 7001 ebx 0 ecx 0 edx 80
cpu0: Geode(TM) Integrated Processor by National Semi ("Geode by NSC"
586-class) 267 MHz
cpu0: FPU,TSC,MSR,CX8,CMOV,MMX
cpu0: TSC disabled
real mem  = 132648960 (129540K)
avail mem = 114737152 (112048K)
using 1644 buffers containing 6733824 bytes (6576K) of memory
mainbus0 (root)
bios0 at mainbus0: AT/286+(77) BIOS, date 11/08/05, BIOS32 rev. 0 @ 0xfc622
pcibios0 at bios0: rev 2.1 @ 0xf0000/0x10000
pcibios0: pcibios_get_intr_routing - function not supported
pcibios0: PCI IRQ Routing information unavailable.
pcibios0: PCI bus #0 is the last bus
bios0: ROM list: 0xe0000/0x8000
cpu0 at mainbus0
pci0 at mainbus0 bus 0: configuration mode 1 (bios)
pchb0 at pci0 dev 0 function 0 "Cyrix GXm PCI" rev 0x00
sis0 at pci0 dev 14 function 0 "NS DP83815 10/100" rev 0x00, DP83816A:
irq 10, address
00:0d:b9:00
...

Reply via email to