1=============
2Floppy Driver
3=============
4
5FAQ list:
6=========
7
8A FAQ list may be found in the fdutils package (see below), and also
9at <http://fdutils.linux.lu/faq.html>.
10
11
12LILO configuration options (Thinkpad users, read this)
13======================================================
14
15The floppy driver is configured using the 'floppy=' option in
16lilo. This option can be typed at the boot prompt, or entered in the
17lilo configuration file.
18
19Example: If your kernel is called linux-2.6.9, type the following line
20at the lilo boot prompt (if you have a thinkpad)::
21
22 linux-2.6.9 floppy=thinkpad
23
24You may also enter the following line in /etc/lilo.conf, in the description
25of linux-2.6.9::
26
27 append = "floppy=thinkpad"
28
29Several floppy related options may be given, example::
30
31 linux-2.6.9 floppy=daring floppy=two_fdc
32 append = "floppy=daring floppy=two_fdc"
33
34If you give options both in the lilo config file and on the boot
35prompt, the option strings of both places are concatenated, the boot
36prompt options coming last. That's why there are also options to
37restore the default behavior.
38
39
40Module configuration options
41============================
42
43If you use the floppy driver as a module, use the following syntax::
44
45	modprobe floppy floppy="<options>"
46
47Example::
48
49	modprobe floppy floppy="omnibook messages"
50
51If you need certain options enabled every time you load the floppy driver,
52you can put::
53
54	options floppy floppy="omnibook messages"
55
56in a configuration file in /etc/modprobe.d/.
57
58
59The floppy driver related options are:
60
61 floppy=asus_pci
62	Sets the bit mask to allow only units 0 and 1. (default)
63
64 floppy=daring
65	Tells the floppy driver that you have a well behaved floppy controller.
66	This allows more efficient and smoother operation, but may fail on
67	certain controllers. This may speed up certain operations.
68
69 floppy=0,daring
70	Tells the floppy driver that your floppy controller should be used
71	with caution.
72
73 floppy=one_fdc
74	Tells the floppy driver that you have only one floppy controller.
75	(default)
76
77 floppy=two_fdc / floppy=<address>,two_fdc
78	Tells the floppy driver that you have two floppy controllers.
79	The second floppy controller is assumed to be at <address>.
80	This option is not needed if the second controller is at address
81	0x370, and if you use the 'cmos' option.
82
83 floppy=thinkpad
84	Tells the floppy driver that you have a Thinkpad. Thinkpads use an
85	inverted convention for the disk change line.
86
87 floppy=0,thinkpad
88	Tells the floppy driver that you don't have a Thinkpad.
89
90 floppy=omnibook / floppy=nodma
91	Tells the floppy driver not to use Dma for data transfers.
92	This is needed on HP Omnibooks, which don't have a workable
93	DMA channel for the floppy driver. This option is also useful
94	if you frequently get "Unable to allocate DMA memory" messages.
95	Indeed, dma memory needs to be continuous in physical memory,
96	and is thus harder to find, whereas non-dma buffers may be
97	allocated in virtual memory. However, I advise against this if
98	you have an FDC without a FIFO (8272A or 82072). 82072A and
99	later are OK. You also need at least a 486 to use nodma.
100	If you use nodma mode, I suggest you also set the FIFO
101	threshold to 10 or lower, in order to limit the number of data
102	transfer interrupts.
103
104	If you have a FIFO-able FDC, the floppy driver automatically
105	falls back on non DMA mode if no DMA-able memory can be found.
106	If you want to avoid this, explicitly ask for 'yesdma'.
107
108 floppy=yesdma
109	Tells the floppy driver that a workable DMA channel is available.
110	(default)
111
112 floppy=nofifo
113	Disables the FIFO entirely. This is needed if you get "Bus
114	master arbitration error" messages from your Ethernet card (or
115	from other devices) while accessing the floppy.
116
117 floppy=usefifo
118	Enables the FIFO. (default)
119
120 floppy=<threshold>,fifo_depth
121	Sets the FIFO threshold. This is mostly relevant in DMA
122	mode. If this is higher, the floppy driver tolerates more
123	interrupt latency, but it triggers more interrupts (i.e. it
124	imposes more load on the rest of the system). If this is
125	lower, the interrupt latency should be lower too (faster
126	processor). The benefit of a lower threshold is less
127	interrupts.
128
129	To tune the fifo threshold, switch on over/underrun messages
130	using 'floppycontrol --messages'. Then access a floppy
131	disk. If you get a huge amount of "Over/Underrun - retrying"
132	messages, then the fifo threshold is too low. Try with a
133	higher value, until you only get an occasional Over/Underrun.
134	It is a good idea to compile the floppy driver as a module
135	when doing this tuning. Indeed, it allows to try different
136	fifo values without rebooting the machine for each test. Note
137	that you need to do 'floppycontrol --messages' every time you
138	re-insert the module.
139
140	Usually, tuning the fifo threshold should not be needed, as
141	the default (0xa) is reasonable.
142
143 floppy=<drive>,<type>,cmos
144	Sets the CMOS type of <drive> to <type>. This is mandatory if
145	you have more than two floppy drives (only two can be
146	described in the physical CMOS), or if your BIOS uses
147	non-standard CMOS types. The CMOS types are:
148
149	       ==  ==================================
150		0  Use the value of the physical CMOS
151		1  5 1/4 DD
152		2  5 1/4 HD
153		3  3 1/2 DD
154		4  3 1/2 HD
155		5  3 1/2 ED
156		6  3 1/2 ED
157	       16  unknown or not installed
158	       ==  ==================================
159
160	(Note: there are two valid types for ED drives. This is because 5 was
161	initially chosen to represent floppy *tapes*, and 6 for ED drives.
162	AMI ignored this, and used 5 for ED drives. That's why the floppy
163	driver handles both.)
164
165 floppy=unexpected_interrupts
166	Print a warning message when an unexpected interrupt is received.
167	(default)
168
169 floppy=no_unexpected_interrupts / floppy=L40SX
170	Don't print a message when an unexpected interrupt is received. This
171	is needed on IBM L40SX laptops in certain video modes. (There seems
172	to be an interaction between video and floppy. The unexpected
173	interrupts affect only performance, and can be safely ignored.)
174
175 floppy=broken_dcl
176	Don't use the disk change line, but assume that the disk was
177	changed whenever the device node is reopened. Needed on some
178	boxes where the disk change line is broken or unsupported.
179	This should be regarded as a stopgap measure, indeed it makes
180	floppy operation less efficient due to unneeded cache
181	flushings, and slightly more unreliable. Please verify your
182	cable, connection and jumper settings if you have any DCL
183	problems. However, some older drives, and also some laptops
184	are known not to have a DCL.
185
186 floppy=debug
187	Print debugging messages.
188
189 floppy=messages
190	Print informational messages for some operations (disk change
191	notifications, warnings about over and underruns, and about
192	autodetection).
193
194 floppy=silent_dcl_clear
195	Uses a less noisy way to clear the disk change line (which
196	doesn't involve seeks). Implied by 'daring' option.
197
198 floppy=<nr>,irq
199	Sets the floppy IRQ to <nr> instead of 6.
200
201 floppy=<nr>,dma
202	Sets the floppy DMA channel to <nr> instead of 2.
203
204 floppy=slow
205	Use PS/2 stepping rate::
206
207	   PS/2 floppies have much slower step rates than regular floppies.
208	   It's been recommended that take about 1/4 of the default speed
209	   in some more extreme cases.
210
211
212Supporting utilities and additional documentation:
213==================================================
214
215Additional parameters of the floppy driver can be configured at
216runtime. Utilities which do this can be found in the fdutils package.
217This package also contains a new version of mtools which allows to
218access high capacity disks (up to 1992K on a high density 3 1/2 disk!).
219It also contains additional documentation about the floppy driver.
220
221The latest version can be found at fdutils homepage:
222
223 http://fdutils.linux.lu
224
225The fdutils releases can be found at:
226
227 http://fdutils.linux.lu/download.html
228
229 http://www.tux.org/pub/knaff/fdutils/
230
231 ftp://metalab.unc.edu/pub/Linux/utils/disk-management/
232
233Reporting problems about the floppy driver
234==========================================
235
236If you have a question or a bug report about the floppy driver, mail
237me at Alain.Knaff@poboxes.com . If you post to Usenet, preferably use
238comp.os.linux.hardware. As the volume in these groups is rather high,
239be sure to include the word "floppy" (or "FLOPPY") in the subject
240line.  If the reported problem happens when mounting floppy disks, be
241sure to mention also the type of the filesystem in the subject line.
242
243Be sure to read the FAQ before mailing/posting any bug reports!
244
245Alain
246
247Changelog
248=========
249
25010-30-2004 :
251		Cleanup, updating, add reference to module configuration.
252		James Nelson <james4765@gmail.com>
253
2546-3-2000 :
255		Original Document
256