URL
https://opencores.org/ocsvn/or1k_old/or1k_old/trunk
Subversion Repositories or1k_old
[/] [or1k_old/] [trunk/] [uclinux/] [uClinux-2.0.x/] [drivers/] [block/] [README.fd] - Rev 1782
Compare with Previous | Blame | View Log
This Readme file describes the floppy driver.
FAQ list:
=========
A FAQ list may be found in the fdutils package (see below), and also
at ftp.imag.fr:pub/Linux/ZLIBC/floppy/FAQ
Lilo config options (Thinkpad users, read this)
===============================================
The floppy driver is configured using the 'floppy=' option in
lilo. This option can be typed at the boot prompt, or entered in the
lilo configuration file.
Example: If your kernel is called linux-pre2.0.9, type the following line
at the lilo boot prompt (if you have a thinkpad):
linux-pre2.0.9 floppy=thinkpad
You may also enter the following line in /etc/lilo.conf, in the description
of linux-pre2.0.9:
append = "floppy=thinkpad"
Several floppy related options may be given, example:
linux-pre2.0.9 floppy=daring floppy=two_fdc
append = "floppy=daring floppy=two_fdc"
If you give options both in the lilo config file and on the boot
prompt, the option strings of both places are concatenated, the boot
prompt options coming last. That's why there are also options to
restore the default behavior.
If you use the floppy driver as a module, use the following syntax:
insmod floppy 'floppy="<options>"'
Example:
insmod floppy 'floppy="daring two_fdc"'
Note that in this case 'floppy=' should only be typed out once, and
not once for each option. You need at least modules-1.3.57 for this
method. However, the older environment variable based syntax is still
available:
(sh syntax): floppy="daring two_fdc" insmod floppy
(csh syntax): setenv floppy "daring two_fdc" ; insmod floppy
Some versions of insmod are buggy in one way or another. If you have
any problems (options not being passed correctly, segfaults during
insmod), first check whether there is a more recent version. If there
isn't, use the old method using environment variables.
The floppy related options include:
floppy=<mask>,allowed_drive_mask
Obsolete. Use the floppy=<drive>,<type>,cmos option instead
floppy=all_drives
Obsolete. Use the floppy=<drive>,<type>,cmos option instead
floppy=asus_pci
Sets the bit mask to allow only units 0 and 1. (The default)
floppy=daring
Tells the floppy driver that you have a well behaved floppy controller.
This allows more efficient and smoother operation, but may fail on
certain controllers. This may speed up certain operations.
floppy=0,daring
Tells the floppy driver that your floppy controller should be used
with caution.
floppy=one_fdc
Tells the floppy driver that you have only floppy controller (default)
floppy=two_fdc
floppy=<address>,two_fdc
Tells the floppy driver that you have two floppy controllers. The
second floppy controller is assumed to be at <address>. This
option is not needed if the second controller is at address
0x370, and if you use the 'cmos' option
floppy=thinkpad
Tells the floppy driver that you have a Thinkpad. Thinkpads use an
inverted convention for the disk change line.
floppy=0,thinkpad
Tells the floppy driver that you don't have a Thinkpad.
floppy=omnibook
floppy=nodma
Tells the floppy driver not to use Dma for data transfers.
This is needed on HP Omnibooks, which don't have a workable
DMA channel for the floppy driver. This option is also useful
if you frequently get "Unable to allocate DMA memory" messages.
Indeed, dma memory needs to be continuous in physical, and is
thus harder to find, whereas non-dma buffers may be allocated
in virtual memory. However, I advise against this if you have
an FDC without a FIFO (8272A or 82072). 82072A and later are
OK. You also need at least a 486 to use nodma.
If you use nodma mode, I suggest you also set the FIFO
threshold to 10 or lower, in order to limit the number of data
transfer interrupts.
floppy=dma
Tells the floppy driver that a workable DMA channel is available
(the default).
floppy=nofifo
Disables the FIFO entirely. This is needed if you get "Bus
master arbitration error" messages from your ethernet card (or
from other devices) while accessing the floppy.
floppy=fifo
Enables the FIFO (default)
floppy=<threshold>,fifo_depth
Sets the FIFO threshold. This is mostly relevant in DMA
mode. If this is higher, the floppy driver tolerates more
interrupt latency, but it triggers more interrupts (i.e. it
imposes more load on the rest of the system). If this is
lower, the interrupt latency should be lower too (faster
processor). The benefit of a lower threshold is less
interrupts.
To tune the fifo threshold, switch on over/underrun messages
using 'floppycontrol --messages'. Then access a floppy
disk. If you get a huge amount of "Over/Underrun - retrying"
messages, then the fifo threshold is too low. Try with a
higher value, until you only get an occasional Over/Underrun.
It is a good idea to compile the floppy driver as a module
when doing this tuning. Indeed, it allows to try different
fifo values without rebooting the machine for each test. Note
that you need to do 'floppycontrol --messages' every time you
re-insert the module.
Usually, tuning the fifo threshold should not be needed, as
the default (0xa) is reasonable.
floppy=<drive>,<type>,cmos
Sets the CMOS type of <drive> to <type>. This is mandatory if
you have more than two floppy drives (only two can be
described in the physical CMOS), or if your BIOS uses
non-standard CMOS types. The CMOS types are:
0 - Use the value of the physical CMOS
1 - 5 1/4 DD
2 - 5 1/4 HD
3 - 3 1/2 DD
4 - 3 1/2 HD
5 - 3 1/2 ED
6 - 3 1/2 ED
16 - unknown or not installed
(Note: there are two valid types for ED drives. This is because 5 was
initially chosen to represent floppy *tapes*, and 6 for ED drives.
AMI ignored this, and used 5 for ED drives. That's why the floppy
driver handles both)
floppy=unexpected_interrupts
Print a warning message when an unexpected interrupt is received
(default behavior)
floppy=no_unexpected_interrupts
floppy=L40SX
Don't print a message when an unexpected interrupt is received. This
is needed on IBM L40SX laptops in certain video modes. (There seems
to be an interaction between video and floppy. The unexpected interrupts
only affect performance, and can safely be ignored.)
Supporting utilities and additional documentation:
==================================================
Additional parameters of the floppy driver can be configured at run
time. Utilities which do this can be found in the fdutils
package. This package also contains a new version of mtools which
allows to access high capacity disks (up to 1992K on a high density 3
1/2 disk!). It also contains additional documentation about the floppy
driver. It can be found at:
ftp.imag.fr:pub/Linux/ZLIBC/fdutils/fdutils-4.1.src.tar.gz
sunsite.unc.edu:/pub/Linux/system/Misc/fdutils-4.1.src.tar.gz
tsx-11.mit.edu:/pub/linux/sources/sbin/fdutils-4.1.src.tar.gz
Alpha patches to these utilities are at:
ftp.imag.fr:pub/Linux/ZLIBC/fdutils/ALPHA
All patches contained in this directory are directly against the base
version, i.e. DON'T APPLY THEM ON TOP OF EACH OTHER. Only apply the
most recent one.
Alpha patches for the floppy driver:
====================================
You may find ALPHA patches of the driver itself in
ftp.imag.fr:pub/Linux/ZLIBC/floppy/ALPHA. These patches are named
fdp<kernel-version>-<day><month>.diff.gz
WARNING: These _are_ ALPHA, and may introduce new problems! Some
problems may only show up on certain hardware, or when trying weirdo
things. So don't be misled by people claiming they are stable and
should really be BETA. What works for one person, may not work for
somebody else at all. This directory contains a RELEASES file
describing the features of some of these patches.
If after some testing these patches prove to be sufficiently stable,
they'll move into ftp.imag.fr:pub/Linux/ZLIBC/floppy/BETA.
You may find quick&dirty fixes to the driver in
ftp.imag.fr:pub/Linux/ZLIBC/QDF. These patches are named
fdp<kernel-version>-<day><month>.diff
These patches fix only the most obvious problems, or provide trivial
enhancements. The main objective is to keep these patches small and
local, in order to keep the probability of introducing new problems as
small as possible. However, they may not attack the root of the
problem but only cure the symptoms. This directory contains a RELEASES
file describing the features of these patches.
The ALPHA, BETA and QDF directories are removed, and replaced by a
README file when they get empty due to integration of the patches into
the stock kernel. You may still find patches to old kernels in
ftp.imag.fr:pub/Linux/ZLIBC/obsolete
Reporting problems about the floppy driver
==========================================
If you have a question or a bug report about the floppy driver, mail
me at Alain.Knaff@imag.fr. If you post to the news, use preferably one
of the groups comp.os.linux.help (for questions) or
comp.os.linux.hardware (for bug reports). As the volume in these
groups is rather high, be sure to include the word "floppy" (or
"FLOPPY") in the subject line.
Be sure to read the FAQ before mailing/posting any bug reports!
Alain