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

Fix #1021, pool buffer type #1025

Merged
merged 2 commits into from
Dec 7, 2020

Conversation

jphickey
Copy link
Contributor

Describe the contribution

Use a generic void* as the interface type for the pool buffer pointers. This reduces the need for local type casting in the apps and makes it generally easier to use.

Fixes #1021

Testing performed
Build and sanity test CFE
Run all unit tests

Expected behavior changes
No impact to behavior.

System(s) tested on
Ubuntu 20.04

Additional context
Note that getting a buffer in one step still requires a type cast, as the interface here is really void**. However when putting or querying a buffer no cast is needed. One can also avoid the need to cast if they get a buffer in two steps (i.e. get as void* first, then convert to real type with a simple assignment.

Contributor Info - All information REQUIRED for consideration of pull request
Joseph Hickey, Vantage Systems, Inc.

@jphickey
Copy link
Contributor Author

Real commit is in 3e347e5, need to get a new baseline first to avoid conflicts.

This can be reviewed but it will need a rebase before final merging.

@jphickey jphickey changed the title Fix 1021 poolbuf ptr Fix #1021, pool buffer type Nov 18, 2020
@jphickey jphickey added the CCB:Ready Ready for discussion at the Configuration Control Board (CCB) label Nov 18, 2020
@astrogeco
Copy link
Contributor

CCB 2020-11-18 APPROVED

  • @jphickey to rebase so we can include it in this merge cycle

astrogeco and others added 2 commits December 2, 2020 10:30
cFE Integration Candidate: 2020-11-24
Using void* instead of uint32* here makes the interface
easier to use and may avoid some nuisance alignment warnings.
@jphickey jphickey force-pushed the fix-1021-poolbuf-ptr branch from 3e347e5 to 1f8f082 Compare December 2, 2020 15:33
@jphickey jphickey marked this pull request as ready for review December 2, 2020 15:33
@jphickey
Copy link
Contributor Author

jphickey commented Dec 2, 2020

Rebased and ready to go.

@astrogeco astrogeco added CCB-20201202 and removed CCB:Ready Ready for discussion at the Configuration Control Board (CCB) labels Dec 2, 2020
@astrogeco
Copy link
Contributor

CCB 2020-12-02 Minor Cleanup

@astrogeco astrogeco changed the base branch from main to integration-candidate December 7, 2020 14:25
@astrogeco astrogeco merged commit 2f92178 into nasa:integration-candidate Dec 7, 2020
astrogeco added a commit to astrogeco/cFS that referenced this pull request Dec 7, 2020
@jphickey jphickey deleted the fix-1021-poolbuf-ptr branch February 1, 2021 19:46
@skliper skliper added this to the 7.0.0 milestone Sep 24, 2021
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.

Pool buffers should not use uint32* as interface type
3 participants