[ Bottom of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]

Technical Reference: Kernel and Subsystems, Volume 1

__pag_setvalue System Call

Purpose

Invokes the kcred_setpag kernel service and sets the value of PAG type to pag.

Syntax

int __pag_setvalue (type, pag)
int type;
int pag;

Description

Given a PAG type and value, the __pag_setvalue system call invokes the kcred_setpag kernel service and sets the value of PAG type to pag. This system call requires the SET_PROC_DAC privilege.

Parameters

type An int value indicating the desired PAG.
pag An int value containing the new PAG value.

Return Values

If successful, 0 is returned. If unsuccessful, -1 is returned and the errno global variable is set to a value reflecting the cause of the error.

Error Codes

ENOENT The type parameter doesn't reference an existing PAG type.
EINVAL The value of pag is -1.
EPERM The calling process lacks the appropriate privilege.

Related Information

__pag_getid System Call, __pag_getname System Call, __pag_getvalue System Call, __pag_setname System Call, kcred_getpagid Kernel Service, kcred_getpagname Kernel Service, and kcred_setpagname Kernel Service.

[ Top of Page | Previous Page | Next Page | Contents | Index | Library Home | Legal | Search ]