Debian Codegraph @

upstream/opensuse-tumbleweed/man4/fd.4

raw
1 '\" t
2 .\" Copyright 1994-1995, Alain Knaff <[email protected]>
3 .\" Copyright, the authors of the Linux man-pages project
4 .\"
5 .\" SPDX-License-Identifier: GPL-2.0-or-later
6 .\"
7 .TH fd 4 2026-02-08 "Linux man-pages (unreleased)"
8 .SH NAME
9 fd \- floppy disk device
10 .SH CONFIGURATION
11 Floppy drives are block devices with major number 2.
12 Typically they
13 are owned by
14 root:floppy
15 (i.e., user root, group floppy) and have
16 either mode 0660 (access checking via group membership) or mode 0666
17 (everybody has access).
18 The minor
19 numbers encode the device type, drive number, and controller number.
20 For each device type (that is, combination of density and track count)
21 there is a base minor number.
22 To this base number, add the drive's
23 number on its controller and 128 if the drive is on the secondary
24 controller.
25 In the following device tables,
26 .I n
27 represents the
28 drive number.
29 .P
30 .B Warning:
31 .B if you use formats with more tracks
32 .B than supported by your drive,
33 .B you may cause it mechanical damage.
34 Trying once if more tracks than the usual 40/80 are supported should not
35 damage it, but no warranty is given for that.
36 If you are not sure, don't create device
37 entries for those formats, so as to prevent their usage.
38 .P
39 Drive-independent device files which automatically detect the media
40 format and capacity:
41 .TS
42 l c
43 l c.
44 Name Base
45 minor #
46 _
47 \f[B]fd\f[]\f[I]n\f[] 0
48 .TE
49 .P
50 5.25 inch double-density device files:
51 .TS
52 lw(1i) l l l l c
53 lw(1i) c c c c c.
54 Name Capacity Cyl. Sect. Heads Base
55 KiB minor #
56 _
57 \f[B]fd\f[]\f[I]n\f[]\f[B]d360\f[] 360 40 9 2 4
58 .TE
59 .P
60 5.25 inch high-density device files:
61 .TS
62 lw(1i) l l l l c
63 lw(1i) c c c c c.
64 Name Capacity Cyl. Sect. Heads Base
65 KiB minor #
66 _
67 \f[B]fd\f[]\f[I]n\f[]\f[B]h360\f[] 360 40 9 2 20
68 \f[B]fd\f[]\f[I]n\f[]\f[B]h410\f[] 410 41 10 2 48
69 \f[B]fd\f[]\f[I]n\f[]\f[B]h420\f[] 420 42 10 2 64
70 \f[B]fd\f[]\f[I]n\f[]\f[B]h720\f[] 720 80 9 2 24
71 \f[B]fd\f[]\f[I]n\f[]\f[B]h880\f[] 880 80 11 2 80
72 \f[B]fd\f[]\f[I]n\f[]\f[B]h1200\f[] 1200 80 15 2 8
73 \f[B]fd\f[]\f[I]n\f[]\f[B]h1440\f[] 1440 80 18 2 40
74 \f[B]fd\f[]\f[I]n\f[]\f[B]h1476\f[] 1476 82 18 2 56
75 \f[B]fd\f[]\f[I]n\f[]\f[B]h1494\f[] 1494 83 18 2 72
76 \f[B]fd\f[]\f[I]n\f[]\f[B]h1600\f[] 1600 80 20 2 92
77 .TE
78 .P
79 3.5 inch double-density device files:
80 .TS
81 lw(1i) l l l l c
82 lw(1i) c c c c c.
83 Name Capacity Cyl. Sect. Heads Base
84 KiB minor #
85 _
86 \f[B]fd\f[]\f[I]n\f[]\f[B]u360\f[] 360 80 9 1 12
87 \f[B]fd\f[]\f[I]n\f[]\f[B]u720\f[] 720 80 9 2 16
88 \f[B]fd\f[]\f[I]n\f[]\f[B]u800\f[] 800 80 10 2 120
89 \f[B]fd\f[]\f[I]n\f[]\f[B]u1040\f[] 1040 80 13 2 84
90 \f[B]fd\f[]\f[I]n\f[]\f[B]u1120\f[] 1120 80 14 2 88
91 .TE
92 .P
93 3.5 inch high-density device files:
94 .TS
95 lw(1i) l l l l c
96 lw(1i) c c c c c.
97 Name Capacity Cyl. Sect. Heads Base
98 KiB minor #
99 _
100 \f[B]fd\f[]\f[I]n\f[]\f[B]u360\f[] 360 40 9 2 12
101 \f[B]fd\f[]\f[I]n\f[]\f[B]u720\f[] 720 80 9 2 16
102 \f[B]fd\f[]\f[I]n\f[]\f[B]u820\f[] 820 82 10 2 52
103 \f[B]fd\f[]\f[I]n\f[]\f[B]u830\f[] 830 83 10 2 68
104 \f[B]fd\f[]\f[I]n\f[]\f[B]u1440\f[] 1440 80 18 2 28
105 \f[B]fd\f[]\f[I]n\f[]\f[B]u1600\f[] 1600 80 20 2 124
106 \f[B]fd\f[]\f[I]n\f[]\f[B]u1680\f[] 1680 80 21 2 44
107 \f[B]fd\f[]\f[I]n\f[]\f[B]u1722\f[] 1722 82 21 2 60
108 \f[B]fd\f[]\f[I]n\f[]\f[B]u1743\f[] 1743 83 21 2 76
109 \f[B]fd\f[]\f[I]n\f[]\f[B]u1760\f[] 1760 80 22 2 96
110 \f[B]fd\f[]\f[I]n\f[]\f[B]u1840\f[] 1840 80 23 2 116
111 \f[B]fd\f[]\f[I]n\f[]\f[B]u1920\f[] 1920 80 24 2 100
112 .TE
113 .P
114 3.5 inch extra-density device files:
115 .TS
116 lw(1i) l l l l c
117 lw(1i) c c c c c.
118 Name Capacity Cyl. Sect. Heads Base
119 KiB minor #
120 _
121 \f[B]fd\f[]\f[I]n\f[]\f[B]u2880\f[] 2880 80 36 2 32
122 \f[B]fd\f[]\f[I]n\f[]\f[B]CompaQ\f[] 2880 80 36 2 36
123 \f[B]fd\f[]\f[I]n\f[]\f[B]u3200\f[] 3200 80 40 2 104
124 \f[B]fd\f[]\f[I]n\f[]\f[B]u3520\f[] 3520 80 44 2 108
125 \f[B]fd\f[]\f[I]n\f[]\f[B]u3840\f[] 3840 80 48 2 112
126 .TE
127 .SH DESCRIPTION
128 .B fd
129 special files access the floppy disk drives in raw mode.
130 The following
131 .BR ioctl (2)
132 calls are supported by
133 .B fd
134 devices:
135 .TP
136 .B FDCLRPRM
137 clears the media information of a drive (geometry of disk in drive).
138 .TP
139 .B FDSETPRM
140 sets the media information of a drive.
141 The media information will be
142 lost when the media is changed.
143 .TP
144 .B FDDEFPRM
145 sets the media information of a drive (geometry of disk in drive).
146 The media information will not be lost when the media is changed.
147 This will disable autodetection.
148 In order to reenable autodetection, you
149 have to issue an
150 .BR FDCLRPRM .
151 .TP
152 .B FDGETDRVTYP
153 returns the type of a drive (name parameter).
154 For formats which work
155 in several drive types,
156 .B FDGETDRVTYP
157 returns a name which is
158 appropriate for the oldest drive type which supports this format.
159 .TP
160 .B FDFLUSH
161 invalidates the buffer cache for the given drive.
162 .TP
163 .B FDSETMAXERRS
164 sets the error thresholds for reporting errors, aborting the operation,
165 recalibrating, resetting, and reading sector by sector.
166 .TP
167 .B FDSETMAXERRS
168 gets the current error thresholds.
169 .TP
170 .B FDGETDRVTYP
171 gets the internal name of the drive.
172 .TP
173 .B FDWERRORCLR
174 clears the write error statistics.
175 .TP
176 .B FDWERRORGET
177 reads the write error statistics.
178 These include the total number of
179 write errors, the location and disk of the first write error, and the
180 location and disk of the last write error.
181 Disks are identified by a
182 generation number which is incremented at (almost) each disk change.
183 .TP
184 .B FDTWADDLE
185 Switch the drive motor off for a few microseconds.
186 This might be
187 needed in order to access a disk whose sectors are too close together.
188 .TP
189 .B FDSETDRVPRM
190 sets various drive parameters.
191 .TP
192 .B FDGETDRVPRM
193 reads these parameters back.
194 .TP
195 .B FDGETDRVSTAT
196 gets the cached drive state (disk changed, write protected et al.)
197 .TP
198 .B FDPOLLDRVSTAT
199 polls the drive and return its state.
200 .TP
201 .B FDGETFDCSTAT
202 gets the floppy controller state.
203 .TP
204 .B FDRESET
205 resets the floppy controller under certain conditions.
206 .TP
207 .B FDRAWCMD
208 sends a raw command to the floppy controller.
209 .P
210 For more precise information, consult also the
211 .I <linux/fd.h>
212 and
213 .I <linux/fdreg.h>
214 include files, as well as the
215 .BR floppycontrol (1)
216 manual page.
217 .SH FILES
218 .I /dev/fd*
219 .SH NOTES
220 The various formats permit reading and writing many types of disks.
221 However, if a floppy is formatted with an inter-sector gap that is too small,
222 performance may drop,
223 to the point of needing a few seconds to access an entire track.
224 To prevent this, use interleaved formats.
225 .P
226 It is not possible to
227 read floppies which are formatted using GCR (group code recording),
228 which is used by Apple II and Macintosh computers (800k disks).
229 .P
230 Reading floppies which are hard sectored (one hole per sector, with
231 the index hole being a little skewed) is not supported.
232 This used to be common with older 8-inch floppies.
233 .\" .SH AUTHORS
234 .\" Alain Knaff ([email protected]), David Niemi
235 .\" ([email protected]), Bill Broadhurst ([email protected]).
236 .SH SEE ALSO
237 .BR chown (1),
238 .BR floppycontrol (1),
239 .BR getfdprm (1),
240 .BR mknod (1),
241 .BR superformat (1),
242 .BR mount (8),
243 .BR setfdprm (8)