forked from project-chip/connectedhomeip
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace the EndPoint::PrepareIO() functions with stored state
#### Problem Currently, the socket-based networking implementation calls `PrepareIO()` on each endpoint to determine file descriptor sets for `select()`. This usually does redundant work (since the conditions only change on endpoint state changes) and is not usable by event-based interfaces (e.g. epoll/kqueue and libraries like libevent/libev/libuv) – see issue project-chip#5556 _rework system layer event loop_. #### Summary of Changes - Maintain the required flags in an endpoint member, `mRequestIO`, in place of recalculating them in `PrepareIO()`. (The points where `mRequestIO` is changed are the points where an event-based interface would be invoked.) - For UDP and Raw endpoints, pass callbacks to `Listen()` rather than setting members separately, to avoid any possiblity of races in a less synchronous environment. Part of issue project-chip#5556 _rework system layer event loop_.
- Loading branch information
1 parent
2b6cc31
commit 7eb4869
Showing
16 changed files
with
111 additions
and
89 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.