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

Consider simplifying the zero-copy SB API #1155

Closed
jphickey opened this issue Feb 4, 2021 · 1 comment · Fixed by #1257 or #1258
Closed

Consider simplifying the zero-copy SB API #1155

jphickey opened this issue Feb 4, 2021 · 1 comment · Fixed by #1257 or #1258
Assignees
Milestone

Comments

@jphickey
Copy link
Contributor

jphickey commented Feb 4, 2021

Is your feature request related to a problem? Please describe.
After some refactoring in PR #1154 the whole CFE_SB_ZeroCopyHandle_t has become somewhat extraneous - there is no extra handle/descriptor for a zero copy buffer - they are all the same, and this simply refers to the same buffer descriptor now.

Describe the solution you'd like
The API can be simplified and this extra handle removed. The buffer content pointer is good enough to reconstitute the descriptor pointer (fixed offset).

Describe alternatives you've considered
Leave API as is (backward compatible, just a little more complex than it needs to be).

Additional context
This will affect public APIs - CFE_SB_ZeroCopyGetPtr, CFE_SB_ZeroCopyReleasePtr, CFE_SB_TransmitBuffer. (CFE_SB_ZeroCopySend and CFE_SB_ZeroCopyPass are affected but already deprecated).

Requester Info
Joseph Hickey, Vantage Systems, Inc.

@skliper skliper added this to the 7.0.0 milestone Feb 5, 2021
@skliper
Copy link
Contributor

skliper commented Feb 5, 2021

I'd like to fit this in Caelum if we can, lower priority than the rest but a goal.

jphickey added a commit to jphickey/cFE that referenced this issue Mar 23, 2021
The separate zero copy handle type is removed.

Adds two new simplified functions CFE_SB_AllocateMessageBuffer
and CFE_SB_ReleaseMessageBuffer to replace CFE_SB_ZeroCopyGetPtr
and CFE_SB_ZeroCopyGetPtr.  These new functions do not use
a separate Handle.

Updates the CFE_SB_TransmitBuffer() API to also remove the handle.
astrogeco added a commit that referenced this issue Mar 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants