Subject: Re: very weird booting issues with new machines - 4-core Opteron
To: None <port-amd64@netbsd.org>
From: Chris Kantarjiev <cak+gmane@dimebank.com>
List: port-amd64
Date: 08/29/2006 09:29:38
  > $NetBSD: acpi_pci_link.c,v 1.4 2006/08/20 15:10:59 christos $

Yup, got that.

> But this does not seem to be your problem. Can you remove the sysbeep
> driver from GENERIC, or the one that probes after it and see if you
> can get through?

I'll try. The next device that shows up with INSTALL_ACPI is fdc0. The ... 
confusing thing is that INSTALL_ACPI works so well.

I spent some time with the ULTRA40 config that Kurt Schreiner posted (over in 
the "opteron 246 system" thread that I started). Here's my H8DCE config. I note 
that GENERIC_ACPI doesn't turn off MPBIOS and doesn't turn on ACPI_SCANPCI or 
PCI_INTR_FIXUP - that doesn't seem right...

Of course, this doesn't boot properly, either, but it crashes in a different 
place. dmesg follows.

# $NetBSD: GENERIC_ACPI,v 1.2 2006/07/04 00:30:22 christos Exp $
# $Id: H8DCE,v 1.5 2006/08/29 04:28:53 cak Exp cak $
#
# SuperMicro H8DCE mobo, with 1.1b BIOS
# Based on GENERIC_ACPI machine description file

include "arch/amd64/conf/GENERIC_ACPI"

#ident  "H8DCE-$Revision: 1.5 $"

maxusers        64

# don't use MPBIOS on H8DCE machines!

acpi0   at mainbus0
no options      MPBIOS
#no options     MPBIOS_SCANPCI          # already off in GENERIC_ACPI
options         ACPI_SCANPCI

options         PCI_INTR_FIXUP          # PCI interrupt routing via ACPI
#no options     ACPI_ACTIVATE_DEV
#no options     ACPICA_PEDANTIC

options         DEBUG_MEMLOAD   # for debugging Basemem/extmem settings
                                 # depends on pci mem hole setting in bios

no options      POWERNOW_K8     # doesn't seem to do anything

#
# Because gcc omits the frame pointer for any -O level, the line below
# is needed to make backtraces in DDB work.
#
makeoptions     COPTS="-O2 -fno-omit-frame-pointer"
options         DDB     # in-kernel debugger
options         DDB_HISTORY_SIZE=512    # enable history editing in DDB
makeoptions     DEBUG="-g"      # compile full symbol table

no file-system  OVERLAY
no file-system  PORTAL
no file-system  UMAPFS
no file-system  CODA

no options      QUOTA           # UFS quotas

no options      INET6
no options      ISO,TPIP
no options      NETATALK
no options      PPP_BSDCOMP
no options      PPP_DEFLATE
no options      PPP_FILTER

# ACPI devices
acpiacad*       at acpi?                # ACPI AC Adapter
acpibut*        at acpi?                # ACPI Button
acpiec*         at acpi?                # ACPI Embedded Controller
acpitz*         at acpi?                # ACPI Thermal Zone

# Mainboard devices
com*            at acpi?                # Serial communications interface
lpt*            at acpi?                # Parallel port
attimer*        at acpi?                # AT Timer
pcppi*          at acpi?                # AT-style speaker sound

# LM7[89] and compatible hardware monitors
lm0     at isa? port 0x290              # other common ports: 0x280, 0x310

# AMD 768 and 8111 power/ACPI controllers
amdpm*  at pci? dev ? function ?        # RNG and SMBus 1.0 interface
#iic*   at amdpm?                       # sensors below are on this bus
#adt7463c* at iic? addr 0x2C            # Unknown other motherboard(s)
#adt7463c* at iic? addr 0x2D            # Tyan S2881
#adt7463c* at iic? addr 0x2E            # Tyan S2882-D

no pseudo-device ppp
no pseudo-device pppoe
no pseudo-device stf

no pseudo-device vcoda

----
I turned on a number of acpi devices; that might be a mistake - especially since 
past kernels have found attimer (the likely next device) at isa. I'll undo that.
----

 > boot netbsd-H8DCE
booting hd0a:netbsd-H8DCE
6841448+860216+336016 [465888+302575]=0x967058
BIOS MEMORY MAP (10 ENTRIES):
     addr 0x0  size 0x9fc00  type 0x1
     addr 0x9fc00  size 0x400  type 0x2
     addr 0xe6000  size 0x1a000  type 0x2
     addr 0x100000  size 0xbaed0000  type 0x1
     addr 0xbafd0000  size 0xe000  type 0x3
     addr 0xbafde000  size 0x22000  type 0x4
     addr 0xfec00000  size 0x1000  type 0x2
     addr 0xfee00000  size 0x1000  type 0x2
     addr 0xff780000  size 0x880000  type 0x2
     addr 0x100000000  size 0x100000000  type 0x1
loading 0x7000-0x9f000 (0x7-0x9f)
loading 0xa7a000-0x1000000 (0xa7a-0x1000)
loading 0x1000000-0xbafd0000 (0x1000-0xbafd0)
loading 0x100000000-0x200000000 (0x100000-0x200000)
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
     The NetBSD Foundation, Inc.  All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
     The Regents of the University of California.  All rights reserved.

NetBSD 4.99.1 (H8DCE) #2: Mon Aug 28 21:42:08 PDT 2006
         cak@vern.landsonar.com:/usr/src/CURRENT/src/sys/arch/amd64/compile/H8DCE
