Bug 17690

Summary: SCSI hangs on SMP kernel (4.0-RELEASE)
Product: Base System Reporter: M.Indlekofer <M.Indlekofer>
Component: i386Assignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 4.0-RELEASE   
Hardware: Any   
OS: Any   

Description M.Indlekofer 2000-03-30 17:00:01 UTC
SMP kernel (4.0-RELEASE) on dual PentiumII system
hangs in SCSI probe phase at boot time.
Infinite loop of SCSI bus resets (probeX:ahc0:0:X:0 SCB ... timeout...).
Non-SMP kernel (4.0-RELEASE) works.
SMP kernel (3.1-RELEASE) worked without problems.
Hardware:
Dual PentiumII 450MHz (ASUS P2B-DS mainboard)
Adaptec aic7890/91 Ultra2 SCSI adapter on board

How-To-Repeat: e.g. /sys/i386/conf/GENERIC SMP activated kernel:
remove cpu I386_CPU and cpu I486_CPU,
enable options SMP and options APIC_IO
Comment 1 ken 2000-03-31 00:43:32 UTC
On Thu, Mar 30, 2000 at 07:59:37 -0800, M.Indlekofer@fz-juelich.de wrote:
> FreeBSD deanna.isi.kfa-juelich.de 4.0-RELEASE FreeBSD 4.0-RELEASE #3: Thu Mar 30 15:50:03 CEST 2000     root@deanna.isi.kfa-juelich.de:/usr/src/sys/compile/MYKERNEL.3  i386
> >Description:
> SMP kernel (4.0-RELEASE) on dual PentiumII system
> hangs in SCSI probe phase at boot time.
> Infinite loop of SCSI bus resets (probeX:ahc0:0:X:0 SCB ... timeout...).
> Non-SMP kernel (4.0-RELEASE) works.
> SMP kernel (3.1-RELEASE) worked without problems.
> Hardware:
> Dual PentiumII 450MHz (ASUS P2B-DS mainboard)
> Adaptec aic7890/91 Ultra2 SCSI adapter on board
> 
> >How-To-Repeat:
> e.g. /sys/i386/conf/GENERIC SMP activated kernel:
> remove cpu I386_CPU and cpu I486_CPU,
> enable options SMP and options APIC_IO

I doubt I can really help you solve the problem, but I would suggest that
you include the dmesg from a 'boot -v' from your uniprocessor 4.0
configuration, as well as the output of 'mptable -dmesg -verbose'.

Those diagnostics may help someone find your problem.

Make sure you CC to the mail to freebsd-gnats-submit@FreeBSD.ORG so that it
will go into the GNATS database.

Thanks,

Ken
-- 
Kenneth Merry
ken@kdm.org
Comment 2 M.Indlekofer 2000-03-31 09:35:32 UTC
Booting SMP (4.0) kernel (written down from screen):
...
APIC_IO: Testing 8254 interrupt delivery
APIC_IO: routing 8254 via IOAPIC #0 intpin 2
Waiting 15 seconds for SCSI devices to settle
SMP: AP CPU #1 Launched!
    ...approx 20 seconds...
(probe0:ahc0:0:0:0): SCB 0xe - timed out in Message-in phase, SEQADDR == 0x167
(probe0:ahc0:0:0:0): BDR message in message buffer
(probe0:ahc0:0:0:0): SCB 0xe - timed out in Message-in phase, SEQADDR == 0x167
(probe0:ahc0:0:0:0): no longer in timeout, status = 34b
ahc0: Issued Channel A Bus Reset, 15 SCBs aborted
Timeout SCB handled by another timout
    ...infinite loop: probeX (X=0, 3, 1 ,6 ,9 ,...) part above repeated approx. every 20 seconds...


'mptable -dmesg -verbose' on uniprocessor kernel (4.0) provides:

===============================================================================

MPTable, version 2.0.15

 looking for EBDA pointer @ 0x040e, found, searching EBDA @ 0x0009fc00
 searching CMOS 'top of mem' @ 0x0009f800 (638K)
 searching default 'top of mem' @ 0x0009fc00 (639K)
 searching BIOS @ 0x000f0000

 MP FPS found in BIOS @ physical addr: 0x000f6dd0

-------------------------------------------------------------------------------

MP Floating Pointer Structure:

  location:                     BIOS
  physical address:             0x000f6dd0
  signature:                    '_MP_'
  length:                       16 bytes
  version:                      1.1
  checksum:                     0x65
  mode:                         Virtual Wire

-------------------------------------------------------------------------------

MP Config Table Header:

  physical address:             0x000f69c6
  signature:                    'PCMP'
  base table length:            260
  version:                      1.1
  checksum:                     0x36
  OEM ID:                       'OEM00000'
  Product ID:                   'PROD00000000'
  OEM table pointer:            0x00000000
  OEM table size:               0
  entry count:                  24
  local APIC address:           0xfee00000
  extended table length:        0
  extended table checksum:      0

-------------------------------------------------------------------------------

MP Config Base Table Entries:
--
Processors:     APIC ID Version State           Family  Model   Step    Flags
                 1       0x11    BSP, usable     6       5       2       0x183fb
ff
                 0       0x11    AP, usable      6       5       2       0x183fb
ff
--
Bus:            Bus ID  Type
                 0       PCI
                 1       PCI
                 2       ISA
--
I/O APICs:      APIC ID Version State           Address
                 2       0x11    usable          0xfec00000
--
I/O Ints:       Type    Polarity    Trigger     Bus ID   IRQ    APIC ID PIN#
                ExtINT   conforms    conforms        2     0          2    0
                INT      conforms    conforms        2     1          2    1
                INT      conforms    conforms        2     0          2    2
                INT      conforms    conforms        2     3          2    3
                INT      conforms    conforms        2     4          2    4
                INT      conforms    conforms        2     5          2    5
                INT      conforms    conforms        2     6          2    6
                INT      conforms    conforms        2     7          2    7
                INT      conforms    conforms        2     8          2    8
                INT      conforms    conforms        2    10          2   10
                INT      conforms    conforms        2    12          2   12
                INT      conforms    conforms        2    14          2   14
                INT      conforms    conforms        2    15          2   15
                INT     active-lo       level        2    11          2   16
                INT     active-lo       level        2     9          2   17
                INT     active-lo       level        2     9          2   19
--
Local Ints:     Type    Polarity    Trigger     Bus ID   IRQ    APIC ID PIN#
                ExtINT  active-hi        edge        2     0        255    0
                NMI     active-hi        edge        2     0        255    1

-------------------------------------------------------------------------------

# SMP kernel config file options:


# Required:
options         SMP                     # Symmetric MultiProcessor Kernel
options         APIC_IO                 # Symmetric (APIC) I/O

# Optional (built-in defaults will work in most cases):
#options                NCPU=2                  # number of CPUs
#options                NBUS=3                  # number of busses
#options                NAPIC=1                 # number of IO APICs
#options                NINTR=24                # number of INTs

-------------------------------------------------------------------------------

dmesg output:

Copyright (c) 1992-2000 The FreeBSD Project.
Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California. All rights reserved.
FreeBSD 4.0-RELEASE #3: Thu Mar 30 15:50:03 CEST 2000
    root@deanna.isi.kfa-juelich.de:/usr/src/sys/compile/MYKERNEL.3
