Hallo, dies ist ein Test.
PWD: /www/data-lst1/unixsoft/unixsoft/kaempfer/.public_html
Running in File Mode
Relative path: ./../../../../../../usr/include/sys/schedctl.h
Real path: /usr/include/sys/schedctl.h
Zurück
/* * Copyright (c) 1996, 2016, Oracle and/or its affiliates. All rights reserved. */ /* * The enclosed is a private interface between system libraries and the kernel * It should not be used in any other way. It may be changed without notice in * a minor release of Solaris. */ #ifndef _SYS_SCHEDCTL_H #define _SYS_SCHEDCTL_H #ifdef __cplusplus extern "C" { #endif #if !defined(_ASM) #include <sys/types.h> #include <sys/processor.h> #include <sys/sysmacros.h> #define SC_SHARED_PAD P2NPHASE(sizeof (ushort_t) + 4 * sizeof (char) + \ 2 * sizeof (uchar_t) + sizeof (processorid_t) + sizeof (chipid_t) + \ sizeof (sc_public_t) + sizeof (int), _FALSE_SHARING_ALIGN) /* * This "public" portion of the sc_shared data is used by libsched/libc. */ typedef struct sc_public { volatile short sc_nopreempt; volatile short sc_yield; } sc_public_t; /* * The private portion of the sc_shared data is for use by user-level threading * support code in libc. Java has a contract containing this language: * * Solaris will attempt to keep the offset, size and encoding * of sc_cpu, sc_state and sc_preemptctl constant, starting with * Solaris 10, to assure binary compatibility for the java/libc * interface into the future. * * See PSARC/2005/351 for details. 'sc_pad' must be the last member of the * structure. * * See PSARC/2016/154 for details of sc_version and sc_disp_nrunnable. */ typedef struct sc_shared { volatile ushort_t sc_state; /* current LWP state */ volatile char sc_sigblock; /* all signals blocked */ volatile uchar_t sc_flgs; /* set only by curthread; see below */ volatile processorid_t sc_cpu; /* last CPU on which LWP ran */ volatile char sc_cid; /* scheduling class id */ volatile char sc_cpri; /* class priority, -128..127 */ volatile uchar_t sc_priority; /* dispatch priority, 0..255 */ uchar_t sc_version; /* schedctl version */ sc_public_t sc_preemptctl; /* preemption control data */ volatile chipid_t sc_seq_cache; /* socket id of this CPU */ volatile int sc_disp_nrunnable; /* runnable threads on this CPU */ char sc_pad[SC_SHARED_PAD]; } sc_shared_t; /* sc_flgs */ #define SC_PARK_FLG 0x01 /* calling lwp_park() */ #define SC_CANCEL_FLG 0x02 /* cancel pending and not disabled */ #define SC_EINTR_FLG 0x04 /* EINTR returned due to SC_CANCEL_FLG */ /* * Possible state settings. These are same as the kernel thread states * except there is no zombie state. */ #define SC_FREE 0x00 #define SC_SLEEP 0x01 #define SC_RUN 0x02 #define SC_ONPROC 0x04 #define SC_STOPPED 0x10 #define SC_WAIT 0x20 /* * Versioning was added with the addition of the sc_disp_nrunnable field. * Because there was no versioning prior to this, no assumptions can be * made about the existence of any field for version 0. * * Otherwise, the fields covered by these versions are as follows: * * Version 1: * sc_disp_nrunnable */ #define SC_VERSION (uchar_t)1 /* * Maximum time preemption can be blocked. The default is two clock ticks at the * regular clock rate (or 20ms). */ #define SC_MAX_TICKS (2) #ifdef _KERNEL caddr_t schedctl(void); void schedctl_init(void); void schedctl_lwp_cleanup(kthread_t *); void schedctl_proc_cleanup(void); int schedctl_get_nopreempt(kthread_t *); void schedctl_set_nopreempt(kthread_t *, short); void schedctl_set_yield(kthread_t *, short); void schedctl_set_cidpri(kthread_t *); int schedctl_sigblock(kthread_t *); void schedctl_clear_sigblock(kthread_t *); void schedctl_finish_sigblock(kthread_t *); int schedctl_cancel_pending(void); void schedctl_cancel_eintr(void); int schedctl_is_park(void); void schedctl_set_park(void); void schedctl_unpark(void); extern clock_t sc_nopreempt_interval; #endif /* _KERNEL */ #endif /* !defined(_ASM) */ #ifdef __cplusplus } #endif #endif /* _SYS_SCHEDCTL_H */