Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 08 Jan 2016 18:29:38 +0000
From:      bugzilla-noreply@freebsd.org
To:        freebsd-doc@FreeBSD.org
Subject:   [Bug 206040] sleepqueue man page describes priority arguments wrong.
Message-ID:  <bug-206040-9@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D206040

            Bug ID: 206040
           Summary: sleepqueue man page describes priority arguments
                    wrong.
           Product: Documentation
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Some People
          Priority: ---
         Component: Documentation
          Assignee: freebsd-doc@FreeBSD.org
          Reporter: david.reed@tidalscale.com

sleepq_signal, sleepq_broadcast both take a "pri" argument.  The man page s=
ays
that if -1 is passed there will be no priority change, otherwise the pri va=
lue
will set the priority of all threads being signaled to pri.

However, if one looks at the code that uses the pri argument in sleepq_resu=
me,
the actual logic can be described by this sentence:

"If pri is 0, the threads that are signaled will awake with priority unchan=
ged.
Otherwise, if a thread is in priority class TIMESHARE, and a thread has a l=
ower
TIMESHARE priority (larger value than pri) that thread's priority will be s=
et
to pri. pri must either be between MIN_PRI and MAX_PRI, or zero."

I'd be happy if this simple fix to the document were made, and backported to
10.2 as well.  Feel free to use the wording above.

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-206040-9>