4 .\" Copyright (c) 1993 Michael Haardt (michael@cantor.informatik.rwth-aachen.de)
5 .\" and 1994,1995, 1997 Alain Knaff (alain@linux.lu)
7 .\" This is free documentation; you can redistribute it and/or
8 .\" modify it under the terms of the GNU General Public License as
9 .\" published by the Free Software Foundation; either version 2 of
10 .\" the License, or (at your option) any later version.
12 .\" The GNU General Public License's references to "object code"
13 .\" and "executables" are to be interpreted as the output of any
14 .\" document formatting or typesetting system, including
15 .\" intermediate and printed output.
17 .\" This manual is distributed in the hope that it will be useful,
18 .\" but WITHOUT ANY WARRANTY; without even the implied warranty of
19 .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 .\" GNU General Public License for more details.
22 .\" You should have received a copy of the GNU General Public
23 .\" License along with this manual; if not, write to the Free
24 .\" Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139,
28 .TH FD 4 "Jul 3, 1999" "Linux" "Special files"
32 fd \- floppy disk device
36 Floppy drives are block devices with major number 2. Typically they
37 are owned by root.floppy and have either mode 0660 (access checking via
38 group membership) or mode 0666 (everybody has access). For the
39 following devices, \fIn\fP is the drive number. It is 0 for the first
40 drive, 1 for the second etc. To get a minor number for a specific
41 drive connected to the first controller, add \fIn\fP to the minor base
42 number. If it is connected to the second controller, add \fIn\fP+128 to
43 the minor base number. \fBWarning: If you use formats with more tracks
44 than supported by your drive, you may damage it mechanically.\fP Trying
45 once if more tracks than the usual 40/80 are supported should not
46 damage it, but no warranty is given for that. Don't create device
47 entries for those formats to prevent their usage if you are not sure.
49 .\"{{{ drive independent
50 Drive independent device files which automatically detect the media
62 5.25 inch double density device files:
66 Name Capac. Cyl. Sect. Heads Base minor #
68 \fBfd\fP\fIn\fP\fBd360\fP 360K 40 9 2 4
73 5.25 inch high density device files:
77 Name Capac. Cyl. Sect. Heads Base minor #
79 \fBfd\fP\fIn\fP\fBh360\fP 360K 40 9 2 20
80 \fBfd\fP\fIn\fP\fBh410\fP 410K 41 10 2 48
81 \fBfd\fP\fIn\fP\fBh420\fP 420K 42 10 2 64
82 \fBfd\fP\fIn\fP\fBh720\fP 720K 80 9 2 24
83 \fBfd\fP\fIn\fP\fBh880\fP 880K 80 11 2 80
84 \fBfd\fP\fIn\fP\fBh1200\fP 1200K 80 15 2 8
85 \fBfd\fP\fIn\fP\fBh1440\fP 1440K 80 18 2 40
86 \fBfd\fP\fIn\fP\fBh1476\fP 1476K 82 18 2 56
87 \fBfd\fP\fIn\fP\fBh1494\fP 1494K 83 18 2 72
88 \fBfd\fP\fIn\fP\fBh1600\fP 1600K 80 20 2 92
93 3.5 inch double density device files:
97 Name Capac. Cyl. Sect. Heads Base minor #
99 \fBfd\fP\fIn\fP\fBu360\fP 360K 80 9 1 12
100 \fBfd\fP\fIn\fP\fBu720\fP 720K 80 9 2 16
101 \fBfd\fP\fIn\fP\fBu800\fP 800K 80 10 2 120
102 \fBfd\fP\fIn\fP\fBu1040\fP 1040K 80 13 2 84
103 \fBfd\fP\fIn\fP\fBu1120\fP 1120K 80 14 2 88
108 3.5 inch high density device files:
112 Name Capac. Cyl. Sect. Heads Base minor #
114 \fBfd\fP\fIn\fP\fBu360\fP 360K 40 9 2 12
115 \fBfd\fP\fIn\fP\fBu720\fP 720K 80 9 2 16
116 \fBfd\fP\fIn\fP\fBu820\fP 820K 82 10 2 52
117 \fBfd\fP\fIn\fP\fBu830\fP 830K 83 10 2 68
118 \fBfd\fP\fIn\fP\fBu1440\fP 1440K 80 18 2 28
119 \fBfd\fP\fIn\fP\fBu1600\fP 1600K 80 20 2 124
120 \fBfd\fP\fIn\fP\fBu1680\fP 1680K 80 21 2 44
121 \fBfd\fP\fIn\fP\fBu1722\fP 1722K 82 21 2 60
122 \fBfd\fP\fIn\fP\fBu1743\fP 1743K 83 21 2 76
123 \fBfd\fP\fIn\fP\fBu1760\fP 1760K 80 22 2 96
124 \fBfd\fP\fIn\fP\fBu1840\fP 1840K 80 23 2 116
125 \fBfd\fP\fIn\fP\fBu1920\fP 1920K 80 24 2 100
130 3.5 inch extra density device files:
134 Name Capac. Cyl. Sect. Heads Base minor #
136 \fBfd\fP\fIn\fP\fBu2880\fP 2880K 80 36 2 32
137 \fBfd\fP\fIn\fP\fBu3200\fP 3200K 80 40 2 104
138 \fBfd\fP\fIn\fP\fBu3520\fP 3520K 80 44 2 108
139 \fBfd\fP\fIn\fP\fBu3840\fP 3840K 80 48 2 112
145 \fBfd\fP special files access the floppy disk drives in raw mode.
148 calls are supported by \fBfd\fP devices:
151 clears the media information of a drive (geometry of disk in drive).
155 sets the media information of a drive. The media information will be
156 lost when the media is changed.
159 sets the media information of a drive (geometry of disk in drive). The
160 media information will not be lost when the media is changed. This
161 will disable autodetection. In order to re-enable autodetection, you
162 have to issue an \fBFDCLRPRM\fP .
165 .IP \fBFDGETDRVTYP\fP
166 returns the type of a drive (name parameter). For formats which work
167 in several drive types, \fBFDGETDRVTYP\fP returns a name which is
168 appropriate for the oldest drive type which supports this format.
172 invalidates the buffer cache for the given drive.
175 .IP \fBFDSETMAXERRS\fP
176 sets the error thresholds for reporting errors, aborting the operation,
177 recalibrating, resetting, and reading sector by sector.
180 .IP \fBFDSETMAXERRS\fP
181 gets the current error thresholds.
184 .IP \fBFDGETDRVTYP\fP
185 gets the internal name of the drive.
188 .IP \fBFDWERRORCLR\fP
189 clears the write error statistics.
192 .IP \fBFDWERRORGET\fP
193 reads the write error statistics. These include the total number of
194 write errors, the location and disk of the first write error, and the
195 location and disk of the last write error. Disks are identified by a
196 generation number which is incremented at (almost) each disk change.
200 Switch the drive motor off for a few microseconds. This might be
201 needed in order to access a disk whose sectors are too close together.
204 .IP \fBFDSETDRVPRM\fP
205 sets various drive parameters.
208 .IP \fBFDGETDRVPRM\fP
209 reads these parameters back.
212 .IP \fBFDGETDRVSTAT\fP
213 gets the cached drive state (disk changed, write protected et al.)
216 .IP \fBFDPOLLDRVSTAT\fP
217 polls the drive and return its state.
220 .IP \fBFDGETFDCSTAT\fP
221 gets the floppy controller state.
225 resets the floppy controller under certain conditions.
229 sends a raw command to the floppy controller.
232 For more precise information, consult also the <linux/fd.h> and
233 <linux/fdreg.h> include files, as well as the manual page for
238 The various formats allow to read and write many types of disks.
239 However, if a floppy is formatted with a too small inter sector gap,
240 performance may drop, up to needing a few seconds to access an entire
241 track. To prevent this, use interleaved formats. It is not possible to
242 read floppies which are formatted using GCR (group code recording),
243 which is used by Apple II and Macintosh computers (800k disks).
244 Reading floppies which are hard sectored (one hole per sector, with
245 the index hole being a little skewed) is not supported. This used to
246 be common with older 8 inch floppies.
254 Alain Knaff (Alain@linux.lu), David Niemi
255 (niemidc@tux.org), Bill Broadhurst (bbroad@netcom.com).
259 .BR floppycontrol (1),