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

개요

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

bp_mapin(9f)

bp_mapin(9F)                   Kernel Functions                   bp_mapin(9F)

NAME
       bp_mapin - allocate virtual address space

SYNOPSIS
       #include <sys/types.h>
       #include <sys/buf.h>

       void bp_mapin(struct buf *bp);

INTERFACE LEVEL
       Architecture independent level 1 (DDI/DKI).

PARAMETERS
       bp    Pointer to the buffer header structure.


DESCRIPTION
       The  bp_mapin()  function  makes  buffer data accessible to a driver by
       mapping the data into a contiguous kernel virtual address region. After
       bp_mapin(), the mapped buffer is  accessible  via  the  bp—>b_un.b_addr
       field of the buf(9S) structure.


       If  bp_mapin() is unable to establish a mapping, it returns without al‐
       locating space and no mapping is performed.


       Any resources associated with establishing the mapping are  deallocated
       by the bp_mapout(9F) function.

CONTEXT
       The bp_mapin() function can be called from user and kernel contexts.

SEE ALSO
       bioaligned(9F), bp_mapout(9F), bp_copyin(9F), bp_copyout(9F), buf(9S)


       Writing Device Drivers in Oracle Solaris 11.4

WARNINGS
       Because  bp_mapin()  does  not keep a reference count, bp_mapout() will
       wipe out any kernel mapping, including mappings that a layer above  the
       device driver might still rely on. See bp_mapout(9F) for details.


       When  a  driver  needs  to look directly at buffer data, it should call
       bp_mapin() without conditioning  the  call  on  other  aspects  of  the
       buf(9S) structure like b_flags.


       To  check  alignment  of  buffer memory, it may be more efficient for a
       driver to use bioaligned(9F) instead of bp_mapin().

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