Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ uwritec(D3) — UnixWare 2.01

Media Vault

Software Library

Restoration Projects

Artifacts Sought






       uwritec(D3)                                              uwritec(D3)


       NAME
             uwritec - return a character from space described by uio
             structure

       SYNOPSIS
             #include <sys/uio.h>
             #include <sys/ddi.h>
             int uwritec(uio_t *uiop);

          Arguments
             uiop      Pointer to the uio structure.

       DESCRIPTION
             uwritec copies a character from the space described by the
             uio(D4) structure pointed to by uiop and returns the character
             to the caller.

             The uio_segflg member of the uio structure specifies the type
             of space from which the copy is made.  If uio_segflg is set to
             UIO_SYSSPACE the character is copied from a kernel address.
             If uio_segflg is set to UIO_USERSPACE the character is copied
             from a user address.

             If the character is successfully copied, uwritec updates the
             appropriate members of the uio and iovec(D4) structures to
             reflect the copy (uio_offset and iov_base are incremented and
             uio_resid and iov_len are decremented) and returns the
             character to the caller.

          Return Values
             If successful, uwritec returns the character.  -1 is returned
             if the space described by the uio structure is empty or there
             is an error.

       USAGE
          Level
             Base only if uio_segflg is set to UIO_USERSPACE.

             Base or Interrupt if uio_segflg is set to UIO_SYSSPACE.

          Synchronization Constraints
             May sleep if uio_segflg is set to UIO_USERSPACE.

             Driver-defined basic locks and read/write locks may be held
             across calls to this function if uio_segflg is UIO_SYSSPACE
             but may not be held if uio_segflg is UIO_USERSPACE.


                           Copyright 1994 Novell, Inc.               Page 1













      uwritec(D3)                                              uwritec(D3)


            Driver-defined sleep locks may be held across calls to this
            function regardless of the value of uio_segflg.

         Warnings
            When holding locks across calls to this function,
            multithreaded drivers must be careful to avoid creating a
            deadlock.  During the data transfer, page fault resolution
            might result in another I/O to the same device.  For example,
            this could occur if the driver controls the disk drive used as
            the swap device.

      REFERENCES
            iovec(D4), uio(D4), uiomove(D3), ureadc(D3)

      NOTICES
         Portability
            All processors

         Applicability
            ddi: 1, 2, 3, 4, 5, 5mp, 6, 6mp, 7, 7mp




























                          Copyright 1994 Novell, Inc.               Page 2








Typewritten Software • bear@typewritten.org • Edmonds, WA 98026