Subject: Re: bin/6774: dd(1) will not seek on raw disk devices
To: None <dave@dtsp.co.nz>
From: Jason Thorpe <thorpej@nas.nasa.gov>
List: tech-kern
Date: 01/09/1999 09:18:20
On 9 Jan 1999 13:10:00 -0000
dave@dtsp.co.nz wrote:
> This seems a trifle unfair on raw disk devices, just because they are a
> character devices. Perhaps instead it could actually try an lseek() and if it
> fails revert to reading and ignoring the preceeding data.
>
> Note that it already does this to decide whether it is a pipe or not...
Unfortunately, this doesn't quite work, due to a defficiency in the specfs
code. The specfs code doesn't actually invoke the underlying driver to
see if the device is seekable. Instead, it just adjusts the file pointer
and continues on.
This needs to be fixed in the kernel, first.
Jason R. Thorpe thorpej@nas.nasa.gov
NASA Ames Research Center Home: +1 408 866 1912
NAS: M/S 258-5 Work: +1 650 604 0935
Moffett Field, CA 94035 Pager: +1 650 940 5942