-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wrong usage of NXSEM_INITIALIZER #6084
Comments
This was referenced Apr 16, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
During code review I've noticed that few places in code use
NXSEM_INITIALIZER(0, SEM_PRIO_NONE)
as static initializer. Those places are:fs/aio/aio_initialize.c
:sched/wqueue/kwork_thread.c
:Such usage is wrong as
SEM_PRIO_NONE
is defined to0
ininclude/semaphore.h
:#define SEM_PRIO_NONE 0
soNXSEM_INITIALIZER
sets theflags
member ofstruct sem_s
to zero and what meansSEM_PRIO_INHERIT
ifCONFIG_PRIORITY_INHERITANCE=y
due toPRIOINHERIT_FLAGS_DISABLE
is not set:The text was updated successfully, but these errors were encountered: