NetBSD/i386 PS/2 and MCA Bus Support
Release 3.1 (for NetBSD 1.3.3)
Unofficial patches and drivers for the NetBSD/i386 1.3.3 kernel to support
IBM PS/2 systems with MCA (MicroChannel) buses.
Tested (to a very limited extent) on
- IBM PS/2 Model 70-E61 with 2Mb RAM (!), 60Mb ESDI disk/controller and a 3Com 3C523 Ethernet
adapter.
- IBM PS/2 Model 80 with 4Mb RAM, 115Mb ESDI disk
Further testing and feedback appreciated.
Changes made to kernel
- New "mca" bus driver, with MI and i386-specific support subroutines
modelled after the existing NetBSD 1.3 PCI and EISA bus drivers.
Typical config file entries would be of the form:
mca0 at mainbus0
...
aha0 at mca0 slot ?
scsibus0 at aha0
...
Only mca0 is currently supported. The "slot" parameter can be specified
or wildcarded as above. Devices are probed in slot number order. Slots
are numbered from 1 to 8. If "options MCAVERBOSE" is used, all detected
MCA devices are logged at boot-up thus:
mca0 slot n: Device Description (0x1234)
or
mca0 slot n: unknown id 0x1234
where 0x1234 is the 16-bit MCA device ID.
MCA devices not attached will generate a message giving the reason:
"disabled" if the device's "enabled" bit (POS register 2 bit 0) is zero
(the device is subsequently ignored); "not supported" if no driver
recognises the ID; "not configured" if no appropriate device in kernel
configuration.
- Device drivers:
- MCA "front-end" to the "aha" driver to support the Adaptec
AHA-1640 SCSI adapter.
- "libi386" needs to be patched and recompiled with IBM_L40 defined
for "biosboot", to enable A20 correctly for PS/2s.
- "options PS2MCA" config option enables following changes in
arch/i386 code necessary for MCA-bus PS/2 systems:
- "mainbus" does MCA bus probe if an "mca" bus is in config file
- 8259s initialized for level-triggered interrupts.
- "com", "lpt", "pms", "fd", "npx", "pccons" and "pcvt" drivers
register level-triggered interrupts. "pcvt", "npx" and "lpt" untested.
- "fd" driver step rate changed for compatibility with PS/2 floppy drives
- clock (IRQ 0) interrupt handler acknowledges interrupt.
- NMI handler attempts to decode NMIs generated by MCA devices. (untested!)
Open Issues
- MCA bus detection is by checking certain bits of MCA adapter setup
register at port 0x96: not sure if this is the best way to do it.
- Floppy driver is still a little flakey (some soft errors).
720k 3.5in floppies not tested.
- Shared IRQs untested.
- pccons reports on-board VGA framebuffer as "mono"
Files
README This document
mca.diff diffs against 1.3.3 kernel source in unified
format relative to /sys
sys/dev/mca/
files.mca MCA bus files
mca.c MI MCA autoconfiguration code
mcadevs_data.h MCA device IDs and descriptions table
mcareg.h MI standardized MCA configuration information
mcavar.h MI definitions for MCA autoconfiguration
aha_mca.c MCA bus code for "aha" driver
sys/arch/i386/mca/
mca_machdep.c i386-specific functions for MCA autoconfig
mca_machdep.h i386-specific definitions for MCA autoconfig
sys/arch/i386/conf/
JET_DDB Sample config file (for test machine, diskless)
INSTALL_MCA Sample config file (for small install kernel)
Release History
- 3.1 (99/09/28)
- Removed non-functional "em" 3C523 driver
- 3.0 (99/09/20)
- Ported to NetBSD 1.3.3
- "fd" driver tweaks
- Many more MCA IDs added to mcadevs_data.h
- 3C523 driver now based on 1.3H "ef" 3C507 driver and called "em"
(not working yet)
- 2.1 (97/01/16)
- Restructured "aha" driver and added support for AHA-1640
- MCA device boot-up message format changed
- Minor change to ie_mca_attach()
- 2.0 (96/11/25)
- Ported to NetBSD 1.2
- Restructured "ie" driver (ISA/MCA)
- Runtime MCA bus detection
- Skeletal PS/2 ESDI driver removed temporarily
- Some more MCA IDs added to mcadevs_data.h
- 1.1 (96/11/08)
- ISA "ie" driver patches to support 3C523
- Some more MCA IDs added to mcadevs_data.h
- 1.0 (96/08/29)
- Initial release for NetBSD 1.1pl1
References
- Assorted MCA Linux patches
- Minix 1.5.10 and 1.7.4 kernel
- Mach MK83a
- Crynwyr Packer Driver Collection for MS-DOS, release 11c
- "The Indispensable PC Hardware Book", 2/e, Hans-Peter Messmer,
Addison-Wesley, 1995
- IBM 8570/8580 Reference Diskette
Acknowledgements
- Andrew Gillham (AHA-1640 testing)
- Bob Keys (PS/2 Model 80 testing)
--
Scott Telford, 99/09/27.
Sample kernel message output (from test system, NetBSD 1.2 with
PS/2 and MCA patches release 2.1, MCAVERBOSE selected)
NetBSD 1.2 (JET_DDB) #21: Wed Jan 15 23:45:53 GMT 1997
root@trillian:/usr/src/local/sys-1.2/arch/i386/compile/JET_DDB
CPU: i386DX (386-class CPU)
real mem = 1966080
avail mem = 892928
using 32 buffers containing 131072 bytes of memory
mainbus0 (root)
isa0 at mainbus0
com0 at isa0 port 0x3f8-0x3ff irq 4: ns16550a, working fifo
com0: console
lpt0 at isa0 port 0x3bc-0x3c3 irq 7
pc0 at isa0 port 0x60-0x6f irq 1: mono
pms0 at pc0 irq 12
fdc0 at isa0 port 0x3f0-0x3f7 irq 6 drq 2
fd0 at fdc0 drive 0: 1.44MB 80 cyl, 2 head, 18 sec
mca0 at mainbus0
mca0 slot 1: 3Com 3C523 Ethernet Adapter (0x6042)
ie0 at mca0 slot 1: address 02:60:8c:3f:98:6f, type 3C523 R14, external xcvr
mca0 slot 4: IBM Integ. ESDI Fixed Disk & Controller (0xdf9f)
IBM Integ. ESDI Fixed Disk & Controller (0xdf9f) at mca0 slot 4 unsupported
biomask 40 netmask 48 ttymask 10da
changing root device to fd0a
Download (FTP)
Links