It is currently Tue, 17 May 2022 03:10:57 GMT



 
Author Message
 Linux SCSI HOWTO (part 1/2)
Archive-name: linux/howto/scsi/part1
Last-modified: 12 Sep 95

-----BEGIN PGP SIGNED MESSAGE-----

*** The Linux SCSI HOWTO is posted automatically by the Linux
*** HOWTO coordinator, Greg Hankins <gr...@sunsite.unc.edu>.  Please
*** direct any comments or questions about this HOWTO to the author,
*** Drew Eckhardt <d...@PoohSticks.ORG>.

- --- BEGIN Linux SCSI HOWTO part 1/2 ---

Archive-name: linux/howto/scsi
Last-modified: 23 Jul 1995
Version: 2.17

Copyright 1994, 1995, Drew Eckhardt

    This documentation is free documentation; you can redistribute it and/or
    modify it under the terms of the GNU General Public License as published by
    the Free Software Foundation; either version 2 of the License, or
    (at your option) any later version.

    This documentation is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this documentation; if not, write to the Free Software
    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.

That said, I'd appreciate it if people would ask me <d...@PoohSticks.ORG>
if there's a newer version available before they publish it.  When people
publish outdated versions, I get questions from users that are answered
in newer versions, and it reflects poorly on the publisher.  I'd also prefer
that all references to free distribution sites, and possibly competing
distributions/products be left intact.  

IMPORTANT :

BUG REPORTS WHICH FAIL TO FOLLOW THE PROCEDURE OUTLINED IN SECTION 2 WILL
BE IGNORED.  

This HOWTO covers the Linux SCSI subsystem, as implemented in Linux
kernel revision 1.2.10 and newer alpha code.  Earlier revisions of the
SCSI code are _unsupported_, and may differ significantly in terms of the
drivers implemented, performance, and options available.

For additional information, you may wish to join the linux-scsi mailing list
by mailing majord...@vger.rutgers.edu with the line

        subscribe linux-scsi

in the text.  You can unsubscribe by sending mail to the same address and
including

        unsubscribe linux-scsi

in the text.

I'm aware that this document isn't the most user-friendly,
and that there may be inaccuracies and oversights.  If
you have constructive comments on how to rectify the situation
you're free to mail me about it.

Table of contents
Section 1                       Common Problems
    Section 1.1                 General Flakiness
    Section 1.2                 The kernel command line
    Section 1.3                 A SCSI device shows up at all possible IDs
    Section 1.4                 A SCSI device shows up at all possible LUNs
    Section 1.5                 You get sense errors when you know the
                                    devices are error free
    Section 1.6                 A kernel configured with networking does
                                    not work.
    Section 1.7                 Device detected, but unable to access.
    Section 1.8                 Sometimes the scsi subsystem locks up
                                    completely.
    Section 1.9                 Configuring and building the kernel
    Section 1.10                LUNS other than 0 don't work

Section 2                       Reporting Bugs
    Section 2.1                 Capturing messages
    Section 2.2                 Locating the source of a panic()

Section 3                       Modules
    Section 3.1                 General information.
    Section 3.2                 Status of modules under 1.2 kernels.
    Section 3.3                 Status of modules under 1.3 kernels.

Section 4                       Hosts
    Section 4.1                 Supported and Unsupported Hardware
    Section 4.1.1               Multiple host adapters
    Section 4.2                 Common Problems
    Section 4.3                 Adaptec 152x, 151x, Sound Blaster 16 SCSI,
                                    SCSI Pro, Gigabyte, and other AIC
                                    6260/6360 based products (Standard)
    Section 4.4                 Adaptec 154x, AMI FastDisk VLB,
                                    Buslogic, DTC 329x (Standard)  
    Section 4.5                 Adaptec 174x (Standard)
    Section 4.6                 Adaptec 274x, 284x (Standard), 294x (ALPHA)
    Section 4.7                 Allways IN2000 (ALPHA)
    Section 4.8                 EATA: DPT Smartcache, Smartcache Plus,
                                    Smartcache III (Standard)
    Section 4.9                 Future Domain 16x0 with TMC-1800, TMC-18C30,
                                    TMC-18C50, or TMC-36C70 chip (Standard)
    Section 4.10                Generic NCR5380 / T130B (Standard)
    Section 4.11                NCR53c8xx rel5 (Standard), rel10+ (ALPHA)
    Section 4.12                Seagate ST0x/Future Domain TMC-8xx/TMC-9xx
                                    (Standard)
    Section 4.13                PAS16 (Standard)
    Section 4.14                Trantor T128/T128F/T228 (Standard)
    Section 4.15                Ultrastor 14f, 24f,  34f (Standard)
    Section 4.16                Western Digital 7000 (Standard)
    Section 4.17                AM53/79C974 (ALPHA)
    Section 4.18                qlogic (STANDARD)

