SC_READ(2) | SC_READ(2) |
#include <sc.h>
int sc_read(int scfd, char* buffer, scarg_t* length, scarg_t offset0, scarg_t offset1);
offset0
and offset1
parameters are
given when accessing a device. The semantics of these
parameters are defined by the opened device.
The buffer
variable points to a buffer in the user parallel process.
In the sc_read()
function, the value of the length
variable becomes the length of the buffer actually read.
sc_read()
returns 0 on success
or one of the following errors:
ENODEV
ENOSPACE
EBUSY
EIO
EINTR