SCHED_G...ITY_MAX(3POSIX)

SCHED_GET_PRIORITY_MAX(3POSIX) πŸ’–

okay bestie, we're reading the POSIX Programmer's Manual today, and this little page is all about sched_get_priority_max and sched_get_priority_min β€” the two functions that tell you where the priority ceiling and floor live for a scheduling policy. it's giving "small but mighty" fr fr ✨


PROLOG 🫢

so like, heads up before we even start: this manual page is part of the POSIX Programmer's Manual. the Linux implementation of this interface may differ β€” so if you're on Linux, go peek at the corresponding Linux manual page for the real tea β€” or the interface might not even be implemented on Linux at all. no cap. πŸ’€


NAME πŸ‘‘

sched_get_priority_max, sched_get_priority_min β€” get priority limits (REALTIME) πŸ’…


SYNOPSIS πŸŽ€

#include <sched.h>

int sched_get_priority_max(int policy);
int sched_get_priority_min(int policy);

DESCRIPTION πŸ¦‹

okay so here's the vibe: sched_get_priority_max() and sched_get_priority_min() shall return the appropriate maximum or minimum, respectively, for the scheduling policy that you pass in as policy. slay.

and the value of policy shall be one of the scheduling policy values defined in <sched.h>. that's the whole assignment bestie, that's it πŸ’–


RETURN VALUE ✨

if it works? sched_get_priority_max() and sched_get_priority_min() shall return the appropriate maximum or minimum values, respectively. iconic.

if it does NOT work? they shall return a value of -1 and set errno to indicate the error. not the moment. 😭


ERRORS πŸ’€

sched_get_priority_max() and sched_get_priority_min() functions shall fail if:

  • EINVAL β€” the value of the policy parameter does not represent a defined scheduling policy. like, she's not on the list bestie, she's a stranger 🚫
heads up: the following sections are informative. (translation: the rest is bonus content, not rules πŸ’…)

EXAMPLES 🌈

None. (yes queen, nothing. we move πŸŽ€)


APPLICATION USAGE 🌸

None. (again, nothing. the page said what it said and dipped ✨)


RATIONALE 🧚

None. (nope, no reasoning given. mysterious main character energy fr 😌)


FUTURE DIRECTIONS ⭐

None. (the future is a blank canvas, bestie πŸ¦‹)


SEE ALSO πŸ”₯

  • sched_getparam()
  • sched_setparam()
  • sched_getscheduler()
  • sched_rr_get_interval()
  • sched_setscheduler()
  • the Base Definitions volume of POSIX.1‐2017, <sched.h>

like, go read those too, they're the friend group πŸ’œ


Portions of this text are reprinted and reproduced in electronic form from IEEE Std 1003.1-2017, Standard for Information Technology -- Portable Operating System Interface (POSIX), The Open Group Base Specifications Issue 7, 2018 Edition, Copyright (C) 2018 by the Institute of Electrical and Electronics Engineers, Inc and The Open Group. In the event of any discrepancy between this version and the original IEEE and The Open Group Standard, the original IEEE and The Open Group Standard is the referee document. The original Standard can be obtained online at http://www.opengroup.org/unix/online.html .

Any typographical or formatting errors that appear in this page are most likely to have been introduced during the conversion of the source files to man page format. To report such errors, see https://www.kernel.org/doc/man-pages/reporting_bugs.html .


and that's the whole page bestie!! this one came from IEEE/The Open Group, dated 2017 β€” so like, vintage but still serving. thanks for reading with me, mwah πŸ’–πŸŽ€βœ¨