Section 5                       Disks
    Section 5.1                 Supported and Unsupported Hardware
    Section 5.2                 Common Problems
    Section 5.3                 Device Files
    Section 5.4                 Partitioning
    Section 5.5                 Disk Geometry

Section 6                       CD ROMs
    Section 6.1                 Supported and Unsupported Hardware
    Section 6.2                 Common Problems
    Section 6.3                 Device Files

Section 7                       Tapes
    Section 7.1                 Supported and Unsupported Hardware
    Section 7.2                 Common Problems
    Section 7.3                 Device Files

Section 8                       Generic
    Section 8.1                 Supported and Unsupported Hardware
    Section 8.2                 Common Problems
    Section 8.3                 Device Files

Section 9                       Buyers' Guide
    Section 9.1                 Transfer types
    Section 9.2                 Scatter/gather
    Section 9.3                 Mailbox vs. non-mailbox
    Section 9.4                 Bus types
    Section 9.5                 Multiple devices
    Section 9.6                 SCSI-I, SCSI-II, FAST and WIDE options, etc.
    Section 9.7                 Driver feature comparison
    Section 9.8                 Board comparison
    Section 9.9                 Summary

Section 10
    Section 10.1                Assignment of minor numbers.

Section 1 : Common Problems

This section lists some of the common problems that people
have.  If there is not anything here that answers your questions, you
should also consult the sections for your host adapter and the devices
in that are giving you problems.

Section 1.1 : General Flakiness
        If you experience random errors, the most likely causes are
        cabling and termination problems.

        Some products, such as those built arround the newer NCR
        chips, feature digital filtering and active signal negation,
        and aren't very sensitive to cabling problems.

        Others, such as the Adaptec 154xC, 154xCF, and 274x, are _extremely_
        sensitive and may fail with cables that work with other systems.

        I reiterate : some host adapters are _extremely_ sensitive to
        cabling and termination problems and therefore, cabling and
        termination should be the first things checked when there are
        problems.

        To minimize your problems, you should use cables which

        1.  Claim SCSI-II compliance
        2.  Have a characteristic impedance of 132 ohms
        3.  All come from the same source to avoid impedance mismatches
        4.  Come from a reputable vendor such as Amphenol

        Termination power should be provided by _all_ devices on
        the SCSI bus, through a diode to prevent current backflow,
        so that sufficient power is available at the ends of the cable
        where it is needed.  To prevent damage if the bus is shorted,
        TERMPWR should be driven through a fuse or other current
        limiting device.

        If multiple devices, external cables, or FAST SCSI 2 are used,
        active or forced perfect termination should be used on both ends
        of the SCSI bus.

        See the Comp.Periphs.Scsi FAQ (available on tsx-11 in
        pub/linux/ALPHA/scsi) for more information about active
        termination.

Section 1.2 : The kernel command line

        Other parts of the documentation refer to a "kernel command line".  

        The kernel command line is a set of options you may specify
        from either the LILO : prompt after an immage name, or in the
        append field in your LILO configuration file (LILO .14
        and newer use /etc/lilo.conf, older versions use /etc/lilo/config).

        Boot your system with LILO, and hit one of the alt, control, or
        shift keys when it first comes up to get a prompt.  LILO
        should respond with

            :

        At this prompt, you can select a kernel image to boot, or list
        them with ?.  Ie

            :?

            ramdisk floppy harddisk

        To boot that kernel with the command line options you have
        selected, simply enter the name followed by a white space delimited
        list of options, terminating with a return.  

        Options take the form of

            variable=valuelist

        Where valuelist may be a single value or comma delimited list
        of values with no whitespace.  With the exception of root device,
        individual values are numbers, and may be specified in either
        decimal or hexadecimal.

        Ie, to boot linux with an Adaptec 1520 clone not recognized
        at bootup, you might type

            :floppy aha152x=0x340,11,7,1

        If you don't care to type all of this at boot time, it is also
        possible to use the LILO configuration file "append" option
        with LILO .13 and newer.

        Ie,
            append="aha152x=0x340,11,7,1"

Section 1.3 :  A SCSI device shows up at all possible IDs

        If this is the case, you have strapped the device at the same
        address as the controller (typically 7, although some boards
        use other addresses, with 6 being used by some Future Domain
        boards).

        Please change the jumper settings.

Section 1.4 :  A SCSI device shows up at all possible LUNs

        The device has buggy firmware.  

        As an interim sollution, you should try using the kernel
        command line option

            max_scsi_luns=1

        If that works, there is a list of buggy devices
        in the kernel sources in drivers/scsi/scsi.c in the variable
        blacklist.  Add your device to this list and mail the patch
        to Linus Torvalds <Linus.Torva...@cs.Helsinki.FI>.

Section 1.5 :  You get sense errors when you know the devices are error free

        Sometimes this is caused by bad cables or impropper termination.

        See Section 1.1 : General Flakiness

Section 1.6 :  A kernel configured with networking does not work.

        The auto-probe routines for many of the network drivers
        are not passive, and will interfere with operation with some
        of the SCSI drivers.
...

read more »



 Sat, 28 Feb 1998 03:00:00 GMT   
 Linux SCSI HOWTO (part 1/2)
Archive-name: linux/howto/scsi/part2
Last-modified: 12 Sep 95

-----BEGIN PGP SIGNED MESSAGE-----

*** The Linux SCSI HOWTO is posted automatically by the Linux
*** HOWTO coordinator, Greg Hankins <gr...@sunsite.unc.edu>.  Please
*** direct any comments or questions about this HOWTO to the author,
*** Drew Eckhardt <d...@PoohSticks.ORG>.

- --- BEGIN Linux SCSI HOWTO part 2/2 ---

Common Problems :

1.  Many people have encountered problems where the chip worked
        fine under DOS, but failed under Linux with a timeout on
        test 1 due to a lost interrupt.

        This is often due to a mismatch between the IRQ hardware
        jumper for a slot or mainboard device and the value set
        in the CMOS setup.  DOUBLE CHECK
                - The IRQ you are using is used only by your onboard NCR chip,
                  or the slot an NCR board is installed in
                - Any main board jumpers selecting the IRQ for the onboard
                  chip or slot match your CMOS setup.

        It may also be due to PCI INTB, INTC, or INTD being selected
        on a PCI board in a system which only supports PCI INTA.  If you
        are using an NCR board which has jumpers to select between PCI
        interrupt lines, make sure you are using INTA.

        Finally, PCI should be using level-sensitive rather
        than edge triggered interrupts.  Check that your board
        is jumpered for level-sensitive, and if that fails
        try edge-triggered because your system may be
        broken.

        This problem is especially common with Viglen some Viglen
        motherboards, where the mainboard IRQ jumper settings are
        NOT as documented in the manual.  I've been told that what
        claims to be IRQ5 is really IRQ9, your mileage will vary.

2.  Lockups / other problems occur when using an S3 928, or Tseng
        ET4000W32 PCI video board.

        There are hardware bugs in at least some revisions of these
        chips.  Don't use them.

3.  You get a message on boot up indicating that the I/O mapping
        was disabled because base address 0 bits 0..1 indicated a
        non I/O mapping

        This is due to a BIOS bug in some machines which results in
        dword reads of configuration regsisters returning the
        high and low 16 bit words swapped.

4.  Some systems have problems if PCI write posting, or CPU->
        PCI buffering are enabled.  If you have problems,
        disable these options.

5.  Some systems with the NCR SDMS software in an onboard BIOS

        ROM and in the system BIOS are unable to boot DOS.
        Disabling the image in one place should rectify this
        problem.