Timecounter "i8254"  frequency 1193182 Hz
CPU: Pentium II/Pentium II Xeon/Celeron (451.02-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0x652  Stepping = 2
  Features=0x183fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CM
OV,PAT,PSE36,MMX,FXSR>
real memory  = 268423168 (262132K bytes)
config> di sn0
config> di lnc0
:config> di le0
config> di ie0
config> di fe0
config> di ed0
config> di cs0
config> di bt0
config> di ata1
config> di ata0
config> di aic0
config> di aha0
config> di adv0
config> en npx0
config> po npx0 0xf0
config> ir npx0 13
config> f npx0 0
config> q
avail memory = 256315392 (250308K bytes)
Preloaded elf kernel "kernel" at 0xc03f3000.
Preloaded userconfig_script "/boot/kernel.conf" at 0xc03f309c.
Pentium Pro MTRR support enabled
md0: Malloc disk
npx0: <math processor> on motherboard
npx0: INT 16 interface
pcib0: <Intel 82443BX (440 BX) host to PCI bridge> on motherboard
pci0: <PCI bus> on pcib0
pcib1: <Intel 82443BX (440 BX) PCI-PCI (AGP) bridge> at device 1.0 on pci0
pci1: <PCI bus> on pcib1
pci1: <VGA-compatible display device> at 0.0 irq 11
isab0: <Intel 82371AB PCI to ISA bridge> at device 4.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel PIIX4 ATA33 controller> port 0xd800-0xd80f at device 4.1 on pci0
pci0: <Intel 82371AB/EB (PIIX4) USB controller> at 4.2 irq 9
chip1: <Intel 82371AB Power management controller> port 0xe800-0xe80f at device
4.3 on pci0
ahc0: <Adaptec aic7890/91 Ultra2 SCSI adapter> port 0xd000-0xd0ff mem 0xe1800000
-0xe1800fff irq 9 at device 6.0 on pci0
ahc0: aic7890/91 Wide Channel A, SCSI Id=7, 16/255 SCBs
xl0: <3Com 3c900B-COMBO Etherlink XL> port 0xb800-0xb87f mem 0xe1000000-0xe10000
7f irq 9 at device 11.0 on pci0
xl0: Ethernet address: 00:50:04:2e:e3:8d
xl0: selecting 10baseT transceiver, half duplex
xl0: supplying EUI64: 00:50:04:ff:fe:2e:e3:8d
fdc0: <NEC 72065B or clone> at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0
fdc0: FIFO enabled, 8 bytes threshold
fd0: <1440-KB 3.5" drive> on fdc0 drive 0
atkbdc0: <keyboard controller (i8042)> at port 0x60-0x6f on isa0
atkbd0: <AT Keyboard> irq 1 on atkbdc0
psm0: <PS/2 Mouse> irq 12 on atkbdc0
psm0: model Generic PS/2 mouse, device ID 0
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
sc0: <System console> on isa0
sc0: VGA <16 virtual consoles, flags=0x200>
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 16550A
sio1 at port 0x2f8-0x2ff irq 3 on isa0
sio1: type 16550A
ppc0: <Parallel port> at port 0x378-0x37f irq 7 on isa0
ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode
ppc0: FIFO with 16/16/9 bytes threshold
ppi0: <Parallel I/O> on ppbus0
lpt0: <Printer> on ppbus0
lpt0: Interrupt-driven port
plip0: <PLIP network interface> on ppbus0
sbc0: <Creative SB16/SB32> at port 0x220-0x22f,0x330-0x331,0x388-0x38b irq 5 drq
 1,5 on isa0
sbc0: setting card to irq 5, drq 1, 5
pcm0: <SB DSP 4.16> on sbc0
unknown0: <Game> at port 0x200-0x207 on isa0
unknown1: <WaveTable> at port 0x620-0x623 on isa0
unknown2: <Generic ESDI/IDE/ATA controller> at port 0x168-0x16f,0x36e-0x36f irq
10 on isa0
Waiting 15 seconds for SCSI devices to settle
Mounting root from ufs:/dev/da0s1a
da0 at ahc0 bus 0 target 0 lun 0
da0: <IBM DGHS09Z 0350> Fixed Direct Access SCSI-3 device
da0: 20.000MB/s transfers (20.000MHz, offset 30), Tagged Queueing Enabled
da0: 8748MB (17916240 512 byte sectors: 255H 63S/T 1115C)
cd0 at ahc0 bus 0 target 1 lun 0
cd0: <TEAC CD-ROM CD-532S 1.0A> Removable CD-ROM SCSI-2 device
cd0: 20.000MB/s transfers (20.000MHz, offset 16)
cd0: Attempt to query device size failed: NOT READY, Medium not present
xl0: selecting BNC port, half duplex
xl0: starting DAD for fe80:0001::0250:04ff:fe2e:e38d
xl0: DAD complete for fe80:0001::0250:04ff:fe2e:e38d - no duplicates found

===============================================================================

Thanks,
Michael
Comment 3 M.Indlekofer 2000-03-31 14:07:12 UTC
I have solved the problem.
The 4.0 SMP kernel is very critical concerning interrupts.
I had to assign the interrupts manually for all controllers in the BIOS setup:
(IRQ9 for graphics, IRQ10 for network, IRQ11 for SCSI works)

Thanks,
Michael
Comment 4 ken 2000-03-31 16:47:51 UTC
On Fri, Mar 31, 2000 at 15:07:12 +0200, Klaus Michael Indlekofer wrote:
> I have solved the problem.
> The 4.0 SMP kernel is very critical concerning interrupts.
> I had to assign the interrupts manually for all controllers in the BIOS setup:
> (IRQ9 for graphics, IRQ10 for network, IRQ11 for SCSI works)

I'm glad you got it working. :)

Ken
-- 
Kenneth Merry
ken@kdm.org
Comment 5 Kenneth D. Merry freebsd_committer freebsd_triage 2000-03-31 16:51:18 UTC
State Changed
From-To: open->closed

PR submitter reports that he has fixed the problem. 
Comment 6 Bryan Drewery freebsd_committer freebsd_triage 2013-09-28 16:17:32 UTC
Responsible Changed
From-To: freebsd-bugs->amdmi3

Over to maintainer.
Comment 7 Bryan Drewery freebsd_committer freebsd_triage 2013-09-28 16:19:14 UTC
Responsible Changed
From-To: amdmi3->freebsd-bugs

Modified wrong PR