The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/man/processor_set_info.man

Version: -  FREEBSD  -  FREEBSD-13-STABLE  -  FREEBSD-13-0  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  l41  -  OPENBSD  -  linux-2.6  -  MK84  -  PLAN9  -  xnu-8792 
SearchContext: -  none  -  3  -  10 

    1 .\" 
    2 .\" Mach Operating System
    3 .\" Copyright (c) 1991,1990 Carnegie Mellon University
    4 .\" All Rights Reserved.
    5 .\" 
    6 .\" Permission to use, copy, modify and distribute this software and its
    7 .\" documentation is hereby granted, provided that both the copyright
    8 .\" notice and this permission notice appear in all copies of the
    9 .\" software, derivative works or modified versions, and any portions
   10 .\" thereof, and that both notices appear in supporting documentation.
   11 .\" 
   12 .\" CARNEGIE MELLON ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS"
   13 .\" CONDITION.  CARNEGIE MELLON DISCLAIMS ANY LIABILITY OF ANY KIND FOR
   14 .\" ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
   15 .\" 
   16 .\" Carnegie Mellon requests users of this software to return to
   17 .\" 
   18 .\"  Software Distribution Coordinator  or  Software.Distribution@CS.CMU.EDU
   19 .\"  School of Computer Science
   20 .\"  Carnegie Mellon University
   21 .\"  Pittsburgh PA 15213-3890
   22 .\" 
   23 .\" any improvements or extensions that they make and grant Carnegie Mellon
   24 .\" the rights to redistribute these changes.
   25 .\" 
   26 .\" 
   27 .\" HISTORY
   28 .\" $Log:       processor_set_info.man,v $
   29 .\" Revision 2.5  93/03/18  15:14:23  mrt
   30 .\"     corrected types
   31 .\"     [93/03/11  12:54:02  lli]
   32 .\" 
   33 .\" Revision 2.4  91/05/14  17:11:39  mrt
   34 .\"     Correcting copyright
   35 .\" 
   36 .\" Revision 2.3  91/02/14  14:14:03  mrt
   37 .\"     Changed to new Mach copyright
   38 .\"     [91/02/12  18:14:51  mrt]
   39 .\" 
   40 .\" Revision 2.2  90/08/07  18:42:42  rpd
   41 .\"     Created.
   42 .\" 
   43 .TH processor_set_info 2 8/13/89
   44 .CM 4
   45 .SH NAME
   46 .nf
   47 processor_set_info   \-   gets information about a processor set
   48 .SH SYNOPSIS
   49 .nf
   50 .ft B
   51 #include <mach.h>
   52 
   53 .nf
   54 .ft B
   55 /* the definition of processor_set_info_ from mach/processor_info.h  */
   56 
   57 typedef int     *processor_set_info_t;  /* variable length array of int */
   58 
   59 /* one interpretation of info is */
   60 
   61    struct processor_set_basic_info {
   62         int             processor_count;        /* number of processors */
   63         int             task_count;             /* number of tasks */
   64         int             thread_count;           /* number of threads */
   65         int             load_average;           /* scaled load average */
   66         int             mach_factor;            /* scaled mach factor */
   67    };
   68 typedef struct processor_set_basic_info         *processor_set_basic_info_t;
   69 
   70 /* another interpretation of info is */
   71 
   72 struct processor_set_sched_info {
   73         int             policies;       /* allowed policies */
   74         int             max_priority;   /* max priority for new threads */
   75 };
   76 
   77 typedef struct processor_set_sched_info *processor_set_sched_info_t;
   78 
   79 
   80 kern_return_t
   81 processor_set_info(processor_set, flavor, host, processor_set_info,
   82     processor_set_infoCnt)
   83         mach_port_t             processor_set;
   84         int                     flavor;
   85         mach_port_t             *host;
   86         processor_set_info_t    processor_set_info;     /* in and out */
   87         mach_msg_type_number_t  *processor_set_infoCnt; /* in and out */
   88 
   89 
   90 
   91 .fi
   92 .ft P
   93 .SH ARGUMENTS
   94 .TP 15
   95 .B
   96 processor_set
   97 The processor_set for which information is to be obtained
   98 .TP 15
   99 .B
  100 flavor
  101 The type of information that is wanted.
  102 .TP 15
  103 .B
  104 host
  105 The host on which the processor set resides.  This is the 
  106 non-privileged host port.
  107 .TP 15
  108 .B
  109 processor_set_info
  110 Information about the processor set specified by 
  111 .B processor_set.
  112 .TP 15
  113 .B
  114 processor_set_infoCnt
  115 Size of the info structure. Should be
  116 .B PROCESSOR_SET_BASIC_INFO_COUNT
  117 for flavor 
  118 .B PROCESSOR_SET_BASIC_INFO
  119 , and 
  120 .B PROCESSOR_SET_SCHED_INFO_COUNT
  121 for flavor
  122 .B PROCESSOR_SET_SCHED_INFO.
  123 
  124 .SH DESCRIPTION
  125 
  126 Returns the selected information array for a processor_set, as specified
  127 by 
  128 .B flavor.
  129 
  130 .B processor_set_info
  131 
  132 is an array of integers that is supplied
  133 by the caller, and filled with specified information. 
  134 .B processor_set_infoCnt
  135 is supplied as the maximum number of integers in 
  136 .B processor_set_info.
  137 On return,
  138 it contains the actual number of integers in  
  139 .B processor_set_info.
  140 
  141 Basic information is defined by 
  142 .B PROCESSOR_SET_BASIC_INFO.
  143 The size of this information is defined by 
  144 .B PROCESSOR_SET_BASIC_INFO_COUNT.
  145 The 
  146 .B load_average
  147 and 
  148 .B mach_factor
  149 arguments are scaled by the constant
  150 .B LOAD_SCALE
  151 (i.e. the integer value returned is the actual value 
  152 multiplied by 
  153 .B LOAD_SCALE.
  154 
  155 Scheduling information is defined by 
  156 .B PROCESSOR_SET_SCHED_INFO.
  157 The size of this information is given by 
  158 .B PROCESSOR_SET_SCHED_INFO_COUNT.
  159 Some machines may define machine-dependent information flavors.
  160 
  161 .SH DIAGNOSTICS
  162 .TP 25
  163 KERN_SUCCESS
  164 The call succeeded.
  165 .TP 25
  166 KERN_INVALID_ARGUMENT
  167 .B processor_set
  168 is not a processor set or
  169 .B flavor
  170 is not recognized.
  171 .TP 25
  172 MIG_ARRAY_TOO_LARGE
  173 Returned info array is too large for
  174 .B processor_set_info.
  175 
  176 .B processor_set_info
  177 
  178 is filled as much as possible. 
  179 .B processor_set_infoCnt
  180 is set to the number of elements that would
  181 be returned if there were enough room.
  182 
  183 .SH BUGS
  184 Availability limited.
  185 
  186 .SH SEE ALSO
  187 .B processor_set_create, processor_set_default, processor_assign,
  188 .B task_assign, thread_assign
  189 
  190 
  191 
  192 
  193 

Cache object: e620dedcb542058715c4ac12ee78d821


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.