6.  If you encounter the message

        "scsi%d: IRQ0 not free, detaching"

        The NCR chip had a 0 stored in the PCI configuration register.  
        Either you have configuration problems (see Common Problem 1), or
        you have a defective mainboard BIOS.

        As a work arround, you could edit drivers/scsi/ncr53c7,8xx.c,
        and change pci_init() so that you have

                irq = my_irq;

        before
                return normal_init (tpnt, board, chip, (int) base,
                    (int) io_port, (int) irq, DMA_NONE, 1, bus, device_fn,
                    options);

7.  Some systems have hideous, broken, BIOS chips.  Don't
        make any bug reports until you've made sure you have
        the newest ROM from your vendor.

Notes:
1.  CONFIG_PCI must be set

Section 4.12 : Seagate ST0x/Future Domain TMC-8xx/TMC-9xx
Supported and Unsupported Configurations :
Base addresses : 0xc8000, 0xca000, 0xcc000, 0xce000, 0xdc000, 0xde000
IRQs : 3, 5
DMA channels : DMA is not used
IO : memory mapped

Autoprobe : probes for address only, IRQ is assumed to be 5,
        requires installed BIOS.

Autoprobe Override :
Compile time : Define OVERRIDE to be the base address, CONTROLLER to
FD or SEAGATE as appropriate, and IRQ to the IRQ.

kernel command line : st0x=address,irq or tmc8xx=address,irq (only works
        for .99.13b and newer)

Antiquity Problems, fix by upgrading :

1.  Versions prior to the one in the Linux .99.12 kernel had a problem
        handshaking with some slow devices, where

        This is what happens when you write data out to the bus

        1.  Write byte to data register, data register is asserted to bus
        2.  time_remaining = 12us
        3.  wait while time_remaining > 0 and REQ is not asserted
        4.  if time_remaining > 0, assert ACK
        5.  wait while time remaining > 0  and REQ is asserted
        6.  deassert ACK

        The problem was encountered in slow devices that do the command
        processing as they read the command, where the REQ/ACK handshake
        takes over 12us - REQ didn't go false when the driver expected it
        to, so the driver ended up sending multiple bytes of data for
        each REQ pulse.

2.  With Linux .99.12, a bug was introduced when I fixed the arbitration
        code, resulting in failed selections on some systems.  This was
        fixed in .99.13.

Common Problems :

1.  There are command timeouts when Linux attempts to read the partition
    table or do other disk access.

    The board ships with the defaults set up for MSDOS, ie interrupts
    are disabled.  To jumper the board for interrupts, on the Seagate
    use jumper W3 (ST01) or JP3 (ST02) and short pins F-G to select
    IRQ 5.

2.  The driver can't handle some devices, particularly cheap SCSI
    tapes and CDROMs.

    The Seagate ties the SCSI bus REQ/ACK handshaking into the PC bus
    IO CHANNEL READY and (optionally) 0WS signals.  Unfortunately, it
    doesn't tell you when the watchdog timer runs out, and you have
    no way of knowing for certain that REQ went low, and may end up
    seeing one REQ pulse as multiple REQ pulses.

    Dealing with this means using a tight loop to look for REQ to
    go low, with a timeout incase you don't catch the transition due
    to an interrupt, etc.  This results in a performance decrease, so it
    would be undesireable to apply this to all SCSI devices.  Instead,
    it is selected on a per-device basis with the "borken" field for
    the given SCSI device in the scsi_devices array.  If you run into
    problems, you should try adding your device to the list of
    devices for which borken is not reset to zero (currently,
    only the TENEX CDROM drives).

3.  A future domain board (specific examples include the 840,841,
    880, and 881) doesn't work.

    A few of the Future domain boards use the Seagate
    register mapping, and have the MSG and CD bits of the
    status register flipped.

    You should edit seagate.h, swapping the definitions for
    STAT_MSG and STAT_CD, and recompile the kernel with
    CONTROLLER defined to SEAGATE and an appropriate
    IRQ and OVERRIDE specified.

4.  When attempting to fdisk your drive, you get error messages
    indicating that the HDIO_REQ or HDIO_GETGEO ioctl failed,
    or

        You must set heads sectors and cylinders.
        You can do this from the extra functions menu.

    See Section 5.4 : Disks : Partitioning

5.  After manually specifying the drive geometry, subsequent
    attempts to read the partition table result in partition
    boundary not on a cylinder boundary, physical and logical
    boundaries don't match, etc. error messages.

    See Section 5.4 : Disks : Partitioning

6.  Some systems which worked prior to .99.13 fail with newer
    versions of Linux.  Older versions of Linux assigned the
    CONTROL and DATA registers in an order different than that
    outlined in the Seagate documentation, which broke on some
    systems.  Newer versions make the assignment in the correct
    way, but this breaks other systems.

    The code in seagate.c looks like this now :

    cli();
    DATA = (unsigned char) ((1 << target) | (controller_type == SEAGATE ? 0x80 : 0x40));
    CONTROL = BASE_CMD | CMD_DRVR_ENABLE | CMD_SEL |
            (reselect ? CMD_ATTN : 0);
    sti();

    Changing this to

    cli();
    CONTROL = BASE_CMD | CMD_DRVR_ENABLE | CMD_SEL |
            (reselect ? CMD_ATTN : 0);
    DATA = (unsigned char) ((1 << target) | (controller_type == SEAGATE ? 0x80 : 0x40));
    sti()

    may fix your problem.

Defines :

FAST or FAST32 will use blind transfers where possible

ARBITRATE will cause the host adapter to arbitrate for the
        bus for better SCSI-II compatability, rather than just
        waiting for BUS FREE and then doing its thing.  Should
        let us do one command per Lun when I integrate my
        reorganization changes into the distribution sources.

SLOW_HANDSHAKE will allow compatability with broken devices that don't
        handshake fast enough (ie, some CD ROM's) for the Seagate
        code.

SLOW_RATE=x, x some number will let you specify a default
        transfer rate if handshaking isn't working correctly.

Section 4.13 : PAS16 SCSI
Supported and Unsupported Configurations :
Ports : 0x388, 0x384, 0x38x, 0x288
IRQs : 10, 12, 14, 15
    IMPORTANT : IRQ MUST be different from the IRQ used for the sound
        portion of the board.
DMA is not used for the SCSI portion of the board
IO : port mapped

Autoprobe : does not require BIOS

Autoprobe Override :
Compile time : Define PAS16_OVERRIDE to be an array of port, irq
tupples.  Ie

#define PAS16_OVERRIDE {{0x388, 10}}

for a board at port 0x388, IRQ 10.

kernel command line :
pas16=port,irq

Defines :
AUTOSENSE - if defined, REQUEST SENSE will be performed automatically
for commands that return with a CHECK CONDITION status.

PSEUDO_DMA - enables PSEUDO-DMA hardware, should give a 3-4X performance
increase compared to polled I/O.

PARITY - enable parity checking.  Not supported

SCSI2 - enable support for SCSI-II tagged queueing.  Untested

UNSAFE - leave interrupts enabled during pseudo-DMA transfers.  You
         only really want to use this if you're having a problem with
         dropped characters during high speed communications, and even
         then, you're going to be better off twiddling with transfersize.

USLEEP - enable support for devices that don't disconnect.  Untested.

Common problems :

1.  Command timeouts, aborts, etc.

    You should install the NCR5380 patches that I posted to the net
    some time ago, which should be integrated into some future alpha
    release.  These patches fix a race condition in earlier NCR5380
    driver cores, as well as fixing support for
...

read more »



 Sat, 28 Feb 1998 03:00:00 GMT   
 
   [ 2 post ] 

Similar Threads

1. Linux SCSI HOWTO (part 1/3)

2. Linux SCSI HOWTO (part 1/3)

3. Linux SCSI HOWTO (part 1/3)

4. Linux SCSI HOWTO (part 2/3)

5. Linux SCSI HOWTO (part 1/3)

6. Linux SCSI HOWTO (part 1/2)

7. Linux SCSI HOWTO (part 2/2)

8. Linux SCSI HOWTO (part 1/3)

9. Linux SCSI HOWTO (part 1/3)

10. Linux SCSI HOWTO (part 1/2)


 
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software