Skip to content

Conversation

jori-nordic
Copy link
Contributor

Work items on the syswq should always run-to-completion.

Override the timeout value to always be K_NO_WAIT.

Allocating with K_FOREVER leads to deadlocks if the freeing also happens from the syswq. Non-zero timeouts are also not nice for the other users of the syswq.

@zephyrbot zephyrbot added the area: Networking Buffers net_buf/net_buf_simple API & implementation label Apr 19, 2024
@jori-nordic jori-nordic force-pushed the buf-alloc-dont-wait-in-syswq branch from 94de455 to a280b3a Compare April 19, 2024 11:22
@jhedberg
Copy link
Member

@jori-nordic CI is failing due to a misspelled word. The change itself looks fine to me.

@jori-nordic jori-nordic force-pushed the buf-alloc-dont-wait-in-syswq branch from a280b3a to b34f994 Compare April 22, 2024 14:54
@jori-nordic
Copy link
Contributor Author

@jhedberg fixed, thanks

Copy link
Member

Choose a reason for hiding this comment

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

Minor nit, we usually have net: prefix instead of "networking" in commit subject that are related to networking files.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

got it, fixed 👍

Copy link
Contributor Author

@jori-nordic jori-nordic Apr 23, 2024

Choose a reason for hiding this comment

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

ah shoot looks like the CI re-runs when you only update the commit message. @stephanosio do you think we could make it so we only run the compliance in those cases?

Work items on the syswq should always run-to-completion.

Override the timeout value to always be K_NO_WAIT.

Allocating with K_FOREVER leads to deadlocks if the freeing also happens
from the syswq. Non-zero timeouts are also not nice for the other users
of the syswq.

Signed-off-by: Jonathan Rico <jonathan.rico@nordicsemi.no>
@jori-nordic jori-nordic force-pushed the buf-alloc-dont-wait-in-syswq branch from b34f994 to d4d5301 Compare April 23, 2024 06:40
@jori-nordic jori-nordic changed the title networking: buf: Disallow blocking allocation in syswq net: buf: Disallow blocking allocation in syswq Apr 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: Networking Buffers net_buf/net_buf_simple API & implementation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants