The second parameter of every call from the LFS to the PFS is the
address of the operating system interface (OSI) structure. This structure
contains information that is used by the OSI_operations and MVS-specific
information that needs to be passed between the LFS and the PFS. It
is mapped by the OSI typedef in
Interface structures for C language servers and clients. The
fields are described as follows:
- Field
- Description
- Wait-post fields
- token
- Wait-post token. Set by osi_wait when it is called to set up for
a wait. This token is the input to osi_post when it is called to wake
up the current thread.
- ecb
- Address of an event control block (ECB). Set by osi_wait when
it is called to set up for a wait. This is the ECB that is used by
osi_wait when it is called to suspend. A program that cannot call
osi_post can use this ECB with an MVS™ cross-memory
post to wake up the current thread. However, using the MVS cross-memory post for this ECB can result
in a system integrity problem.
- ascb
- Address of the address space control block (ASCB). Set by osi_wait
when it is called to set up for a wait. This ASCB address is used,
along with the ECB, for an MVS cross-memory
post.
- SMF accounting fields
- diribc
- Directory I/O block count that occurred on this operation.
- readibc
- Read I/O block count that occurred on this operation.
- writeibc
- Write I/O block count that occurred on this operation.
- bytesrd
- The number of bytes that were read on this operation.
- byteswr
- The number of bytes that were written on this operation.
- Miscellaneous fields
- rtokptr
- Address of the recovery token area. The recovery token area is
set and cleared by the PFS on each operation, to provide for abnormal
end and end-of-memory recovery. Refer to Recovery considerations for
details.
- workarea
- Address of a work area for use by the PFS. This area can be used
for the dynamic, or automatic, storage necessary to run the current
operation. This can save the PFS the overhead of obtaining and freeing
stack storage on every call. The workarea is on a doubleword boundary.
- workarealen
- Length of the workarea. The workarea length is 3KB. This allows
2KB for routines that call the SAF Chk_Owner_Two_Files routine or
the osi_uiomove service, each of which requires that a 2-KB work area
be passed. The other SAF security routines require a 1-KB work area.
- pid
- The current thread's process ID (PID). This is the input to osi_signal
if it is called to send a signal to the current thread's process.
- pfsid
- A PFS identifier that is used with osi_sleep and osi_wakeup.
- attr
- Address of an output file attribute buffer. Whenever this field is nonzero,
the PFS should build and return a standard attribute structure for
the file operated on at the end of the current operation. This is
the same attribute structure that would be returned by vn_getattr.
The
buffer is preset with an attribute structure header that contains
the available length of the buffer.
Because this buffer may
be the same area as an input attribute structure, it should not be
modified until the very end of the current operation.
If the
PFS does not return the file's attributes when asked, the LFS invokes
vn_getattr to get them. This results in poorer performance for files
that are supported by this PFS.
- fsp
- Address of an output File Security Packet (FSP). Whenever this
field is nonzero, the PFS should return an fsp structure for the file
operated on. This is the same fsp structure that would be returned
by vn_getattr.
If the PFS does not return the file's FSP when asked,
the LFS builds one. For a description of the FSP, refer to Security responsibilities and considerations.
- remount
- A flag that indicates that the current operation is running during
a remount (that is, during UNMOUNT with the REMOUNT option).
- NotSigReg
- Indicates that the calling process is not registered for signals
and so should not be sent any.