ddi_dma_movwin(9f) 맨 페이지 - 윈디하나의 솔라나라

개요

섹션
맨 페이지 이름
검색(S)

ddi_dma_movwin(9f)

ddi_dma_movwin(9F)             Kernel Functions             ddi_dma_movwin(9F)

NAME
       ddi_dma_movwin - shift current DMA window

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

       int ddi_dma_movwin(ddi_dma_handle_t handle, off_t *offp,
            uint_t *lenp, ddi_dma_cookie_t *cookiep);

INTERFACE LEVEL
       This interface is obsolete. ddi_dma_getwin(9F) should be used instead.

PARAMETERS
       handle     The DMA handle filled in by a call to ddi_dma_setup(9F).


       offp       A pointer to an offset to set the DMA window to. Upon a suc‐
                  cessful  return,  it  will  be filled in with the new offset
                  from the beginning of the  object  resources  are  allocated
                  for.


       lenp       A  pointer  to a value which must either be the current size
                  of the DMA window (as known  from  a  call  to  ddi_dma_cur‐
                  win(9F) or from a previous call to ddi_dma_movwin()). Upon a
                  successful  return,  it  will be filled in with the size, in
                  bytes, of the current window.


       cookiep    A pointer to a DMA cookie (see ddi_dma_cookie(9S)).  Upon  a
                  successful  return,  cookiep  is filled in just as if an im‐
                  plicit ddi_dma_htoc(9F) had been made.


DESCRIPTION
       The ddi_dma_movwin() function shifts the current DMA window. If  a  DMA
       request  allows  the system to allocate resources for less than the en‐
       tire object by setting the DDI_DMA_PARTIAL flag in the  ddi_dma_req(9S)
       structure,  the  current  DMA  window  can  be  shifted  by  a  call to
       ddi_dma_movwin().


       The caller must first determine the current DMA window size by  a  call
       to  ddi_dma_curwin(9F). Using the current offset and size of the window
       thus retrieved, the caller of ddi_dma_movwin() may  change  the  window
       onto  the object by changing the offset by a value which is some multi‐
       ple of the size of the DMA window.


       The ddi_dma_movwin() function takes care of  underlying  resource  syn‐
       chronizations required to shift the window. However, if you want to ac‐
       cess the data prior to or after moving the window, further synchroniza‐
       tions using ddi_dma_sync(9F) are required.


       This  function  is normally called from an interrupt routine. The first
       invocation of the DMA engine is done from the  driver.  All  subsequent
       invocations  of the DMA engine are done from the interrupt routine. The
       interrupt routine checks to see if the request has been  completed.  If
       it  has, it returns without invoking another DMA transfer. Otherwise it
       calls ddi_dma_movwin() to shift the current window and  starts  another
       DMA transfer.

RETURN VALUES
       The ddi_dma_movwin() function returns:

       DDI_SUCCESS    The  current  length  and offset are legal and have been
                      set.


       DDI_FAILURE    Otherwise.


CONTEXT
       The ddi_dma_movwin() function can be called from  user,  interrupt,  or
       kernel context.

ATTRIBUTES
       See attributes(7) for a description of the following attributes:

       tab()  box; cw(2.75i) |cw(2.75i) lw(2.75i) |lw(2.75i) ATTRIBUTE TYPEAT‐
       TRIBUTE VALUE _ Stability LevelObsolete


SEE ALSO
       attributes(7),         ddi_dma_curwin(9F),          ddi_dma_getwin(9F),
       ddi_dma_htoc(9F),          ddi_dma_setup(9F),         ddi_dma_sync(9F),
       ddi_dma_cookie(9S), ddi_dma_req(9S)


       Writing Device Drivers in Oracle Solaris 11.4

WARNINGS
       The caller must guarantee that the resources used by the object are in‐
       active prior to calling this function.

Oracle Solaris 11.4               16 Jan 2006               ddi_dma_movwin(9F)
맨 페이지 내용의 저작권은 맨 페이지 작성자에게 있습니다.
RSS ATOM XHTML 5 CSS3