NCR53C710 SCSI Driver

Updated March 4th 2002:   Driver disk for RedHat 7.2 added. Driver supports multiple controllers and auto-detection of EISA boards.
Updated May 6th 2001:   Driver disks for RedHat 7.0 and 7.1 added.
Updated August 21st 2000:   Driver now supports multiple controllers; I have updated the RedHat 6.2 boot disk with the new version.

    The BIOS on some older Compaq machines reports 16M of DRAM when they really have more. For 2.2 kernels that was overcome by appending "mem=64M" (for example) to the kernel boot parameters. For 2.4 kernels the syntax has changed such that you specify the size and address of the extra memory rather than total size. So, "mem=64M" under 2.2 becomes "mem=48M@16M" (assuming the BIOS reports 16M when you really have 64M).

The Driver:
    This page gives details of a Linux driver for the NCR53C710 SCSI chips found on many Intel based Compaq machines, and NCR 3430 systems. The driver needs some work in its error handling and auto-detect routines, but it should at least work.

There is already a driver in the kernel source tree for the 53c710, but unfortunately it will not work on Intel systems where the chip registers appear in the I/O address space, rather than in the memory address space.  Before I had an Intel machine with a 53c710, I hit a similar problem on a 68030 based VME card.  To overcome the problem I wrote this simple driver for the 53c710 (known as sim710).  The driver has been found to work on an NCR 3430 and Compaq machines (e.g. Compaq Proliant).

The driver is included in current 2.2 and 2.4 kernel sources, and to use it you simply need to answer 'Y' or 'M' to the new "Simple 53c710 SCSI support" config question. Some current distributions include the driver module, but there are problems in some cases, generally as a result of the sim710 module requiring parameters, and, in older versions of the driver, requiring a space in the parameter value. If you apply the latest patch below to your kernel source then the driver will accept any of ' ', ',' or '+' as a parameter seperator. Also, the driver will auto-detect the address and IRQ used, so it is generally not necessary to specify any parameters. Support for MCA based machines from NCR was added by Trent McNair.

Features of the driver are:

I now have a Compaq Proliant 2000, so I can work on the driver (thanks Chris!).  The machine has the 53c710 on the motherboard with CDROM and DAT drive, and a Smart2 RAID controller with five 1GB disks (currently configured as RAID5 giving a 4GB logical disk).  It also has a NetFlex-2 ethernet card, but as yet there doesn't seem to be a driver for that card - let me know if you know different. Thanks to Sean Jensen, I also have a Compaq 53c710 EISA card, so I can test this with multiple controllers.

To pass parameters at boot time use something like


and to pass parameters to insmod use something like

     sim710="addr:0x8000 irq:15"

Note The change of comma to space, and the addition of quotes. If the latest patch below is applied, then you can use '+' in the insmod parameters, and so do not need the quotes. Also with the latest patch you don't generally need to specify any parameters, as it will auto-detect them. Note autodetection is disabled if any addr: parameters are specified.

To specify multiple controllers, you would use a syntax such as

     sim710="addr:0x7000 irq:14 addr:0x9000 irq:15"

or simply


Controllers can share an IRQ.

When specifying parameters for multiple controllers, addr: must be the first parameter specified for each controller.

