ISA PnP utilities Version 1.10 ============================== These programs allow ISA Plug-And-Play devices to be configured on a Linux machine. This program is suitable for all systems, whether or not they include a PnP BIOS. In fact, a PnP BIOS adds some complications because it may already activate some cards so that the drivers can find them, and these tools can unconfigure them, or change their settings causing all sorts of nasty effects. If you have (for example) plug and play network cards that already work, I suggest you read the manual page isapnp.conf(5) on the format of the configuration file very carefully. See the example for a dataflex voice fax modem and NE2000 clone PnP card in README.modules. See the section below on Drivers and MODULES for more background information. For even more hints etc see the FAQ at: http://www.roestock.demon.co.uk/isapnptools/isapnpfaq.html The commands have been taken from the Plug and Play ISA specification Version 1.0a, widely available on the net. (ftp://developr/drg/Plug-and-Play/Pnpspecs/PNPISA.EXE - this is a self-extracting DOS archive of PNPISA.DOC - a word 6 document. If Word 6 not available, use the freely redistributable viewer wordview which comes on the Win95 CD). See CHANGES for a list of changes from the previous version. See README.OS2 for description of OS2 stuff. Installation intructions ======================== See the file INSTALL. Format of pnp configuration file: ================================= See the manual page isapnp.conf.5. Drivers and MODULES =================== Note that boards first configured by isapnp are not visible to the kernel during boot up. This means that drivers for the boards must be loaded as modules after the board has been configured, so that they can locate the board. See README.modules for an example. This doesn't apply to serial cards, because setserial can be used to configure the serial ports after the kernel has booted. Also, IDE devices can be initialised after the kernel boots by configuring IDE-PCMCIA in the kernel. Then writing a module to initialise the device after running isapnp. See README.ide and /usr/src/linux/Documentation/Configure.help. An alternative method is to use initrd to run isapnp before booting the main kernel. See README.initrd and /usr/src/linux/Documentation/initrd.txt. This may be particularly applicable for IDE devices attached to PnP cards. I hope to experiment with initrd sometime for my network card... if you've already done it please tell me how. If the kernel needs rebooting after configuration, because the drivers are not modules, it may be possible to do this automatically in your bootup scripts: use an isapnp.conf file which dumps the board configuration registers and tests the the output. If the board(s) haven't been configured, configure them with the configuration isapnp.conf file and reboot. If the boards have been configured, continue the boot normally. You may want to take precautions to prevent the kernel continuously rebooting if something goes wrong... isapnp for debugging. ===================== This example shows how the PEEK command may now be used with the standard configuration settings to dump the actual board configuration register settings, for example, the script: #(DEBUG) (READPORT 0x3bb) #(READPORT 0x203) (CSN 1) # Or as many cards as you have (IDENTIFY *) (CONFIGURE DFX0000/1493 (LD 0 (IO 0 (PEEK)) # Dump Port 0 (IO 1 (PEEK)) # Dump Port 1 (IO 2 (PEEK)) # Dump Port 2 (INT 0 (PEEK)) # Dump INT 0 (DMA 0 (PEEK)) # Dump DMA 0 (DMA 1 (PEEK)) # Dump DMA 1 (MEM 0 (PEEK)) # Dump MEM 0 (REG 0x60 (PEEK)) (REG 0x61 (PEEK)) # Dump Port 0 (REG 0x62 (PEEK)) (REG 0x63 (PEEK)) # Dump Port 1 (REG 0x64 (PEEK)) (REG 0x65 (PEEK)) # Dump Port 2 (REG 0x70 (PEEK)) (REG 0x71 (PEEK)) # Dump INT 0 (REG 0x74 (PEEK)) # Dump DMA 0 (REG 0x75 (PEEK)) # Dump DMA 1 )) (WAITFORKEY) produces the following with my dataflex modem: Board 1 has Identity 6e 00 00 05 d5 00 00 d8 10: DFX0000 Serial No 1493 [checksum 6e] Peek(DFX0000/1493)[0][0x60](IO 0) is 0x03E8, (3,232) Peek(DFX0000/1493)[0][0x62](IO 1) is 0x0000, (0,0) Peek(DFX0000/1493)[0][0x64](IO 2) is 0x0000, (0,0) Peek(DFX0000/1493)[0][0x70](INT 0) is 0x0C02, (12,2) Peek(DFX0000/1493)[0][0x74](DMA 0) is 0x04, (4) Peek(DFX0000/1493)[0][0x74](DMA 0) is 0x04, (4) Peek(DFX0000/1493)[0][0x40](MEM 0) is 0x0000000000000000, (0,0,0,0,0,0,0,0) Peek(DFX0000/1493)[0][0x60](-REG-) is 0x03, (3) Peek(DFX0000/1493)[0][0x61](-REG-) is 0xE8, (232) Peek(DFX0000/1493)[0][0x62](-REG-) is 0x00, (0) Peek(DFX0000/1493)[0][0x63](-REG-) is 0x00, (0) Peek(DFX0000/1493)[0][0x64](-REG-) is 0x00, (0) Peek(DFX0000/1493)[0][0x65](-REG-) is 0x00, (0) Peek(DFX0000/1493)[0][0x70](-REG-) is 0x0C, (12) Peek(DFX0000/1493)[0][0x71](-REG-) is 0x02, (2) Peek(DFX0000/1493)[0][0x74](-REG-) is 0x04, (4) Peek(DFX0000/1493)[0][0x75](-REG-) is 0x04, (4) Bugs ==== I haven't tested the Memory setting stuff, as I haven't got a card with suitable drivers. If it doesn't work, tell me, and work around using poke, which I have tested. Note ==== These programs must run as root, as they need unrestricted access to the computer IO addresses. This could cause lots of problems, so use with care. DO NOT MAKE THESE PROGRAMS SUID root ! Copyright ========= These programs are copyright P.J.H.Fox (fox@roestock.demon.co.uk) and distributed under the GPL (see COPYING). If mailing patches, bug reports or comments, please put 'isapnp' somewhere in the subject line, and mail to isapnp@roestock.demon.co.uk. Warranty ======== There is NO WARRANTY for these programs. These programs have been compiled on my machine using gcc 2.7.2, flex 2.4.7 and linux 2.0.30, with libc-5.3.12 and they seem to work for me. However, due to the nature of these programs, they are very likely to completely screw up your computer: USE AT YOUR OWN RISK. But if you find them useful, or have some suggestions for improvement, please tell me. Credits ======= Thanks to the following for bug fixes and improvements to isapnptools. Bob Clark Neal Sanche Karsten Keil Jim Studt Jeff Epler Markus Gutschke Andy Sewell See also ======== Users of isapnptools may be interested in the pnp mailing list (pnp-list@redhat.com): To subscribe to the mailinglist, simply send a message with the word "subscribe" in the Subject: field to pnp-list-request@redhat.com. Latest information of isapnptools is available at the time of writing on my website: http://www.roestock.demon.co.uk/isapnptools/. This includes an FAQ, and htmlised manual pages, so please refer to this first in the event of any difficulties. Peter Fox 10-Jun-97