total memory = 7087 MB
avail memory = 6825 MB
timecounter: Timecounters tick every 10.000 msec
timecounter: Timecounter "i8254" frequency 1193182 Hz quality 100
timecounter: selected timecounter "i8254" frequency 1193182 Hz quality 100
mainbus0 (root)
cpu0 at mainbus0: apid 0 (boot processor)
cpu0: Dual Core AMD Opteron(tm) Processor 270, 2000.10 MHz
cpu0: features: f7dbfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR>
cpu0: features: f7dbfbff<PGE,MCA,CMOV,PAT,PSE36,MPC,NOX,MMXX,MMX>
cpu0: features: f7dbfbff<FXSR,SSE,SSE2,HTT,LONG,3DNOW2,3DNOW>
cpu0: calibrating local timer
cpu0: apic clock running at 200 MHz
cpu0: 16 page colors
cpu1 at mainbus0: apid 1 (application processor)
cpu1: not started
cpu2 at mainbus0: apid 2 (application processor)
cpu2: not started
cpu3 at mainbus0: apid 3 (application processor)
cpu3: not started
ioapic0 at mainbus0 apid 4 (I/O APIC)
ioapic0: pa 0xfec00000, version 11, 24 pins
ioapic1 at mainbus0 apid 5 (I/O APIC)
ioapic1: pa 0xdfefc000, version 11, 24 pins
acpi0 at mainbus0: Advanced Configuration and Power Interface
acpi0: fixed-feature power button present
timecounter: Timecounter "ACPI-Fast" frequency 3579545 Hz quality 1000
timecounter: selected timecounter "ACPI-Fast" frequency 3579545 Hz quality 1000
ACPI-Fast 24-bit timer
ACPI Object Type 'Processor' (0x0c) at acpi0 not configured
ACPI Object Type 'Processor' (0x0c) at acpi0 not configured
ACPI Object Type 'Processor' (0x0c) at acpi0 not configured
ACPI Object Type 'Processor' (0x0c) at acpi0 not configured
PNP0A03 [PCI/PCI-X Host Bridge] at acpi0 not configured
PNP0000 [AT Interrupt Controller] at acpi0 not configured
PNP0200 [AT DMA Controller] at acpi0 not configured
attimer1 at acpi0 (PNP0100): AT Timer
attimer1: io 0x40-0x43 irq 0
PNP0B00 [AT Real-Time Clock] at acpi0 not configured
pcppi1 at acpi0 (PNP0800)
pcppi1: io 0x61
midi0 at pcppi1: PC speaker (CPU-intensive output)
sysbeep0 at pcppi1
PNP0C04 [Math Coprocessor] at acpi0 not configured
com2 at acpi0 (PNP0501-1)
com2: io 0x3f8-0x3ff irq 4
com: ns16550a, working fifo
com2: console
com3 at acpi0 (PNP0501-2)
com3: io 0x2f8-0x2ff irq 3
com3: ns16550a, working fifo
PNP0700 [PC standard floppy disk controller] at acpi0 not configured
lpt2 at acpi0 (PNP0400)
lpt2: io 0x378-0x37f irq 7
PNP0C02 [Plug and Play motherboard register resources] at acpi0 not configured
PNP0C02 [Plug and Play motherboard register resources] at acpi0 not configured
PNP0303 [IBM Enhanced (101/102-key, PS/2 mouse support)] at acpi0 not configured
PNP0C02 [Plug and Play motherboard register resources] at acpi0 not configured
PNP0C02 [Plug and Play motherboard register resources] at acpi0 not configured
PNP0C01 [System Board] at acpi0 not configured
PNP0A03 [PCI/PCI-X Host Bridge] at acpi0 not configured
acpibut0 at acpi0 (PNP0C0C-170): ACPI Power Button
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
PNP0C0F [PCI interrupt link device] at acpi0 not configured
pcppi1: attached to attimer1
pci0 at mainbus0 bus 0: configuration mode 1
pci0: i/o space, memory space enabled, rd/line, rd/mult, wr/inv ok
NVIDIA nForce4 Memory Controller (miscellaneous memory, revision 0xa3) at pci0 
dev 0 function 0 not configured
pcib0 at pci0 dev 1 function 0
pcib0: NVIDIA nForce4 PCI-ISA bridge (rev. 0xa3)
NVIDIA nForce4 SMBus (SMBus serial bus, revision 0xa2) at pci0 dev 1 function 1 
not configured
ohci0 at pci0 dev 2 function 0: NVIDIA nForce4 USB Host Controller (rev. 0xa2)
ohci0: interrupting at ioapic0 pin 20 (irq 9)
ohci0: OHCI version 1.0, legacy support
usb0 at ohci0: USB revision 1.0
uhub0 at usb0
uhub0: NVIDIA OHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 10 ports with 10 removable, self powered
ehci0 at pci0 dev 2 function 1: NVIDIA nForce4 USB2 Host Controller (rev. 0xa3)
ehci0: interrupting at ioapic0 pin 21 (irq 9)
ehci0: BIOS has given up ownership
ehci0: EHCI version 1.0
ehci0: companion controller, 4 ports each: ohci0
usb1 at ehci0: USB revision 2.0
uhub1 at usb1
uhub1: NVIDIA EHCI root hub, class 9/0, rev 2.00/1.00, addr 1
uhub1: 10 ports with 10 removable, self powered
auich0 at pci0 dev 4 function 0: nForce4 AC-97 Audio
auich0: interrupting at ioapic0 pin 22 (irq 9)
auich0: ac97: Avance Logic ALC650 codec; 20 bit DAC, 18 bit ADC, Realtek 3D
auich0: ac97: ext id 5c7<AC97_22,LDAC,SDAC,CDAC,SPDIF,DRA,VRA>
viaide0 at pci0 dev 6 function 0
viaide0: NVIDIA nForce4 IDE Controller (rev. 0xf2)
viaide0: bus-master DMA support present
viaide0: primary channel configured to compatibility mode
viaide0: primary channel interrupting at ioapic0 pin 14 (irq 14)
atabus0 at viaide0 channel 0
viaide0: secondary channel configured to compatibility mode
viaide0: secondary channel interrupting at ioapic0 pin 15 (irq 15)
atabus1 at viaide0 channel 1
viaide1 at pci0 dev 7 function 0
viaide1: NVIDIA nForce4 Serial ATA Controller (rev. 0xf3)
viaide1: bus-master DMA support present
viaide1: primary channel wired to native-PCI mode
viaide1: using ioapic0 pin 20 (irq 9) for native-PCI interrupt
atabus2 at viaide1 channel 0
viaide1: secondary channel wired to native-PCI mode
atabus3 at viaide1 channel 1
viaide2 at pci0 dev 8 function 0
viaide2: NVIDIA nForce4 Serial ATA Controller (rev. 0xf3)
viaide2: bus-master DMA support present
viaide2: primary channel wired to native-PCI mode
viaide2: using ioapic0 pin 21 (irq 5) for native-PCI interrupt
atabus4 at viaide2 channel 0
viaide2: secondary channel wired to native-PCI mode
atabus5 at viaide2 channel 1
ppb0 at pci0 dev 9 function 0: NVIDIA nForce4 PCI Host Bridge (rev. 0xa2)
pci1 at ppb0 bus 3
pci1: i/o space, memory space enabled
nfe0 at pci0 dev 10 function 0: ioapic0 pin 22 (irq 11), address 00:30:48:57:7f:b8
makphy0 at nfe0 phy 1: Marvell 88E1111 Gigabit PHY, rev. 2
makphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 
1000baseT-FDX, auto
ppb1 at pci0 dev 13 function 0: NVIDIA nForce4 PCIe Host Bridge (rev. 0xa3)
pci2 at ppb1 bus 2
pci2: memory space enabled, rd/line, wr/inv ok
ppb2 at pci0 dev 14 function 0: NVIDIA nForce4 PCIe Host Bridge (rev. 0xa3)
pci3 at ppb2 bus 1
pci3: i/o space, memory space enabled, rd/line, wr/inv ok
vga0 at pci3 dev 0 function 0: NVIDIA GeForce 6200TC (rev. 0xa1)
vga0: WARNING: ignoring 64-bit BAR @ 0x14
vga0: WARNING: ignoring 64-bit BAR @ 0x1c
wsdisplay0 at vga0 kbdmux 1
wsmux1: connecting to wsdisplay0
pchb0 at pci0 dev 24 function 0
pchb0: Advanced Micro Devices AMD64 HyperTransport configuration (rev. 0x00)
pchb1 at pci0 dev 24 function 1
pchb1: Advanced Micro Devices AMD64 Address Map configuration (rev. 0x00)
pchb2 at pci0 dev 24 function 2
pchb2: Advanced Micro Devices AMD64 DRAM configuration (rev. 0x00)
pchb3 at pci0 dev 24 function 3
pchb3: Advanced Micro Devices AMD64 Miscellaneous configuration (rev. 0x00)
pchb4 at pci0 dev 25 function 0
pchb4: Advanced Micro Devices AMD64 HyperTransport configuration (rev. 0x00)
pchb5 at pci0 dev 25 function 1
pchb5: Advanced Micro Devices AMD64 Address Map configuration (rev. 0x00)
pchb6 at pci0 dev 25 function 2
pchb6: Advanced Micro Devices AMD64 DRAM configuration (rev. 0x00)
pchb7 at pci0 dev 25 function 3
pchb7: Advanced Micro Devices AMD64 Miscellaneous configuration (rev. 0x00)
isa0 at pcib0
pckbc0 at isa0 port 0x60-0x64
pckbd0 at pckbc0 (kbd slot)
pckbc0: using irq 1 for kbd slot
wskbd0 at pckbd0 mux 1
wskbd0: connecting to wsdisplay0

----

Karl points out that I've lost about 1G of memory, and thinks that has to do 
with the "pci mem hole". This is voodoo for me - suggestions welcome. But I'd 
really love to get the machine running, first!