Driver options:
  • addr:0x9000
  • specifies the base address of the chip
  • irq:15
  • specifies the IRQ used by the chip (auto-detected if lastest patch applied)
  • debug:0xffff 
  • generates lots of output; the value is a bit mask see sim710.c for details
  • ignore:0x21
  • ignores specific SCSI IDs (IDs 5 and 0 in this example)
  • nodisc:0x40
  • prevents disconnect for certain IDs (ID 6 in this case)
  • noneg:0x03 
  • prevents (a)sync negotiation for certain IDs (0 and 1 in this case)

    Available patches:
    RedHat drivers disk for 53c710:

    These driver disks can be used to install on machines with 53c710 SCSI controllers (e.g. Compaq machines). You need to uncompress the file and then dump it on to a floppy. On a linux box that could be done as follows:

    gzip -d sim710.img.gz
    dd if=sim710.img of=/dev/fd0 bs=18k

    On a DOS box I guess you can use rawrite.exe, although I havn't tried.

    For RedHat 7.1 I installed with "linux expert text dd mem=48M@16M".
    Insert the driver disk when requested at the start of the install, and then go on to select the 53c710 driver as the SCSI module you want to load. You should not need to specify any module parameters; if you do need to, please note the CPQID fields reported by the driver when it starts up, and I'll add support for your card.

    Install up to the point where it is asking if you want to create a boot disk. Alt-F2 to a bash prompt, then, with the sim710 driver disk in the floppy drive:

    For RedHat 6.2:

    chroot /mnt/sysimage
    mount /dev/fd0 /mnt/floppy
    cp /mnt/floppy/sim710.o /lib/modules/2.2.14-5.0/scsi
    umount /mnt/floppy
    /sbin/mkinitrd -v -f /boot/initrd-2.2.14-5.0.img 2.2.14-5.0
    /sbin/lilo -v

    For RedHat 7.1:

    chroot /mnt/sysimage
    mount /dev/fd0 /mnt/floppy
    cp /mnt/floppy/sim710.o.i586 /lib/modules/2.4.2-2/kernel/drivers/scsi/sim710.o
    umount /mnt/floppy
    /sbin/mkinitrd -v -f /boot/initrd-2.4.2-2.img 2.4.2-2
    /sbin/lilo -v

    The above instructions are for installing RedHat 7.1 on a Pentium based system; for a 386 or 486 based system, you would cp /mnt/floppy/sim710.o.i386.

    For RedHat 7.2:

    chroot /mnt/sysimage /bin/bash
    mkdir /mnt/floppy
    mount /dev/fd0 /mnt/floppy
    cp /mnt/floppy/sim710.o.i386 /lib/modules/2.4.7-10/kernel/drivers/scsi/sim710.o
    umount /mnt/floppy
    /sbin/mkinitrd -v -f /boot/initrd-2.4.7-10.img 2.4.7-10
    Note, I used the grub bootloader, so there was no need to run lilo after updating the initrd. I specifically specified bash on the chroot command because without that I got some "humble shell" which hung when I first mounted the floppy. RedHat 7.2 installs an i386 kernel on 386, 486, and 586 systems, so I did need the .i386 module for my P66 based box.

    Then Alt-F1 and click YES to create a boot disk. On completing the install, your system should boot from the harddisk. You'll need to apply the relevant patch listed above if you want to build you own kernel.

    How I created the driver disk:

    Some people have asked how I created the driver disk. Put simply, I started from an existing RH driver disk, and replaced the driver module. In practice I had to figure out how the modules.cgz file on the disk was built, and I had to build the module with the right kernel version.

    For RedHat 6.2:
    You can edit include/linux/version.h and modify UTS_RELEASE to change the version. I built the module once as version "2.2.14-5.0BOOT", and once as "2.2.14-5.0". If you name those sim710.o.2.2.14-5.0BOOT and sim710.o.2.2.14-5.0, and make sure my existing driver disk image is available as sim710.img, then you can run the following script to recreate sim710.img with the new modules:

    rm -rf sim710.img.mountpoint
    rm -rf sim710.img.workdir
    mkdir sim710.img.mountpoint
    mkdir sim710.img.workdir
    mount -o loop sim710.img sim710.img.mountpoint
    cd sim710.img.workdir
    zcat ../sim710.img.mountpoint/modules.cgz | cpio -id
    cp ../sim710.o.2.2.14-5.0BOOT 2.2.14-5.0BOOT/sim710.o
    echo 2.2.14-5.0BOOT/sim710.o | cpio -o --format=crc | gzip -9 > ../sim710.img.mountpoint/modules.cgz
    cd ..
    cp sim710.o.2.2.14-5.0 sim710.img.mountpoint/sim710.o
    umount sim710.img.mountpoint
    rm -rf sim710.img.mountpoint
    rm -rf sim710.img.workdir

    For RedHat 7.1:
    This is an improvement over the above method. The RedHat kernel source includes the configs used to buidl the variosu kernels. When building the 2.4.2-2BOOT module, you need to edit the Makefile to add BOOT to the EXTRAVERSION field. Then for each build, I did "make mrproper", "cp configs/ .config", "make oldconfig && make dep && make bzImage && make modules". Then, having named the three sim710.o modules appropriately, I ran this script:

    # Create a RedHat driver disk for sim710.  Expects you to have three
    # versions of the module compiled against the relevant RedHat source
    # tree.  The modules are
    #	sim710.o-2.4.2-2BOOT		build with boot kernel config
    #	sim710.o-2.4.2.i386		build with i386 kernel config
    #	sim710.o-2.4.2.i586		built with i586 kernel config
    # "2.4.2-2" is the base kernel version, and should be set appropriately
    # below.
    rm -rf sim710.img.mountpoint
    rm -rf sim710.img.workdir
    mkdir sim710.img.mountpoint
    mkdir sim710.img.workdir
    dd if=/dev/zero of=sim710.img bs=1k count=128
    echo y | mke2fs -m 0 -N 32 sim710.img
    mount -o loop sim710.img sim710.img.mountpoint
    cd sim710.img.mountpoint
    rm -rf lost+found
    touch modules.dep
    touch pcitable
    echo "Version 0" > modinfo
    echo "sim710" >> modinfo
    echo "    scsi" >> modinfo
    echo "    \"53c710 driver for Compaq and NCR machines\"" >> modinfo
    echo "Supplemental Drivers" > rhdd-6.1
    cd ../sim710.img.workdir
    mkdir ${BASE}BOOT
    cp ../sim710.o-${BASE}BOOT ${BASE}BOOT/sim710.o
    echo ${BASE}BOOT/sim710.o | cpio -o --format=crc | gzip -9 > ../sim710.img.mountpoint/modules.cgz
    cd ..
    cp -f sim710.o-${BASE}.i386 sim710.img.mountpoint/sim710.o.i386
    cp -f sim710.o-${BASE}.i586 sim710.img.mountpoint/sim710.o.i586
    umount sim710.img.mountpoint
    rm -rf sim710.img.mountpoint
    rm -rf sim710.img.workdir

    For RedHat 7.2:
    I used the same process as for RedHat 7.1, except the kernel is 2.4.7-10, not 2.4.2-2.

    Updating the sim710 module in a pre-installed RedHat 6.2 system:

    If you have already installed RedHat 6.2 from an earler version of my driver disk, and now want to switch to the latest version of the driver, then you can proceed as follows:

    1. Grab the latest driver disk and write it to a floppy as explained above.
    2. Mount the floppy and copy off the sim710.o file, which is the new module.
    3. Copy the module to the right place: "cp sim710.o /lib/modules/2.2.14-5.0/scsi/sim710.o"
    4. Edit /etc/conf.modules to specify the new parameters for sim710. To add an extra controller, I changed this line to read "options sim710 sim710=addr:0x7000+addr:0x9000". Save the file.
    5. Make a new initial ramdisk: "/sbin/mkinitrd -v -f /boot/ 2.2.14-5.0"
    6. Edit /etc/lilo.conf to add a new entry for your modified configuration. The new entry is a copy of the existing one (the five or so lines starting with 'image='), but with the label value changed and the initrd value changed to our new ramdisk '/boot/'.
    7. Run "lilo -v"
    8. Reboot and select the new kernel at the lilo prompt.

    Other Useful Links:

    Tim Peeler has created boot disks, kernel rpms, etc. for RedHat 6.0 and Slackware here.

    Richard Black's site, here.

    Jean Philippe's site, here, or here.

    The compaqandlinux mail list, here for details.