1.\" $OpenBSD: sched_get_priority_min.3,v 1.1 2010/11/07 20:18:22 deraadt Exp $ 2.\" 3.\" Copyright (c) 2010 Federico G. Schwindt <fgsch@openbsd.org> 4.\" 5.\" Permission to use, copy, modify, and distribute this software for 6.\" any purpose with or without fee is hereby granted, provided that 7.\" the above copyright notice and this permission notice appear in all 8.\" copies. 9.\" 10.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL 11.\" WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED 12.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE 13.\" AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL 14.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA 15.\" OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER 16.\" TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 17.\" PERFORMANCE OF THIS SOFTWARE. 18.\" 19.Dd $Mdocdate: November 7 2010 $ 20.Dt SCHED_GET_PRIORITY_MIN 3 21.Os 22.Sh NAME 23.Nm sched_get_priority_max , 24.Nm sched_get_priority_min 25.Nd get priority limits 26.Sh SYNOPSIS 27.Fd #include <sched.h> 28.Ft int 29.Fn sched_get_priority_max "int policy" 30.Ft int 31.Fn sched_get_priority_min "int policy" 32.Sh DESCRIPTION 33The 34.Fn sched_get_priority_max 35and 36.Fn sched_get_priority_min 37functions return the maximum and minimum priority values, respectively, 38for the scheduling policy specified by 39.Fa policy . 40.Pp 41The scheduling policy for a thread can either be 42.Dv SCHED_FIFO 43(first in, first out), 44.Dv SCHED_RR 45(round-robin) or 46.Dv SCHED_OTHER . 47.Sh RETURN VALUES 48Upon successful completion, 49.Fn sched_get_priority_max 50and 51.Fn sched_get_priority_min 52return the maximum and minimum priority values, respectively. 53Otherwise, a value of \-1 is returned and errno is set to indicate the error. 54.Sh ERRORS 55The 56.Fn sched_get_priority_max 57and 58.Fn sched_get_priority_min 59functions will fail if: 60.Bl -tag -width Er 61.It Bq Er EINVAL 62Invalid value for 63.Fa policy . 64.El 65.Sh STANDARDS 66The 67.Fn sched_get_priority_max 68and 69.Fn sched_get_priority_min 70functions conform to 71.St -p1003.1-2008 . 72.Pp 73This implementation does not support process scheduling. 74