ddi_device_copy man page on SunOS

Man page or keyword search:  
man Server   20652 pages
apropos Keyword Search (all sections)
Output format
SunOS logo
[printable version]

ddi_device_copy(9F)	 Kernel Functions for Drivers	   ddi_device_copy(9F)

NAME
       ddi_device_copy	- copy data from one device register to another device
       register

SYNOPSIS
       #include <sys/ddi.h>
       #include <sys/sunddi.h>

       int  ddi_device_copy(ddi_acc_handle_t  src_handle,  caddr_t   src_addr,
       ssize_t	src_advcnt,  ddi_acc_handle_t  dest_handle, caddr_t dest_addr,
       ssize_t dest_advcnt, size_t bytecount, uint_t dev_datasz);

INTERFACE LEVEL
       Solaris DDI specific (Solaris DDI).

PARAMETERS
       src_handle      The data access handle of the source device.

       src_addr	       Base data source address.

       src_advcnt      Number of  dev_datasz units to advance on every access.

       dest_handle     The data access handle of the destination device.

       dest_addr       Base data destination address.

       dest_advcnt     Number of  dev_datasz units to advance on every access.

       bytecount       Number of bytes to transfer.

       dev_datasz      The size of each data word. Possible values are defined
		       as: "15">DDI_DATA_SZ01_ACC 1 byte data size

		       DDI_DATA_SZ02_ACC       2 bytes data size

		       DDI_DATA_SZ04_ACC       4 bytes data size

		       DDI_DATA_SZ08_ACC       8 bytes data size

DESCRIPTION
       ddi_device_copy()  copies   bytecount  bytes  from the source  address,
       src_addr, to  the  destination  address,	  dest_addr.   The  attributes
       encoded	in the access handles, src_handle and  dest_handle, govern how
       data is actually copied from  the   source  to  the  destination.  Only
       matching data sizes between the source and destination are supported.

       Data  will  automatically  be translated to maintain a consistent  view
       between the source and the destination. The  translation	 may   involve
       byte-swapping if the source and the destination devices	have incompat‐
       ible endian characteristics.

       The  src_advcnt and  dest_advcnt	 arguments  specifies  the  number  of
       dev_datasz units to advance with each access to the device addresses. A
       value of	 0 will use the same source and destination device address  on
       every  access.  A  positive  value  increments the corresponding device
       address by certain number of data size units in the  next  access.   On
       the other hand, a negative value decrements the device address.

       The  dev_datasz	argument  determines the size of the data word on each
       access. The data size must be the same between the source and  destina‐
       tion.

RETURN VALUES
       ddi_device_copy() returns:

       DDI_SUCCESS	       Successfully transferred the data.

       DDI_FAILURE	       The byte count is not a multiple dev_datasz.

CONTEXT
       ddi_device_copy()  can  be  called from user, kernel, or interrupt con‐
       text.

SEE ALSO
       ddi_regs_map_free(9F), ddi_regs_map_setup(9F)

       Writing Device Drivers

SunOS 5.10			  15 Nov 1996		   ddi_device_copy(9F)
[top]

List of man pages available for SunOS

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net