|
/* BEGIN ts_dptbl.c */
#include <sys/proc.h>
#include <sys/priocntl.h>
#include <sys/class.h>
#include <sys/disp.h>
#include <sys/ts.h>
#include <sys/rtpriocntl.h>
/*
* This is the loadable module wrapper.
*/
#include <sys/modctl.h>
extern struct mod_ops mod_miscops;
/*
* Module linkage information for the kernel.
*/
static struct modlmisc modlmisc = {
&mod_miscops, "Time sharing dispatch table"
};
static struct modlinkage modlinkage = {
MODREV_1, &modlmisc, 0
};
_init()
{
return (mod_install(&modlinkage));
}
_info(modinfop)
struct modinfo *modinfop;
{
return (mod_info(&modlinkage, modinfop));
}
/*
* array of global priorities used by ts procs sleeping or
* running in kernel mode after sleep. Must have at least
* 40 values.
*/
pri_t config_ts_kmdpris[] = {
60,61,62,63,64,65,66,67,68,69,
70,71,72,73,74,75,76,77,78,79,
80,81,82,83,84,85,86,87,88,89,
90,91,92,93,94,95,96,97,98,99,
};
tsdpent_t config_ts_dptbl[] = {
/* glbpri qntm tqexp slprt mxwt lwt */
0, 100, 0, 10, 5, 10,
1, 100, 0, 11, 5, 11,
2, 100, 1, 12, 5, 12,
3, 100, 1, 13, 5, 13,
4, 100, 2, 14, 5, 14
5, 100, 2, 15, 5, 15,
6, 100, 3, 16, 5, 16,
7, 100, 3, 17, 5, 17,
8, 100, 4, 18, 5, 18,
9, 100, 4, 19, 5, 19,
10, 80, 5, 20, 5, 20,
11, 80, 5, 21, 5, 21,
12, 80, 6, 22, 5, 22,
13, 80, 6, 23, 5, 23,
14, 80, 7, 24, 5, 24,
15, 80, 7, 25, 5, 25,
16, 80, 8, 26, 5, 26,
17, 80, 8, 27, 5, 27,
18, 80, 9, 28, 5, 28,
19, 80, 9, 29, 5, 29,
20, 60, 10, 30, 5, 30,
21, 60, 11, 31, 5, 31,
22, 60, 12, 32, 5, 33,
24, 60, 14, 34, 5, 34,
25, 60, 15, 35, 5, 35,
26, 60, 16, 36, 5, 36,
27, 60, 17, 37, 5, 37,
28, 60, 18, 38, 5, 38,
29, 60, 19, 39, 5, 39,
30, 40, 20, 40, 5, 40,
31, 40, 21, 41, 5, 41,
32, 40, 22, 42, 5, 42,
33, 40, 23, 43, 5, 43,
34, 40, 24, 44, 5, 44,
35, 40, 25, 45, 5, 45,
36, 40, 26, 46, 5, 46,
37, 40, 27, 47, 5, 47,
38, 40, 28, 48, 5, 48,
39, 40, 29, 49, 5, 49,
40, 20, 30, 50, 5, 50,
41, 20, 31, 50, 5, 50,
42, 20, 32, 51, 5, 51,
43, 20, 33, 51, 5, 51,
44, 20, 34, 52, 5, 52,
45, 20, 35, 52, 5, 52,
46, 20, 36, 53, 5, 53,
47, 20 37, 53, 5, 53,
48, 20, 38, 54, 5, 54,
49, 20, 39, 54, 5, 54,
50, 10, 40, 55, 5, 55,
51, 10, 41, 55, 5, 55,
52, 10, 42, 56, 5, 56,
53, 10, 43, 56, 5, 56,
54, 10, 44, 57, 5, 57,
55, 10, 45, 57, 5, 57,
56, 10, 46, 58, 5, 58,
57, 10, 47, 58, 5, 58,
58, 10, 48, 59, 5, 59,
59, 10, 49, 59, 5, 59,
};
short config_ts_maxumdpri = sizeof (config_ts_dptbl)/16 - 1;
/*
* Return the address of config_ts_dptbl
*/
tsdpent_t *
ts_getdptbl()
{
return (config_ts_dptbl);
}
/*
* Return the address of config_ts_kmdpris
*/
int *
ts_getkmdpris()
{
return (config_ts_kmdpris);
}
/*
* Return the address of ts_maxumdpri
*/
short
ts_getmaxumdpri()
{
return (config_ts_maxumdpri);
}
/* END ts_dptbl.c */
|