priocntlset man page on SunOS

Man page or keyword search:  
man Server   20652 pages
apropos Keyword Search (all sections)
Output format
SunOS logo
[printable version]

priocntlset(2)			 System Calls			priocntlset(2)

NAME
       priocntlset - generalized process scheduler control

SYNOPSIS
       #include <sys/types.h>
       #include <sys/procset.h>
       #include <sys/priocntl.h>
       #include <sys/rtpriocntl.h>
       #include <sys/tspriocntl.h>

       long priocntlset(procset_t *psp, int cmd, /* arg */ ...);

DESCRIPTION
       The priocntlset() function changes the scheduling properties of running
       processes. priocntlset() has the same functions as the priocntl() func‐
       tion,  but  a more general way of specifying the set of processes whose
       scheduling properties are to be changed, which includes specifying LWPs
       of processes other than the calling process.

       cmd  specifies  the  function  to  be  performed. arg is a pointer to a
       structure whose type depends on cmd. See priocntl(2) for the valid val‐
       ues of cmd and the corresponding arg structures.

       psp  is	a  pointer to a procset structure, which priocntlset() uses to
       specify the set of processes whose  scheduling  properties  are	to  be
       changed. The procset structure contains the following members:

	 idop_t	   p_op;	/* operator connecting left/right sets */
	 idtype_t  p_lidtype;	/* left set ID type */
	 id_t	   p_lid;	/* left set ID */
	 idtype_t  p_ridtype;	/* right set ID type */
	 id_t	   p_rid;	/* right set ID */

       The  p_lidtype  and  p_lid  members  specify  the ID type and ID of one
       ("left") set of processes; the p_ridtype and p_rid members specify  the
       ID type and ID of a second ("right") set of processes. ID types and IDs
       are specified just as for the  priocntl()  function.  The  p_op	member
       specifies the operation to be performed on the two sets of processes to
       get the set of processes the function is to apply to. The valid	values
       for p_op and the processes they specify are:

       POP_DIFF	   Set difference: processes in left set and not in right set.

       POP_AND	   Set intersection: processes in both left and right sets.

       POP_OR	   Set union: processes in either left or right sets or both.

       POP_XOR	   Set exclusive-or: processes in left or right set but not in
		   both.

       The following macro, which is defined in <procset.h>, offers  a	conve‐
       nient way to initialize a procset structure:

	 #define  setprocset(psp, op, ltype, lid, rtype, rid) \
	 (psp)->p_op	   = (op), \
	 (psp)->p_lidtype  = (ltype), \
	 (psp)->p_lid	   = (lid), \
	 (psp)->p_ridtype  = (rtype), \
	 (psp)->p_rid	   = (rid),

RETURN VALUES
       Unless  otherwise noted above, priocntlset() returns 0 on success. Oth‐
       erwise, it returns −1 and sets errno to indicate the error.

ERRORS
       The priocntlset() function will fail if:

       EAGAIN	 An attempt to change the class of a process failed because of
		 insufficient resources other than memory (for example, class-
		 specific kernel data structures).

       EFAULT	 One of the arguments points to an illegal address.

       EINVAL	 The argument cmd was  invalid,	 an  invalid  or  unconfigured
		 class	was  specified, or one of the parameters specified was
		 invalid.

       ENOMEM	 An attempt to change the class of a process failed because of
		 insufficient memory.

       EPERM	 The  {PRIV_PROC_PRIOCNTL}  privilege  is  not asserted in the
		 effective set of the calling LWP.

		 The calling LWP does not have sufficient privileges to affect
		 the target LWP.

       ERANGE	 The requested time quantum is out of range.

       ESRCH	 None of the specified processes exist.

SEE ALSO
       priocntl(1), priocntl(2)

SunOS 5.10			  11 May 2011			priocntlset(2)
[top]

List of man pages available for SunOS

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net