summaryrefslogtreecommitdiffstats
path: root/usr.sbin/fdread/fdread.c
Commit message (Collapse)AuthorAgeFilesLines
* Drop the defunct FDOPT_NOERRLOG option from all the floppy utilities.joerg2009-06-241-8/+1
| | | | | | | | The kernel does not log floppy media errors anymore. In fdcontrol, do always open the file descriptor in read-only mode so it can operate on read-only media, as there is no longer a separate control device to operate on.
* Remove unused variables.stefanf2006-07-201-2/+2
|
* fdread cannot work without opening the /dev/fd node in O_RDWR mode now,peter2005-10-261-1/+1
| | | | | | | because it sets the floppy controller parameters, which requires O_RDWR. Specifically, the FD_SOPTS ioctl requires this, and the code errors out and aborts if it can't do it. Among other things, it is changing the FDOPT_NOERRLOG flag. Broken in 6.0 as well.
* Cleanup usr.sbin/fd* so they can compile under WARNS=6.delphij2005-01-081-21/+21
| | | | | | | | | | | | | | | | | | | | | | | | fdcontrol/fdcontrol.c: - Add const constraint to an intermediate value which is not supposed to be changed elsewhere. fdread/fdread.c: - Use _devname in favor of devname to avoid name conflicit. - -1 is less than any positive number so in order to get the block to function, we should get the block a little earlier. - Cast to remove signed when we are sure that a return value is positive, or is compared with an positive number (tracknumber of a floppy disk is not likely to have UINT_MAX/2 anyway) fdread/fdutil.c: - Use more specific initializer fdwrite/fdwrite.c: - Use static on format_track since it's not referenced in other places. - Use const char* to represent string constant. Bump WARNS accordingly.
* Break out the function to print the FDC error information intojoerg2001-07-021-44/+4
| | | | fdutil.c so it can be used elsewhere.
* Implement the -I option that uses the FD_READID ioctl in order to readjoerg2001-06-261-3/+75
| | | | sector ID fields from a floppy, and display them.
* Part #2 of the <machine/ioctl_fd.h> => <sys/fdcio.h> move: handle thejoerg2001-06-061-2/+1
| | | | tools in usr.sbin/fd*.
* Now that we've got the ne765.h file installed under <dev/ic/>, use itjoerg2001-06-041-2/+1
| | | | | | here instead of the old "/sys/isa/ic/..." hack. This should fix building the world for machines that don't have a /sys symlink, finally.
* Initial import of fdread(1), a logical counterpart to fdwrite(1).joerg2001-05-141-0/+307
Its main purpose is to adapt automatically to the floppy parameters (in particular the track size for efficient reading), and to allow a simple error recovery for CRC-errored sectors. Requires the newly added fdc(4) options.
OpenPOWER on IntegriCloud