[Toc][Index]

FS32_READ - Read from a File

  
Purpose   
Read the specified number of bytes from a file to a buffer location. 
Version for 32-bit IFS'es. Handles a 64-bit file pointer and size. 
Calling Sequence   

int _cdecl FS32_READ(psffsi, psffsd, pData, pLen, IOflag)

struct sffsi * psffsi;
struct sffsd * psffsd;
char * pData;
unsigned long * pLen;
unsigned long IOflag;


Where   
psffsi is a pointer to the file-system-independent portion of an open file 
instance. 
sfi_position is the location within the file where the data is to be read 
from. The FSD should update the sfi_position field. Since OS/2 Warp Server 
for e-Business 4.5 (Aurora), 64-bit file position is supported. It is 
stored in sfi_positionl field. Both sfi_position and sfi_positionl should 
be updated each time it changed. If the file position is larger than 2GB 
(signed), it should be truncated to a (LONG) value. 
psffsd is a pointer to the file-system-dependent portion of an open file 
instance. 
pData is the address of the application data area. 
Addressing of this data area has not been validated by the kernel (see 
FSH_ PROBEBUF). 
pLen is a pointer to the length of the application data area. 
On input, this is the number of bytes to be read. On output, this is the 
number of bytes successfully read. If the application data area is smaller 
than the length, no transfer is to take place. The FSD will not be called 
for zero length reads. The FSD does not need to verify this pointer. 
IOflag indicates information about the operation on the handle. 
IOflag == 0x0010 indicates write-through 
IOflag == 0x0020 indicates no-cache 
  
Remarks   
If read is successful and is a file, the FSD should set ST_SREAD and 
ST_PREAD to make the kernel time stamp the last modification time in the 
SFT. 
Of the information passed in IOflag, the write-through bit is a mandatory 
bit in that any data written to the block device must be put out on the 
medium before the device driver returns. The no-cache bit, on the other 
hand, is an advisory bit that says whether the data being transferred is 
worth caching or not.   

Created using Inf-PHP v.2 (c) 2003 Yuri Prokushev
Created using Inf-HTML v.0.9b (c) 1995 Peter Childs