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

doc: conn_udp: document that send and receives needs to be called from the same thread #4993

Closed
OlegHahm opened this issue Mar 8, 2016 · 6 comments · Fixed by #4995
Closed
Assignees
Labels
Area: doc Area: Documentation Area: network Area: Networking

Comments

@OlegHahm
Copy link
Member

OlegHahm commented Mar 8, 2016

No description provided.

@OlegHahm OlegHahm added Area: network Area: Networking Area: doc Area: Documentation DocTF labels Mar 8, 2016
@miri64
Copy link
Member

miri64 commented Mar 8, 2016

That's rather GNRC specific... so I don't think conn_udp is the right place for that.

@miri64
Copy link
Member

miri64 commented Mar 8, 2016

(also it's more a bug than a feature, so I would rather fix that instead of documenting faulty behavior ;-))

@OlegHahm
Copy link
Member Author

OlegHahm commented Mar 8, 2016

Well, it is currently the case and confuses users...

@miri64
Copy link
Member

miri64 commented Mar 8, 2016

I have to solutions in my sleeve:

  • the fast and easy fix is to have thread running in gnrc_conn.c that acts as a supervisor for all connections and hands all received packets to the various registered connections (that's basically how I did it for emb6 and lwip, but I did not an extra thread since they are already single threaded and pretty much do all that for you)
  • the more sophisticated and memory saving method would be to use core: mbox: initial commit #4919 for that and give every connection it's own mbox. This would require an adaption to gnrc_netreg to also take mboxs into account.

@OlegHahm
Copy link
Member Author

OlegHahm commented Mar 8, 2016

Since neither the one nor the other solution exists, I would rather have this documented.

@miri64
Copy link
Member

miri64 commented Mar 8, 2016

Will provide one as soon as I find the time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: doc Area: Documentation Area: network Area: Networking
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants