Skip to content

Conversation

nordicjm
Copy link
Contributor

Adds queue functionality, taken from zephyr kernel code

@lemrey
Copy link
Contributor

lemrey commented Jun 12, 2025

We should definitely not have a /kernel folder here. For now, you could copy it as-is into the application folder where you need it and carry on.

Down the road, I think it would be best to make a generic queue library that has the same characteristic as this one (list based and dynamic, no-copy), and has its own bm_ API. Then we glue it to the k_queue APIs with macros. This way we could have a simpler library with no Zephyr leftovers, that would be more re-usable.

@nordicjm
Copy link
Contributor Author

nordicjm commented Jun 13, 2025

We should definitely not have a /kernel folder here. For now, you could copy it as-is into the application folder where you need it and carry on.

It's needed by multiple applications so that will not work, it needs a central location

Down the road, I think it would be best to make a generic queue library that has the same characteristic as this one (list based and dynamic, no-copy), and has its own bm_ API. Then we glue it to the k_queue APIs with macros. This way we could have a simpler library with no Zephyr leftovers, that would be more re-usable.

That's a no, this is needed for reuse of zephyr code as-is, as explained in the call. If you really want to rewrite it and verify it is functionally identical and that nothing breaks then you can do that, but I will not be doing that

@lemrey
Copy link
Contributor

lemrey commented Jun 15, 2025

It's needed by multiple applications so that will not work, it needs a central location

I see, thanks for clarifying. Please have a look if #162 would work for you.

@knutel-nordic
Copy link

Add link to the revision this was copied from?

@nordicjm nordicjm requested review from a team as code owners June 20, 2025 07:44
@nordicjm nordicjm changed the title kernel: Add queue functionality lib: Add zephyr queue functionality Jun 20, 2025
Copy link
Contributor

@eivindj-nordic eivindj-nordic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not reviewed very thoroughly as we plan to remove this when #162 is tested and ready.

@lemrey
Copy link
Contributor

lemrey commented Jun 20, 2025

Made a comment thinking it was a different PR, and have deleted it 🙊

@eivindj-nordic eivindj-nordic added this to the v0.9.0 milestone Jun 23, 2025
@eivindj-nordic
Copy link
Contributor

@nrfconnect/ncs-code-owners @nrfconnect/ncs-co-build-system Please review.

nordicjm added 2 commits June 25, 2025 11:37
Adds queue functionality, taken from zephyr kernel code

File taken from zephyr commit:
  6656c02fe4f2c0adfc5e0b5fba334c35fa5ecbd1

Signed-off-by: Jamie McCrae <[email protected]>
Assigns this to pluto

Signed-off-by: Jamie McCrae <[email protected]>
Allows for an apache 2.0 license on this file

Signed-off-by: Jamie McCrae <[email protected]>
@nordicjm nordicjm requested a review from a team as a code owner June 25, 2025 10:48
@eivindj-nordic eivindj-nordic removed the request for review from a team June 25, 2025 14:50
@eivindj-nordic eivindj-nordic merged commit babad7f into nrfconnect:main Jun 25, 2025
7 checks passed
@nordicjm nordicjm deleted the movepart04 branch August 15, 2025 10:44
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.

6 participants