Skip to content
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

[DRAFT] Backport semaphore fixes #188

Draft
wants to merge 5 commits into
base: px4_firmware_nuttx-10.1.0+
Choose a base branch
from

Conversation

ThomasDebrunner
Copy link
Member

@ThomasDebrunner ThomasDebrunner commented Jun 9, 2022

Summary

Backport of apache/nuttx#5171 and draft apache/nuttx#6318

Impact

This should resolve priority inheritance issues

Testing

Tested against adverse example. Not flight tested.

ThomasDebrunner and others added 5 commits June 9, 2022 17:11
Add a list in TCB to track all semphores the task held, so we
can release all holders when exit, so nxsched_verify_tcb
is unnecessary.

Signed-off-by: Zeng Zhaoxiu <[email protected]>
1. The task which called nxsem_release_holder may not be a holder of the semaphore,
   counts of the holder would not be decreamented.
   This commit try to resolve the problem if there is only one holder.
2. Avoid counts overflow.

Signed-off-by: Zeng Zhaoxiu <[email protected]>
@pkarashchenko
Copy link
Contributor

There probably is a typo in summary. The priority inheritance PR is apache/nuttx#6318

@ThomasDebrunner
Copy link
Member Author

Thanks, updated

@davids5
Copy link
Member

davids5 commented Jun 17, 2022

@ThomasDebrunner Is this Additional change Needed as well?

PX4BuildBot pushed a commit that referenced this pull request Aug 24, 2024
"net/netdev_upperhalf.c", line 133: warning #188-D: enumerated type mixed with
          another type
        total += netdev_lower_quota_load(lower, type);

CC:  dirent/lib_alphasort.c "spi/spi_transfer.c", line 83: warning #188-D: enumerated type mixed with
          another type
    SPI_SETMODE(spi, seq->mode);
    ^

Signed-off-by: guoshichao <[email protected]>
PX4BuildBot pushed a commit that referenced this pull request Aug 24, 2024
CC:  irq/irq_initialize.c "ioexpander/gpio.c", line 386: warning #188-D: enumerated type mixed with
          another type
            *ptr = dev->gp_pintype;
                 ^

Signed-off-by: guoshichao <[email protected]>
PX4BuildBot pushed a commit that referenced this pull request Aug 26, 2024
… warnings

"/mnt/yang/qixinwei_cmake/nuttx/sched/sched/sched_removeblocked.c", line 58: warning #188-D:
          enumerated type mixed with another type
    tstate_t task_state = btcb->task_state;
"/mnt/yang/qixinwei_cmake/nuttx/sched/sched/sched_setpriority.c", line 243: warning #188-D:
          enumerated type mixed with another type
    tstate_t task_state = tcb->task_state;

Signed-off-by: yanghuatao <[email protected]>
PX4BuildBot pushed a commit that referenced this pull request Sep 19, 2024
CC:  obstack/lib_obstack_printf.c "mmap/fs_rammap.c", line 126: warning #188-D: enumerated type mixed with
          another type
    enum mm_map_type_e type = (uintptr_t)entry->priv.p & 3;
                              ^

Signed-off-by: guoshichao <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants