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

Make cpuload correct and more efficient for all configurations of NuttX #81

Merged
merged 1 commit into from
Jul 9, 2013
Merged

Make cpuload correct and more efficient for all configurations of NuttX #81

merged 1 commit into from
Jul 9, 2013

Conversation

FreddieChopin
Copy link
Contributor

Currently cpuload assumes there are only 2 static threads - idle and init, this
is true only for "basic" config of NuttX, as there can be 3 more static threads:
paging, work0 and work1 - depending on config. In such cases cpuload
would mistake one of them for init (which in fact is always last), giving
incorrect results to "top"

Signed-off-by: Freddie Chopin [email protected]

Currently cpuload assumes there are only 2 static threads - idle and init, this
is true only for "basic" config of NuttX, as there can be 3 more static threads:
paging, work0 and work1 - depending on config. In such cases cpuload
would mistake one of them for init (which in fact is always last), giving
incorrect results to "top"

Signed-off-by: Freddie Chopin <[email protected]>
@LorenzMeier
Copy link
Member

This will be merged on the next merge window, which likely is in 9 days. The contribution is highly appreciated.

@px4dev
Copy link
Contributor

px4dev commented Dec 23, 2012

I think this is actually the wrong way to go about it.

Instead of statically configuring the 'magic' tasks, the sched_note_switch implementation should just create them lazily as and when it sees a task it doesn't recognise. This would insulate the code from changes in NuttX that might otherwise be confusing later.

@FreddieChopin
Copy link
Contributor Author

It's better than current code anyway - so an improvement (;

@LorenzMeier
Copy link
Member

Hi Freddie,

Sorry that it took forever. We were looking into fixing this more generic, but since we never got around to it we just should have applied the patch, and worked from there.

Thanks!

@LorenzMeier LorenzMeier merged commit e5c7ae4 into PX4:master Jul 9, 2013
PX4BuildBot added a commit that referenced this pull request Jan 29, 2019
    - genmsg in PX4/Firmware (fe35896): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Jan 29, 2019
    - genmsg in PX4/Firmware (8b2371f): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Jan 30, 2019
    - genmsg in PX4/Firmware (3079aa5): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Jan 30, 2019
    - genmsg in PX4/Firmware (b8356b0): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Jan 31, 2019
    - genmsg in PX4/Firmware (e67c62e): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Jan 31, 2019
    - genmsg in PX4/Firmware (a9c98e8): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 2, 2019
    - genmsg in PX4/Firmware (8a66b9e): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 2, 2019
    - genmsg in PX4/Firmware (31f9983): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 3, 2019
    - genmsg in PX4/Firmware (aefe354): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 4, 2019
    - genmsg in PX4/Firmware (ec3f08c): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 4, 2019
    - genmsg in PX4/Firmware (221bc16): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 5, 2019
    - genmsg in PX4/Firmware (a8f01a2): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Feb 6, 2019
    - genmsg in PX4/Firmware (d433877): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
dagar added a commit that referenced this pull request Feb 6, 2019
    - genmsg in PX4/Firmware (d433877): ros/genmsg@42e3646
    - genmsg current upstream: ros/genmsg@5736b1f
    - Changes: ros/genmsg@42e3646...5736b1f

    5736b1f 2019-01-28 Dirk Thomas - add missing run_depend on empy (#81)
PX4BuildBot added a commit that referenced this pull request Aug 23, 2019
    - matrix in PX4/Firmware (f29f329): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@84b3da2
    - Changes: PX4/PX4-Matrix@56b0699...84b3da2

    84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 24, 2019
    - matrix in PX4/Firmware (17fab59): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@84b3da2
    - Changes: PX4/PX4-Matrix@56b0699...84b3da2

    84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 24, 2019
    - matrix in PX4/Firmware (1711847): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@84b3da2
    - Changes: PX4/PX4-Matrix@56b0699...84b3da2

    84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 26, 2019
    - matrix in PX4/Firmware (1da5edd): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@84b3da2
    - Changes: PX4/PX4-Matrix@56b0699...84b3da2

    84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 26, 2019
    - matrix in PX4/Firmware (2d77055): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@84b3da2
    - Changes: PX4/PX4-Matrix@56b0699...84b3da2

    84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 27, 2019
    - matrix in PX4/Firmware (6fe57cc): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 27, 2019
    - matrix in PX4/Firmware (201987c): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 28, 2019
    - matrix in PX4/Firmware (6f0351d): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 28, 2019
    - matrix in PX4/Firmware (4ec5dd7): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
PX4BuildBot added a commit that referenced this pull request Aug 29, 2019
    - matrix in PX4/Firmware (341c0ae): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
dagar pushed a commit that referenced this pull request Aug 29, 2019
    - matrix in PX4/Firmware (341c0ae): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (#81)
bozkurthan pushed a commit to bozkurthan/Firmware that referenced this pull request Sep 4, 2019
    - matrix in PX4/Firmware (341c0ae): PX4/PX4-Matrix@56b0699
    - matrix current upstream: PX4/PX4-Matrix@cc084e0
    - Changes: PX4/PX4-Matrix@56b0699...cc084e0

    cc084e0 2019-08-26 Martina Rivizzigno - matrix: add method to check all values are nan (PX4#82)
84b3da2 2019-08-22 kritz - Canonical Quaternion with tests (PX4#81)
dagar pushed a commit to dagar/PX4-Firmware that referenced this pull request Jul 23, 2021
dagar pushed a commit that referenced this pull request Oct 16, 2024
Returning meaningful error codes from STM32 CAN driver methods
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.

3 participants