Go to main content

man pages section 9: DDI and DKI Kernel Functions

Exit Print View

Updated: July 2017
 
 

ddi_get_pid(9F)

Name

ddi_get_pid - returns the processID

Synopsis

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

pid_t ddi_get_pid(void);

Interface Level

Solaris DDI specific (Solaris DDI).

Description

ddi_get_pid() obtains the process ID of the current process. This value can be used to allow only a select process to perform a certain operation. It can also be used to determine whether a device context belongs to the current process.

Return Values

ddi_get_pid() returns the process ID.

Context

This routine can be called from user context only.

See Also

drv_getparm(9F)

Writing Device Drivers for Oracle Solaris 11.3

STREAMS Programming Guide