#include <sys/types.h> #include <sys/ddi.h> #include <sys/sunddi.h>pid_t ddi_get_pid(void);
Solaris DDI specific (Solaris DDI).
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.
ddi_get_pid() returns the process ID.
This routine can be called from user context only.