Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

getrbuf(9f) [x11r4 man page]

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

NAME
getrbuf - get a raw buffer header SYNOPSIS
#include <sys/buf.h> #include <sys/kmem.h> #include <sys/ddi.h> struct buf *getrbuf(int sleepflag); INTERFACE LEVEL
Architecture independent level 1 (DDI/DKI). PARAMETERS
sleepflag Indicates whether driver should sleep for free space. DESCRIPTION
getrbuf() allocates the space for a buffer header to the caller. It is used in cases where a block driver is performing raw (character interface) I/O and needs to set up a buffer header that is not associated with the buffer cache. getrbuf() calls kmem_alloc(9F) to perform the memory allocation. kmem_alloc()requires the information included in the sleepflag argument. If sleepflag is set to KM_SLEEP, the driver may sleep until the space is freed up. If sleepflag is set to KM_NOSLEEP, the driver will not sleep. In either case, a pointer to the allocated space is returned or NULL to indicate that no space was available. RETURN VALUES
getrbuf() returns a pointer to the allocated buffer header, or NULL if no space is available. CONTEXT
getrbuf() can be called from user or interrupt context. (Drivers must not allow getrbuf() to sleep if called from an interrupt routine.) SEE ALSO
bioinit(9F), freerbuf(9F), kmem_alloc(9F), kmem_free(9F) Writing Device Drivers SunOS 5.10 20 Nov 1996 getrbuf(9F)

Check Out this Related Man Page

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

NAME
getrbuf - get a raw buffer header SYNOPSIS
#include <sys/buf.h> #include <sys/kmem.h> #include <sys/ddi.h> struct buf *getrbuf(int sleepflag); INTERFACE LEVEL
Architecture independent level 1 (DDI/DKI). PARAMETERS
sleepflag Indicates whether driver should sleep for free space. DESCRIPTION
getrbuf() allocates the space for a buffer header to the caller. It is used in cases where a block driver is performing raw (character interface) I/O and needs to set up a buffer header that is not associated with the buffer cache. getrbuf() calls kmem_alloc(9F) to perform the memory allocation. kmem_alloc()requires the information included in the sleepflag argument. If sleepflag is set to KM_SLEEP, the driver may sleep until the space is freed up. If sleepflag is set to KM_NOSLEEP, the driver will not sleep. In either case, a pointer to the allocated space is returned or NULL to indicate that no space was available. RETURN VALUES
getrbuf() returns a pointer to the allocated buffer header, or NULL if no space is available. CONTEXT
getrbuf() can be called from user or interrupt context. (Drivers must not allow getrbuf() to sleep if called from an interrupt routine.) SEE ALSO
bioinit(9F), freerbuf(9F), kmem_alloc(9F), kmem_free(9F) Writing Device Drivers SunOS 5.10 20 Nov 1996 getrbuf(9F)
Man Page

We Also Found This Discussion For You

1. UNIX for Advanced & Expert Users

Shopt -s histappend

What is the point of this? Whenever I close my shell it appends to the history file without adding this. I have never seen it overwrite my history file. # When the shell exits, append to the history file instead of overwriting it shopt -s histappend (3 Replies)
Discussion started by: cokedude
3 Replies