dfs_writenowait

Writes sectors into a file using DFS, returning immediately after initiation.

Library:LibC
Classification:Novell
Service:Direct File System

Syntax

  #include <dfs.h>  
   
  int dfs_writenowait (
     int              fildes,
     uint32_t         startingSector,
     size_t           sectorCount,
     const void      *buffer,
     dfs_cbparms_t   *cbNode );
  

Parameters

fildes

(IN) Specifies the file handle returned from a prior dfs_sopen call for the file.

startingSector

(IN) Specifies the starting sector number in the file (logical offset from beginning of file) where the write operation is to begin.

sectorCount

(IN) Specifies the number of sectors to be written from the buffer.

buffer

(IN) Points to a contiguous buffer area large enough to contain the number of sectors to be written.

cbNode

(IN) Points to a structure used to signal completion of all requested writes for a particular call to dfs_writenowait.

Return Values

If successful in initiating the request, returns 0. Otherwise, returns a nonzero error code:

Decimal

Constant

Description

4

EBADF

The fildes parameter isn't a valid file descriptor.

79

ENOTSUP

The NLM is loaded in protected address space. This operation is supported only in kernel address space.

106

ENOCONTEXT

The current thread has not context.

The actual completion is stored in the ccode field of the dfs_cbparms_t structure upon completion of the request. For possible DFS errors, see Section 13.4.5, DFS Return Values.

Remarks

This function is identical to dfs_write, except that the function caller returns immediately after posting the write to the driver. This means that the status returned from the function only indicates whether the call was initiated or not. The completion status is returned in the structure provided for completion notification.

See Also