1714a4da4SMauro Carvalho Chehab.. SPDX-License-Identifier: GPL-2.0 21da177e4SLinus Torvalds 3714a4da4SMauro Carvalho Chehab================================================ 4714a4da4SMauro Carvalho ChehabCirrus Logic LAN CS8900/CS8920 Ethernet Adapters 5714a4da4SMauro Carvalho Chehab================================================ 6714a4da4SMauro Carvalho Chehab 7714a4da4SMauro Carvalho Chehab.. note:: 81da177e4SLinus Torvalds 91da177e4SLinus Torvalds This document was contributed by Cirrus Logic for kernel 2.2.5. This version 10e1f8e874SFrancois Cami has been updated for 2.3.48 by Andrew Morton. 111da177e4SLinus Torvalds 12714a4da4SMauro Carvalho Chehab Still, this is too outdated! A major cleanup is needed here. 13714a4da4SMauro Carvalho Chehab 141da177e4SLinus TorvaldsCirrus make a copy of this driver available at their website, as 151da177e4SLinus Torvaldsdescribed below. In general, you should use the driver version which 161da177e4SLinus Torvaldscomes with your Linux distribution. 171da177e4SLinus Torvalds 181da177e4SLinus Torvalds 191da177e4SLinus TorvaldsLinux Network Interface Driver ver. 2.00 <kernel 2.3.48> 201da177e4SLinus Torvalds 211da177e4SLinus Torvalds 22714a4da4SMauro Carvalho Chehab.. TABLE OF CONTENTS 231da177e4SLinus Torvalds 241da177e4SLinus Torvalds 1.0 CIRRUS LOGIC LAN CS8900/CS8920 ETHERNET ADAPTERS 251da177e4SLinus Torvalds 1.1 Product Overview 261da177e4SLinus Torvalds 1.2 Driver Description 271da177e4SLinus Torvalds 1.2.1 Driver Name 281da177e4SLinus Torvalds 1.2.2 File in the Driver Package 291da177e4SLinus Torvalds 1.3 System Requirements 301da177e4SLinus Torvalds 1.4 Licensing Information 311da177e4SLinus Torvalds 321da177e4SLinus Torvalds 2.0 ADAPTER INSTALLATION and CONFIGURATION 331da177e4SLinus Torvalds 2.1 CS8900-based Adapter Configuration 341da177e4SLinus Torvalds 2.2 CS8920-based Adapter Configuration 351da177e4SLinus Torvalds 361da177e4SLinus Torvalds 3.0 LOADING THE DRIVER AS A MODULE 371da177e4SLinus Torvalds 381da177e4SLinus Torvalds 4.0 COMPILING THE DRIVER 391da177e4SLinus Torvalds 4.1 Compiling the Driver as a Loadable Module 401da177e4SLinus Torvalds 4.2 Compiling the driver to support memory mode 411da177e4SLinus Torvalds 4.3 Compiling the driver to support Rx DMA 421da177e4SLinus Torvalds 431da177e4SLinus Torvalds 5.0 TESTING AND TROUBLESHOOTING 441da177e4SLinus Torvalds 5.1 Known Defects and Limitations 451da177e4SLinus Torvalds 5.2 Testing the Adapter 461da177e4SLinus Torvalds 5.2.1 Diagnostic Self-Test 471da177e4SLinus Torvalds 5.2.2 Diagnostic Network Test 481da177e4SLinus Torvalds 5.3 Using the Adapter's LEDs 491da177e4SLinus Torvalds 5.4 Resolving I/O Conflicts 501da177e4SLinus Torvalds 511da177e4SLinus Torvalds 6.0 TECHNICAL SUPPORT 521da177e4SLinus Torvalds 6.1 Contacting Cirrus Logic's Technical Support 531da177e4SLinus Torvalds 6.2 Information Required Before Contacting Technical Support 541da177e4SLinus Torvalds 6.3 Obtaining the Latest Driver Version 551da177e4SLinus Torvalds 6.4 Current maintainer 561da177e4SLinus Torvalds 6.5 Kernel boot parameters 571da177e4SLinus Torvalds 581da177e4SLinus Torvalds 59714a4da4SMauro Carvalho Chehab1. Cirrus Logic LAN CS8900/CS8920 Ethernet Adapters 60714a4da4SMauro Carvalho Chehab=================================================== 611da177e4SLinus Torvalds 621da177e4SLinus Torvalds 63714a4da4SMauro Carvalho Chehab1.1. Product Overview 64714a4da4SMauro Carvalho Chehab===================== 651da177e4SLinus Torvalds 661da177e4SLinus TorvaldsThe CS8900-based ISA Ethernet Adapters from Cirrus Logic follow 671da177e4SLinus TorvaldsIEEE 802.3 standards and support half or full-duplex operation in ISA bus 681da177e4SLinus Torvaldscomputers on 10 Mbps Ethernet networks. The adapters are designed for operation 691da177e4SLinus Torvaldsin 16-bit ISA or EISA bus expansion slots and are available in 701da177e4SLinus Torvalds10BaseT-only or 3-media configurations (10BaseT, 10Base2, and AUI for 10Base-5 711da177e4SLinus Torvaldsor fiber networks). 721da177e4SLinus Torvalds 731da177e4SLinus TorvaldsCS8920-based adapters are similar to the CS8900-based adapter with additional 741da177e4SLinus Torvaldsfeatures for Plug and Play (PnP) support and Wakeup Frame recognition. As 751da177e4SLinus Torvaldssuch, the configuration procedures differ somewhat between the two types of 761da177e4SLinus Torvaldsadapters. Refer to the "Adapter Configuration" section for details on 771da177e4SLinus Torvaldsconfiguring both types of adapters. 781da177e4SLinus Torvalds 791da177e4SLinus Torvalds 80714a4da4SMauro Carvalho Chehab1.2. Driver Description 81714a4da4SMauro Carvalho Chehab======================= 821da177e4SLinus Torvalds 831da177e4SLinus TorvaldsThe CS8900/CS8920 Ethernet Adapter driver for Linux supports the Linux 841da177e4SLinus Torvaldsv2.3.48 or greater kernel. It can be compiled directly into the kernel 851da177e4SLinus Torvaldsor loaded at run-time as a device driver module. 861da177e4SLinus Torvalds 871da177e4SLinus Torvalds1.2.1 Driver Name: cs89x0 881da177e4SLinus Torvalds 891da177e4SLinus Torvalds1.2.2 Files in the Driver Archive: 901da177e4SLinus Torvalds 911da177e4SLinus TorvaldsThe files in the driver at Cirrus' website include: 921da177e4SLinus Torvalds 93714a4da4SMauro Carvalho Chehab =================== ==================================================== 94714a4da4SMauro Carvalho Chehab readme.txt this file 95714a4da4SMauro Carvalho Chehab build batch file to compile cs89x0.c. 96714a4da4SMauro Carvalho Chehab cs89x0.c driver C code 97714a4da4SMauro Carvalho Chehab cs89x0.h driver header file 98714a4da4SMauro Carvalho Chehab cs89x0.o pre-compiled module (for v2.2.5 kernel) 99714a4da4SMauro Carvalho Chehab config/Config.in sample file to include cs89x0 driver in the kernel. 100714a4da4SMauro Carvalho Chehab config/Makefile sample file to include cs89x0 driver in the kernel. 101714a4da4SMauro Carvalho Chehab config/Space.c sample file to include cs89x0 driver in the kernel. 102714a4da4SMauro Carvalho Chehab =================== ==================================================== 1031da177e4SLinus Torvalds 1041da177e4SLinus Torvalds 1051da177e4SLinus Torvalds 106714a4da4SMauro Carvalho Chehab1.3. System Requirements 107714a4da4SMauro Carvalho Chehab------------------------ 1081da177e4SLinus Torvalds 1091da177e4SLinus TorvaldsThe following hardware is required: 1101da177e4SLinus Torvalds 1111da177e4SLinus Torvalds * Cirrus Logic LAN (CS8900/20-based) Ethernet ISA Adapter 1121da177e4SLinus Torvalds 1131da177e4SLinus Torvalds * IBM or IBM-compatible PC with: 1141da177e4SLinus Torvalds * An 80386 or higher processor 1151da177e4SLinus Torvalds * 16 bytes of contiguous IO space available between 210h - 370h 1161da177e4SLinus Torvalds * One available IRQ (5,10,11,or 12 for the CS8900, 3-7,9-15 for CS8920). 1171da177e4SLinus Torvalds 1181da177e4SLinus Torvalds * Appropriate cable (and connector for AUI, 10BASE-2) for your network 1191da177e4SLinus Torvalds topology. 1201da177e4SLinus Torvalds 1211da177e4SLinus TorvaldsThe following software is required: 1221da177e4SLinus Torvalds 1231da177e4SLinus Torvalds* LINUX kernel version 2.3.48 or higher 1241da177e4SLinus Torvalds 1251da177e4SLinus Torvalds * CS8900/20 Setup Utility (DOS-based) 1261da177e4SLinus Torvalds 1271da177e4SLinus Torvalds * LINUX kernel sources for your kernel (if compiling into kernel) 1281da177e4SLinus Torvalds 1291da177e4SLinus Torvalds * GNU Toolkit (gcc and make) v2.6 or above (if compiling into kernel 1301da177e4SLinus Torvalds or a module) 1311da177e4SLinus Torvalds 1321da177e4SLinus Torvalds 1331da177e4SLinus Torvalds 134714a4da4SMauro Carvalho Chehab1.4. Licensing Information 135714a4da4SMauro Carvalho Chehab-------------------------- 1361da177e4SLinus Torvalds 1371da177e4SLinus TorvaldsThis program is free software; you can redistribute it and/or modify it under 1381da177e4SLinus Torvaldsthe terms of the GNU General Public License as published by the Free Software 1391da177e4SLinus TorvaldsFoundation, version 1. 1401da177e4SLinus Torvalds 1411da177e4SLinus TorvaldsThis program is distributed in the hope that it will be useful, but WITHOUT 1421da177e4SLinus TorvaldsANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 1431da177e4SLinus TorvaldsFITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 1441da177e4SLinus Torvaldsmore details. 1451da177e4SLinus Torvalds 1461da177e4SLinus TorvaldsFor a full copy of the GNU General Public License, write to the Free Software 1471da177e4SLinus TorvaldsFoundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 1481da177e4SLinus Torvalds 1491da177e4SLinus Torvalds 1501da177e4SLinus Torvalds 151714a4da4SMauro Carvalho Chehab2. Adapter Installation and Configuration 152714a4da4SMauro Carvalho Chehab========================================= 1531da177e4SLinus Torvalds 1541da177e4SLinus TorvaldsBoth the CS8900 and CS8920-based adapters can be configured using parameters 1551da177e4SLinus Torvaldsstored in an on-board EEPROM. You must use the DOS-based CS8900/20 Setup 1561da177e4SLinus TorvaldsUtility if you want to change the adapter's configuration in EEPROM. 1571da177e4SLinus Torvalds 1581da177e4SLinus TorvaldsWhen loading the driver as a module, you can specify many of the adapter's 1591da177e4SLinus Torvaldsconfiguration parameters on the command-line to override the EEPROM's settings 1601da177e4SLinus Torvaldsor for interface configuration when an EEPROM is not used. (CS8920-based 1611da177e4SLinus Torvaldsadapters must use an EEPROM.) See Section 3.0 LOADING THE DRIVER AS A MODULE. 1621da177e4SLinus Torvalds 1631da177e4SLinus TorvaldsSince the CS8900/20 Setup Utility is a DOS-based application, you must install 1641da177e4SLinus Torvaldsand configure the adapter in a DOS-based system using the CS8900/20 Setup 1651da177e4SLinus TorvaldsUtility before installation in the target LINUX system. (Not required if 1661da177e4SLinus Torvaldsinstalling a CS8900-based adapter and the default configuration is acceptable.) 1671da177e4SLinus Torvalds 1681da177e4SLinus Torvalds 169714a4da4SMauro Carvalho Chehab2.1. CS8900-based Adapter Configuration 170714a4da4SMauro Carvalho Chehab--------------------------------------- 1711da177e4SLinus Torvalds 1721da177e4SLinus TorvaldsCS8900-based adapters shipped from Cirrus Logic have been configured 173714a4da4SMauro Carvalho Chehabwith the following "default" settings:: 1741da177e4SLinus Torvalds 1751da177e4SLinus Torvalds Operation Mode: Memory Mode 1761da177e4SLinus Torvalds IRQ: 10 1771da177e4SLinus Torvalds Base I/O Address: 300 1781da177e4SLinus Torvalds Memory Base Address: D0000 1791da177e4SLinus Torvalds Optimization: DOS Client 1801da177e4SLinus Torvalds Transmission Mode: Half-duplex 1811da177e4SLinus Torvalds BootProm: None 1821da177e4SLinus Torvalds Media Type: Autodetect (3-media cards) or 1831da177e4SLinus Torvalds 10BASE-T (10BASE-T only adapter) 1841da177e4SLinus Torvalds 1851da177e4SLinus TorvaldsYou should only change the default configuration settings if conflicts with 1861da177e4SLinus Torvaldsanother adapter exists. To change the adapter's configuration, run the 1871da177e4SLinus TorvaldsCS8900/20 Setup Utility. 1881da177e4SLinus Torvalds 1891da177e4SLinus Torvalds 190714a4da4SMauro Carvalho Chehab2.2. CS8920-based Adapter Configuration 191714a4da4SMauro Carvalho Chehab--------------------------------------- 1921da177e4SLinus Torvalds 1931da177e4SLinus TorvaldsCS8920-based adapters are shipped from Cirrus Logic configured as Plug 1941da177e4SLinus Torvaldsand Play (PnP) enabled. However, since the cs89x0 driver does NOT 1951da177e4SLinus Torvaldssupport PnP, you must install the CS8920 adapter in a DOS-based PC and 1961da177e4SLinus Torvaldsrun the CS8900/20 Setup Utility to disable PnP and configure the 1971da177e4SLinus Torvaldsadapter before installation in the target Linux system. Failure to do 1981da177e4SLinus Torvaldsthis will leave the adapter inactive and the driver will be unable to 1991da177e4SLinus Torvaldscommunicate with the adapter. 2001da177e4SLinus Torvalds 201714a4da4SMauro Carvalho Chehab:: 2021da177e4SLinus Torvalds 2031da177e4SLinus Torvalds **************************************************************** 2041da177e4SLinus Torvalds * CS8920-BASED ADAPTERS: * 2051da177e4SLinus Torvalds * * 2061da177e4SLinus Torvalds * CS8920-BASED ADAPTERS ARE PLUG and PLAY ENABLED BY DEFAULT. * 2071da177e4SLinus Torvalds * THE CS89X0 DRIVER DOES NOT SUPPORT PnP. THEREFORE, YOU MUST * 2081da177e4SLinus Torvalds * RUN THE CS8900/20 SETUP UTILITY TO DISABLE PnP SUPPORT AND * 2091da177e4SLinus Torvalds * TO ACTIVATE THE ADAPTER. * 2101da177e4SLinus Torvalds **************************************************************** 2111da177e4SLinus Torvalds 2121da177e4SLinus Torvalds 2131da177e4SLinus Torvalds 2141da177e4SLinus Torvalds 215714a4da4SMauro Carvalho Chehab3. Loading the Driver as a Module 216714a4da4SMauro Carvalho Chehab================================= 2171da177e4SLinus Torvalds 2181da177e4SLinus TorvaldsIf the driver is compiled as a loadable module, you can load the driver module 2191da177e4SLinus Torvaldswith the 'modprobe' command. Many of the adapter's configuration parameters can 2201da177e4SLinus Torvaldsbe specified as command-line arguments to the load command. This facility 2211da177e4SLinus Torvaldsprovides a means to override the EEPROM's settings or for interface 2221da177e4SLinus Torvaldsconfiguration when an EEPROM is not used. 2231da177e4SLinus Torvalds 224714a4da4SMauro Carvalho ChehabExample:: 2251da177e4SLinus Torvalds 2261da177e4SLinus Torvalds insmod cs89x0.o io=0x200 irq=0xA media=aui 2271da177e4SLinus Torvalds 2281da177e4SLinus TorvaldsThis example loads the module and configures the adapter to use an IO port base 2291da177e4SLinus Torvaldsaddress of 200h, interrupt 10, and use the AUI media connection. The following 230714a4da4SMauro Carvalho Chehabconfiguration options are available on the command line:: 2311da177e4SLinus Torvalds 232714a4da4SMauro Carvalho Chehab io=### - specify IO address (200h-360h) 233714a4da4SMauro Carvalho Chehab irq=## - specify interrupt level 234714a4da4SMauro Carvalho Chehab use_dma=1 - Enable DMA 235714a4da4SMauro Carvalho Chehab dma=# - specify dma channel (Driver is compiled to support 2361da177e4SLinus Torvalds Rx DMA only) 237714a4da4SMauro Carvalho Chehab dmasize=# (16 or 64) - DMA size 16K or 64K. Default value is set to 16. 238714a4da4SMauro Carvalho Chehab media=rj45 - specify media type 2391da177e4SLinus Torvalds or media=bnc 2401da177e4SLinus Torvalds or media=aui 2412fe0ae78SMatt LaPlante or media=auto 242714a4da4SMauro Carvalho Chehab duplex=full - specify forced half/full/autonegotiate duplex 2431da177e4SLinus Torvalds or duplex=half 2441da177e4SLinus Torvalds or duplex=auto 245714a4da4SMauro Carvalho Chehab debug=# - debug level (only available if the driver was compiled 2461da177e4SLinus Torvalds for debugging) 2471da177e4SLinus Torvalds 248714a4da4SMauro Carvalho Chehab**Notes:** 2491da177e4SLinus Torvalds 2501da177e4SLinus Torvaldsa) If an EEPROM is present, any specified command-line parameter 2511da177e4SLinus Torvalds will override the corresponding configuration value stored in 2521da177e4SLinus Torvalds EEPROM. 2531da177e4SLinus Torvalds 2541da177e4SLinus Torvaldsb) The "io" parameter must be specified on the command-line. 2551da177e4SLinus Torvalds 2561da177e4SLinus Torvaldsc) The driver's hardware probe routine is designed to avoid 2571da177e4SLinus Torvalds writing to I/O space until it knows that there is a cs89x0 2581da177e4SLinus Torvalds card at the written addresses. This could cause problems 2591da177e4SLinus Torvalds with device probing. To avoid this behaviour, add one 260714a4da4SMauro Carvalho Chehab to the ``io=`` module parameter. This doesn't actually change 2611da177e4SLinus Torvalds the I/O address, but it is a flag to tell the driver 2621da177e4SLinus Torvalds to partially initialise the hardware before trying to 2631da177e4SLinus Torvalds identify the card. This could be dangerous if you are 2641da177e4SLinus Torvalds not sure that there is a cs89x0 card at the provided address. 2651da177e4SLinus Torvalds 2661da177e4SLinus Torvalds For example, to scan for an adapter located at IO base 0x300, 2671da177e4SLinus Torvalds specify an IO address of 0x301. 2681da177e4SLinus Torvalds 2691da177e4SLinus Torvaldsd) The "duplex=auto" parameter is only supported for the CS8920. 2701da177e4SLinus Torvalds 2711da177e4SLinus Torvaldse) The minimum command-line configuration required if an EEPROM is 2721da177e4SLinus Torvalds not present is: 2731da177e4SLinus Torvalds 2741da177e4SLinus Torvalds io 2751da177e4SLinus Torvalds irq 2761da177e4SLinus Torvalds media type (no autodetect) 2771da177e4SLinus Torvalds 2781da177e4SLinus Torvaldsf) The following additional parameters are CS89XX defaults (values 2791da177e4SLinus Torvalds used with no EEPROM or command-line argument). 2801da177e4SLinus Torvalds 2811da177e4SLinus Torvalds * DMA Burst = enabled 2821da177e4SLinus Torvalds * IOCHRDY Enabled = enabled 2831da177e4SLinus Torvalds * UseSA = enabled 2841da177e4SLinus Torvalds * CS8900 defaults to half-duplex if not specified on command-line 2851da177e4SLinus Torvalds * CS8920 defaults to autoneg if not specified on command-line 2861da177e4SLinus Torvalds * Use reset defaults for other config parameters 2871da177e4SLinus Torvalds * dma_mode = 0 2881da177e4SLinus Torvalds 2891da177e4SLinus Torvaldsg) You can use ifconfig to set the adapter's Ethernet address. 2901da177e4SLinus Torvalds 2911da177e4SLinus Torvaldsh) Many Linux distributions use the 'modprobe' command to load 2921da177e4SLinus Torvalds modules. This program uses the '/etc/conf.modules' file to 2931da177e4SLinus Torvalds determine configuration information which is passed to a driver 2941da177e4SLinus Torvalds module when it is loaded. All the configuration options which are 2951da177e4SLinus Torvalds described above may be placed within /etc/conf.modules. 2961da177e4SLinus Torvalds 297714a4da4SMauro Carvalho Chehab For example:: 2981da177e4SLinus Torvalds 2991da177e4SLinus Torvalds > cat /etc/conf.modules 3001da177e4SLinus Torvalds ... 3011da177e4SLinus Torvalds alias eth0 cs89x0 3021da177e4SLinus Torvalds options cs89x0 io=0x0200 dma=5 use_dma=1 3031da177e4SLinus Torvalds ... 3041da177e4SLinus Torvalds 3051da177e4SLinus Torvalds In this example we are telling the module system that the 3061da177e4SLinus Torvalds ethernet driver for this machine should use the cs89x0 driver. We 3071da177e4SLinus Torvalds are asking 'modprobe' to pass the 'io', 'dma' and 'use_dma' 3081da177e4SLinus Torvalds arguments to the driver when it is loaded. 3091da177e4SLinus Torvalds 3101da177e4SLinus Torvaldsi) Cirrus recommend that the cs89x0 use the ISA DMA channels 5, 6 or 3111da177e4SLinus Torvalds 7. You will probably find that other DMA channels will not work. 3121da177e4SLinus Torvalds 3131da177e4SLinus Torvaldsj) The cs89x0 supports DMA for receiving only. DMA mode is 3141da177e4SLinus Torvalds significantly more efficient. Flooding a 400 MHz Celeron machine 3151da177e4SLinus Torvalds with large ping packets consumes 82% of its CPU capacity in non-DMA 3161da177e4SLinus Torvalds mode. With DMA this is reduced to 45%. 3171da177e4SLinus Torvalds 3181da177e4SLinus Torvaldsk) If your Linux kernel was compiled with inbuilt plug-and-play 3191da177e4SLinus Torvalds support you will be able to find information about the cs89x0 card 320714a4da4SMauro Carvalho Chehab with the command:: 3211da177e4SLinus Torvalds 3221da177e4SLinus Torvalds cat /proc/isapnp 3231da177e4SLinus Torvalds 3241da177e4SLinus Torvaldsl) If during DMA operation you find erratic behavior or network data 3251da177e4SLinus Torvalds corruption you should use your PC's BIOS to slow the EISA bus clock. 3261da177e4SLinus Torvalds 3271da177e4SLinus Torvaldsm) If the cs89x0 driver is compiled directly into the kernel 3281da177e4SLinus Torvalds (non-modular) then its I/O address is automatically determined by 3291da177e4SLinus Torvalds ISA bus probing. The IRQ number, media options, etc are determined 3301da177e4SLinus Torvalds from the card's EEPROM. 3311da177e4SLinus Torvalds 3321da177e4SLinus Torvaldsn) If the cs89x0 driver is compiled directly into the kernel, DMA 3331da177e4SLinus Torvalds mode may be selected by providing the kernel with a boot option 3341da177e4SLinus Torvalds 'cs89x0_dma=N' where 'N' is the desired DMA channel number (5, 6 or 7). 3351da177e4SLinus Torvalds 336714a4da4SMauro Carvalho Chehab Kernel boot options may be provided on the LILO command line:: 3371da177e4SLinus Torvalds 3381da177e4SLinus Torvalds LILO boot: linux cs89x0_dma=5 3391da177e4SLinus Torvalds 340714a4da4SMauro Carvalho Chehab or they may be placed in /etc/lilo.conf:: 3411da177e4SLinus Torvalds 3421da177e4SLinus Torvalds image=/boot/bzImage-2.3.48 3431da177e4SLinus Torvalds append="cs89x0_dma=5" 3441da177e4SLinus Torvalds label=linux 3451da177e4SLinus Torvalds root=/dev/hda5 3461da177e4SLinus Torvalds read-only 3471da177e4SLinus Torvalds 3481da177e4SLinus Torvalds The DMA Rx buffer size is hardwired to 16 kbytes in this mode. 3491da177e4SLinus Torvalds (64k mode is not available). 3501da177e4SLinus Torvalds 3511da177e4SLinus Torvalds 352714a4da4SMauro Carvalho Chehab4. Compiling the Driver 353714a4da4SMauro Carvalho Chehab======================= 3541da177e4SLinus Torvalds 3551da177e4SLinus TorvaldsThe cs89x0 driver can be compiled directly into the kernel or compiled into 3561da177e4SLinus Torvaldsa loadable device driver module. 3571da177e4SLinus Torvalds 358714a4da4SMauro Carvalho ChehabJust use the standard way to configure the driver and compile the Kernel. 3591da177e4SLinus Torvalds 3601da177e4SLinus Torvalds 361714a4da4SMauro Carvalho Chehab4.1. Compiling the Driver to Support Rx DMA 362714a4da4SMauro Carvalho Chehab------------------------------------------- 3631da177e4SLinus Torvalds 3641da177e4SLinus TorvaldsThe compile-time optionality for DMA was removed in the 2.3 kernel 3651da177e4SLinus Torvaldsseries. DMA support is now unconditionally part of the driver. It is 3661da177e4SLinus Torvaldsenabled by the 'use_dma=1' module option. 3671da177e4SLinus Torvalds 3681da177e4SLinus Torvalds 369714a4da4SMauro Carvalho Chehab5. Testing and Troubleshooting 370714a4da4SMauro Carvalho Chehab============================== 3711da177e4SLinus Torvalds 372714a4da4SMauro Carvalho Chehab5.1. Known Defects and Limitations 373714a4da4SMauro Carvalho Chehab---------------------------------- 3741da177e4SLinus Torvalds 3751da177e4SLinus TorvaldsRefer to the RELEASE.TXT file distributed as part of this archive for a list of 3761da177e4SLinus Torvaldsknown defects, driver limitations, and work arounds. 3771da177e4SLinus Torvalds 3781da177e4SLinus Torvalds 379714a4da4SMauro Carvalho Chehab5.2. Testing the Adapter 380714a4da4SMauro Carvalho Chehab------------------------ 3811da177e4SLinus Torvalds 3821da177e4SLinus TorvaldsOnce the adapter has been installed and configured, the diagnostic option of 3831da177e4SLinus Torvaldsthe CS8900/20 Setup Utility can be used to test the functionality of the 3841da177e4SLinus Torvaldsadapter and its network connection. Use the diagnostics 'Self Test' option to 3851da177e4SLinus Torvaldstest the functionality of the adapter with the hardware configuration you have 3861da177e4SLinus Torvaldsassigned. You can use the diagnostics 'Network Test' to test the ability of the 3871da177e4SLinus Torvaldsadapter to communicate across the Ethernet with another PC equipped with a 3881da177e4SLinus TorvaldsCS8900/20-based adapter card (it must also be running the CS8900/20 Setup 3891da177e4SLinus TorvaldsUtility). 3901da177e4SLinus Torvalds 391714a4da4SMauro Carvalho Chehab.. note:: 392714a4da4SMauro Carvalho Chehab 393714a4da4SMauro Carvalho Chehab The Setup Utility's diagnostics are designed to run in a 3941da177e4SLinus Torvalds DOS-only operating system environment. DO NOT run the diagnostics 3951da177e4SLinus Torvalds from a DOS or command prompt session under Windows 95, Windows NT, 3961da177e4SLinus Torvalds OS/2, or other operating system. 3971da177e4SLinus Torvalds 3981da177e4SLinus TorvaldsTo run the diagnostics tests on the CS8900/20 adapter: 3991da177e4SLinus Torvalds 400714a4da4SMauro Carvalho Chehab 1. Boot DOS on the PC and start the CS8900/20 Setup Utility. 4011da177e4SLinus Torvalds 402714a4da4SMauro Carvalho Chehab 2. The adapter's current configuration is displayed. Hit the ENTER key to 4031da177e4SLinus Torvalds get to the main menu. 4041da177e4SLinus Torvalds 405714a4da4SMauro Carvalho Chehab 4. Select 'Diagnostics' (ALT-G) from the main menu. 4061da177e4SLinus Torvalds * Select 'Self-Test' to test the adapter's basic functionality. 4071da177e4SLinus Torvalds * Select 'Network Test' to test the network connection and cabling. 4081da177e4SLinus Torvalds 4091da177e4SLinus Torvalds 410714a4da4SMauro Carvalho Chehab5.2.1. Diagnostic Self-test 411714a4da4SMauro Carvalho Chehab^^^^^^^^^^^^^^^^^^^^^^^^^^^ 4121da177e4SLinus Torvalds 4131da177e4SLinus TorvaldsThe diagnostic self-test checks the adapter's basic functionality as well as 4141da177e4SLinus Torvaldsits ability to communicate across the ISA bus based on the system resources 4151da177e4SLinus Torvaldsassigned during hardware configuration. The following tests are performed: 4161da177e4SLinus Torvalds 4171da177e4SLinus Torvalds * IO Register Read/Write Test 418714a4da4SMauro Carvalho Chehab 4191da177e4SLinus Torvalds The IO Register Read/Write test insures that the CS8900/20 can be 4201da177e4SLinus Torvalds accessed in IO mode, and that the IO base address is correct. 4211da177e4SLinus Torvalds 4221da177e4SLinus Torvalds * Shared Memory Test 423714a4da4SMauro Carvalho Chehab 4241da177e4SLinus Torvalds The Shared Memory test insures the CS8900/20 can be accessed in memory 4251da177e4SLinus Torvalds mode and that the range of memory addresses assigned does not conflict 4261da177e4SLinus Torvalds with other devices in the system. 4271da177e4SLinus Torvalds 4281da177e4SLinus Torvalds * Interrupt Test 429714a4da4SMauro Carvalho Chehab 4301da177e4SLinus Torvalds The Interrupt test insures there are no conflicts with the assigned IRQ 4311da177e4SLinus Torvalds signal. 4321da177e4SLinus Torvalds 4331da177e4SLinus Torvalds * EEPROM Test 434714a4da4SMauro Carvalho Chehab 4351da177e4SLinus Torvalds The EEPROM test insures the EEPROM can be read. 4361da177e4SLinus Torvalds 4371da177e4SLinus Torvalds * Chip RAM Test 438714a4da4SMauro Carvalho Chehab 4391da177e4SLinus Torvalds The Chip RAM test insures the 4K of memory internal to the CS8900/20 is 4401da177e4SLinus Torvalds working properly. 4411da177e4SLinus Torvalds 4421da177e4SLinus Torvalds * Internal Loop-back Test 443714a4da4SMauro Carvalho Chehab 4441da177e4SLinus Torvalds The Internal Loop Back test insures the adapter's transmitter and 4451da177e4SLinus Torvalds receiver are operating properly. If this test fails, make sure the 4461da177e4SLinus Torvalds adapter's cable is connected to the network (check for LED activity for 4471da177e4SLinus Torvalds example). 4481da177e4SLinus Torvalds 4491da177e4SLinus Torvalds * Boot PROM Test 450714a4da4SMauro Carvalho Chehab 4511da177e4SLinus Torvalds The Boot PROM test insures the Boot PROM is present, and can be read. 4521da177e4SLinus Torvalds Failure indicates the Boot PROM was not successfully read due to a 4531da177e4SLinus Torvalds hardware problem or due to a conflicts on the Boot PROM address 4541da177e4SLinus Torvalds assignment. (Test only applies if the adapter is configured to use the 4551da177e4SLinus Torvalds Boot PROM option.) 4561da177e4SLinus Torvalds 4571da177e4SLinus TorvaldsFailure of a test item indicates a possible system resource conflict with 4581da177e4SLinus Torvaldsanother device on the ISA bus. In this case, you should use the Manual Setup 4591da177e4SLinus Torvaldsoption to reconfigure the adapter by selecting a different value for the system 4601da177e4SLinus Torvaldsresource that failed. 4611da177e4SLinus Torvalds 4621da177e4SLinus Torvalds 463714a4da4SMauro Carvalho Chehab5.2.2. Diagnostic Network Test 464714a4da4SMauro Carvalho Chehab^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 4651da177e4SLinus Torvalds 4661da177e4SLinus TorvaldsThe Diagnostic Network Test verifies a working network connection by 4671da177e4SLinus Torvaldstransferring data between two CS8900/20 adapters installed in different PCs 4681da177e4SLinus Torvaldson the same network. (Note: the diagnostic network test should not be run 4691da177e4SLinus Torvaldsbetween two nodes across a router.) 4701da177e4SLinus Torvalds 4711da177e4SLinus TorvaldsThis test requires that each of the two PCs have a CS8900/20-based adapter 4721da177e4SLinus Torvaldsinstalled and have the CS8900/20 Setup Utility running. The first PC is 4731da177e4SLinus Torvaldsconfigured as a Responder and the other PC is configured as an Initiator. 4741da177e4SLinus TorvaldsOnce the Initiator is started, it sends data frames to the Responder which 4751da177e4SLinus Torvaldsreturns the frames to the Initiator. 4761da177e4SLinus Torvalds 4771da177e4SLinus TorvaldsThe total number of frames received and transmitted are displayed on the 4781da177e4SLinus TorvaldsInitiator's display, along with a count of the number of frames received and 4791da177e4SLinus Torvaldstransmitted OK or in error. The test can be terminated anytime by the user at 4801da177e4SLinus Torvaldseither PC. 4811da177e4SLinus Torvalds 4821da177e4SLinus TorvaldsTo setup the Diagnostic Network Test: 4831da177e4SLinus Torvalds 484714a4da4SMauro Carvalho Chehab 1. Select a PC with a CS8900/20-based adapter and a known working network 4851da177e4SLinus Torvalds connection to act as the Responder. Run the CS8900/20 Setup Utility 4861da177e4SLinus Torvalds and select 'Diagnostics -> Network Test -> Responder' from the main 4871da177e4SLinus Torvalds menu. Hit ENTER to start the Responder. 4881da177e4SLinus Torvalds 489714a4da4SMauro Carvalho Chehab 2. Return to the PC with the CS8900/20-based adapter you want to test and 4901da177e4SLinus Torvalds start the CS8900/20 Setup Utility. 4911da177e4SLinus Torvalds 492714a4da4SMauro Carvalho Chehab 3. From the main menu, Select 'Diagnostic -> Network Test -> Initiator'. 4931da177e4SLinus Torvalds Hit ENTER to start the test. 4941da177e4SLinus Torvalds 4951da177e4SLinus TorvaldsYou may stop the test on the Initiator at any time while allowing the Responder 4961da177e4SLinus Torvaldsto continue running. In this manner, you can move to additional PCs and test 4971da177e4SLinus Torvaldsthem by starting the Initiator on another PC without having to stop/start the 4981da177e4SLinus TorvaldsResponder. 4991da177e4SLinus Torvalds 5001da177e4SLinus Torvalds 5011da177e4SLinus Torvalds 502714a4da4SMauro Carvalho Chehab5.3. Using the Adapter's LEDs 503714a4da4SMauro Carvalho Chehab----------------------------- 5041da177e4SLinus Torvalds 5051da177e4SLinus TorvaldsThe 2 and 3-media adapters have two LEDs visible on the back end of the board 5061da177e4SLinus Torvaldslocated near the 10Base-T connector. 5071da177e4SLinus Torvalds 5081da177e4SLinus TorvaldsLink Integrity LED: A "steady" ON of the green LED indicates a valid 10Base-T 5091da177e4SLinus Torvaldsconnection. (Only applies to 10Base-T. The green LED has no significance for 5101da177e4SLinus Torvaldsa 10Base-2 or AUI connection.) 5111da177e4SLinus Torvalds 5121da177e4SLinus TorvaldsTX/RX LED: The yellow LED lights briefly each time the adapter transmits or 5131da177e4SLinus Torvaldsreceives data. (The yellow LED will appear to "flicker" on a typical network.) 5141da177e4SLinus Torvalds 5151da177e4SLinus Torvalds 516714a4da4SMauro Carvalho Chehab5.4. Resolving I/O Conflicts 517714a4da4SMauro Carvalho Chehab---------------------------- 5181da177e4SLinus Torvalds 5191da177e4SLinus TorvaldsAn IO conflict occurs when two or more adapter use the same ISA resource (IO 5201da177e4SLinus Torvaldsaddress, memory address or IRQ). You can usually detect an IO conflict in one 5211da177e4SLinus Torvaldsof four ways after installing and or configuring the CS8900/20-based adapter: 5221da177e4SLinus Torvalds 523714a4da4SMauro Carvalho Chehab 1. The system does not boot properly (or at all). 5241da177e4SLinus Torvalds 525714a4da4SMauro Carvalho Chehab 2. The driver cannot communicate with the adapter, reporting an "Adapter 5261da177e4SLinus Torvalds not found" error message. 5271da177e4SLinus Torvalds 528714a4da4SMauro Carvalho Chehab 3. You cannot connect to the network or the driver will not load. 5291da177e4SLinus Torvalds 530714a4da4SMauro Carvalho Chehab 4. If you have configured the adapter to run in memory mode but the driver 5311da177e4SLinus Torvalds reports it is using IO mode when loading, this is an indication of a 5321da177e4SLinus Torvalds memory address conflict. 5331da177e4SLinus Torvalds 5341da177e4SLinus TorvaldsIf an IO conflict occurs, run the CS8900/20 Setup Utility and perform a 5351da177e4SLinus Torvaldsdiagnostic self-test. Normally, the ISA resource in conflict will fail the 5361da177e4SLinus Torvaldsself-test. If so, reconfigure the adapter selecting another choice for the 5371da177e4SLinus Torvaldsresource in conflict. Run the diagnostics again to check for further IO 5381da177e4SLinus Torvaldsconflicts. 5391da177e4SLinus Torvalds 5401da177e4SLinus TorvaldsIn some cases, such as when the PC will not boot, it may be necessary to remove 5411da177e4SLinus Torvaldsthe adapter and reconfigure it by installing it in another PC to run the 5421da177e4SLinus TorvaldsCS8900/20 Setup Utility. Once reinstalled in the target system, run the 5431da177e4SLinus Torvaldsdiagnostics self-test to ensure the new configuration is free of conflicts 5441da177e4SLinus Torvaldsbefore loading the driver again. 5451da177e4SLinus Torvalds 5461da177e4SLinus TorvaldsWhen manually configuring the adapter, keep in mind the typical ISA system 5471da177e4SLinus Torvaldsresource usage as indicated in the tables below. 5481da177e4SLinus Torvalds 549714a4da4SMauro Carvalho Chehab:: 550714a4da4SMauro Carvalho Chehab 5511da177e4SLinus Torvalds I/O Address Device IRQ Device 5521da177e4SLinus Torvalds ----------- -------- --- -------- 5531da177e4SLinus Torvalds 200-20F Game I/O adapter 3 COM2, Bus Mouse 5541da177e4SLinus Torvalds 230-23F Bus Mouse 4 COM1 5551da177e4SLinus Torvalds 270-27F LPT3: third parallel port 5 LPT2 5561da177e4SLinus Torvalds 2F0-2FF COM2: second serial port 6 Floppy Disk controller 5571da177e4SLinus Torvalds 320-32F Fixed disk controller 7 LPT1 5581da177e4SLinus Torvalds 8 Real-time Clock 5591da177e4SLinus Torvalds 9 EGA/VGA display adapter 5601da177e4SLinus Torvalds 12 Mouse (PS/2) 5611da177e4SLinus Torvalds Memory Address Device 13 Math Coprocessor 5621da177e4SLinus Torvalds -------------- --------------------- 14 Hard Disk controller 5635d3f083dSMatt LaPlante A000-BFFF EGA Graphics Adapter 5645d3f083dSMatt LaPlante A000-C7FF VGA Graphics Adapter 5651da177e4SLinus Torvalds B000-BFFF Mono Graphics Adapter 5661da177e4SLinus Torvalds B800-BFFF Color Graphics Adapter 5671da177e4SLinus Torvalds E000-FFFF AT BIOS 5681da177e4SLinus Torvalds 5691da177e4SLinus Torvalds 5701da177e4SLinus Torvalds 5711da177e4SLinus Torvalds 572714a4da4SMauro Carvalho Chehab6. Technical Support 573714a4da4SMauro Carvalho Chehab==================== 5741da177e4SLinus Torvalds 575714a4da4SMauro Carvalho Chehab6.1. Contacting Cirrus Logic's Technical Support 576714a4da4SMauro Carvalho Chehab------------------------------------------------ 5771da177e4SLinus Torvalds 578714a4da4SMauro Carvalho ChehabCirrus Logic's CS89XX Technical Application Support can be reached at:: 5791da177e4SLinus Torvalds 5801da177e4SLinus Torvalds Telephone :(800) 888-5016 (from inside U.S. and Canada) 5811da177e4SLinus Torvalds :(512) 442-7555 (from outside the U.S. and Canada) 5821da177e4SLinus Torvalds Fax :(512) 912-3871 5831da177e4SLinus Torvalds Email :ethernet@crystal.cirrus.com 5841da177e4SLinus Torvalds WWW :http://www.cirrus.com 5851da177e4SLinus Torvalds 5861da177e4SLinus Torvalds 587714a4da4SMauro Carvalho Chehab6.2. Information Required before Contacting Technical Support 588714a4da4SMauro Carvalho Chehab------------------------------------------------------------- 5891da177e4SLinus Torvalds 5901da177e4SLinus TorvaldsBefore contacting Cirrus Logic for technical support, be prepared to provide as 5911da177e4SLinus TorvaldsMuch of the following information as possible. 5921da177e4SLinus Torvalds 5931da177e4SLinus Torvalds1.) Adapter type (CRD8900, CDB8900, CDB8920, etc.) 5941da177e4SLinus Torvalds 5951da177e4SLinus Torvalds2.) Adapter configuration 5961da177e4SLinus Torvalds 5971da177e4SLinus Torvalds * IO Base, Memory Base, IO or memory mode enabled, IRQ, DMA channel 5981da177e4SLinus Torvalds * Plug and Play enabled/disabled (CS8920-based adapters only) 5991da177e4SLinus Torvalds * Configured for media auto-detect or specific media type (which type). 6001da177e4SLinus Torvalds 6011da177e4SLinus Torvalds3.) PC System's Configuration 6021da177e4SLinus Torvalds 6031da177e4SLinus Torvalds * Plug and Play system (yes/no) 6041da177e4SLinus Torvalds * BIOS (make and version) 6051da177e4SLinus Torvalds * System make and model 6061da177e4SLinus Torvalds * CPU (type and speed) 6071da177e4SLinus Torvalds * System RAM 6081da177e4SLinus Torvalds * SCSI Adapter 6091da177e4SLinus Torvalds 6101da177e4SLinus Torvalds4.) Software 6111da177e4SLinus Torvalds 6121da177e4SLinus Torvalds * CS89XX driver and version 6131da177e4SLinus Torvalds * Your network operating system and version 6141da177e4SLinus Torvalds * Your system's OS version 6151da177e4SLinus Torvalds * Version of all protocol support files 6161da177e4SLinus Torvalds 6171da177e4SLinus Torvalds5.) Any Error Message displayed. 6181da177e4SLinus Torvalds 6191da177e4SLinus Torvalds 6201da177e4SLinus Torvalds 621714a4da4SMauro Carvalho Chehab6.3 Obtaining the Latest Driver Version 622714a4da4SMauro Carvalho Chehab--------------------------------------- 6231da177e4SLinus Torvalds 6241da177e4SLinus TorvaldsYou can obtain the latest CS89XX drivers and support software from Cirrus Logic's 6251da177e4SLinus TorvaldsWeb site. You can also contact Cirrus Logic's Technical Support (email: 6261da177e4SLinus Torvaldsethernet@crystal.cirrus.com) and request that you be registered for automatic 6271da177e4SLinus Torvaldssoftware-update notification. 6281da177e4SLinus Torvalds 6291da177e4SLinus TorvaldsCirrus Logic maintains a web page at http://www.cirrus.com with the 630670e9f34SPaolo Ornatilatest drivers and technical publications. 6311da177e4SLinus Torvalds 6321da177e4SLinus Torvalds 633714a4da4SMauro Carvalho Chehab6.4. Current maintainer 634714a4da4SMauro Carvalho Chehab----------------------- 6351da177e4SLinus Torvalds 6361da177e4SLinus TorvaldsIn February 2000 the maintenance of this driver was assumed by Andrew 637e1f8e874SFrancois CamiMorton. 6381da177e4SLinus Torvalds 6391da177e4SLinus Torvalds6.5 Kernel module parameters 640714a4da4SMauro Carvalho Chehab---------------------------- 6411da177e4SLinus Torvalds 6421da177e4SLinus TorvaldsFor use in embedded environments with no cs89x0 EEPROM, the kernel boot 643714a4da4SMauro Carvalho Chehabparameter ``cs89x0_media=`` has been implemented. Usage is:: 6441da177e4SLinus Torvalds 6451da177e4SLinus Torvalds cs89x0_media=rj45 or 6461da177e4SLinus Torvalds cs89x0_media=aui or 6471da177e4SLinus Torvalds cs89x0_media=bnc 648