Caller-provided buffer into which the data will be read.
The buffer need not be physically contiguous nor page aligned.
nbytes
Amount of data in bytes to read into buf.
offset
Offset in bytes from the start of the file at which to start reading.
Return values
EBADF
handle was not valid.
EINVAL
nbytes + offset exceeds the file size.
EIO
There was an error while reading from the file.
Usage
For large files, this function can be called repeatedly with
increasing offsets. In this case, the driver would read some part
of the file, download that data to its hardware, and then call
mdi_read_file( )
again with offset set to one byte past the end of the last
read( )
to read the next portion of the file.
Context and synchronization
Blockable
context
at a time when it is safe to lower the system
interrupt priority (ipl) to plbase.