summaryrefslogtreecommitdiff
path: root/sched.h
diff options
context:
space:
mode:
authorrpj <rpj>2001-07-03 02:00:09 +0000
committerrpj <rpj>2001-07-03 02:00:09 +0000
commit663a1af0674c37774d310541e9b30c60316f2055 (patch)
treec0f96f98c55cb98ecbd55dac2a5e1c60c00b280e /sched.h
parentc156eacc8b9c6f33f89c7563f2821320be79c2e1 (diff)
Cosmetic changes.
Diffstat (limited to 'sched.h')
-rw-r--r--sched.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/sched.h b/sched.h
index 870087f..23a43cb 100644
--- a/sched.h
+++ b/sched.h
@@ -66,8 +66,18 @@ int sched_setscheduler (pid_t pid, int policy);
int sched_getscheduler (pid_t pid);
+/*
+ * Note that this macro returns ENOTSUP rather than
+ * ENOSYS as might be expected. However, returning ENOSYS
+ * should mean that sched_get_priority_{min,max} are
+ * not implemented as well as sched_rr_get_interval.
+ * This is not the case, since we just don't support
+ * round-robin scheduling. Therefore I have chosen to
+ * return the same value as sched_setscheduler when
+ * SCHED_RR is passed to it.
+ */
#define sched_rr_get_interval(_pid, _interval) \
- ( errno = ENOSYS, (int) -1 )
+ ( errno = ENOTSUP, (int) -1 )
#ifdef __cplusplus