Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

bradjc
Copy link
Contributor

@bradjc bradjc commented Jan 14, 2021

Pull Request Overview

As part of the effort to remove unsafe from the TBF parsing code (#1465), the last goal was always to move all of the TBF parsing code to its own library since by definition the kernel is not the only thing that needs to handle TBFs. Rather than have TBF code re-implemented, this would allow there to be a single TBF parsing crate that can be used by the kernel and also tools like elf2tab.

Turns out, moving this to a library is quite easy. I didn't want to do this earlier in case there were fixes or updates needed to the earlier tbf parsing re-write from #1465. But since the code has been working now seems like a reasonable time to move it to a library.

Apologies to @alistair23 for moving code, but I can help update if git doesn't do it automatically.

Testing Strategy

This pull request was tested by running kernels on nano33 and hail, but really this doesn't change any logic.

TODO or Help Wanted

n/a

Documentation Updated

  • Updated the relevant files in /docs, or no updates are required.

Formatting

  • Ran make prepush.

@github-actions github-actions bot added kernel tock-libraries This affects libraries supported by the Tock project labels Jan 14, 2021
hudson-ayers
hudson-ayers previously approved these changes Jan 14, 2021
Copy link
Contributor

@hudson-ayers hudson-ayers left a comment

Choose a reason for hiding this comment

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

This is great. Looks like git tracked the moved files correctly.

Nice to remove another nightly feature from the kernel crate (now people can't use it elsewhere in the kernel).

alistair23
alistair23 previously approved these changes Jan 15, 2021
@bradjc bradjc requested a review from jrvanwhy January 15, 2021 13:24
Turns out it is not actually needed.

Co-authored-by: Hudson Ayers <[email protected]>
@bradjc bradjc dismissed stale reviews from alistair23 and hudson-ayers via ef13e02 January 15, 2021 20:58
hudson-ayers
hudson-ayers previously approved these changes Jan 15, 2021
alistair23
alistair23 previously approved these changes Jan 15, 2021
@bradjc bradjc dismissed stale reviews from alistair23 and hudson-ayers via 684799f January 18, 2021 15:27
@bradjc
Copy link
Contributor Author

bradjc commented Jan 18, 2021

I added some structure to the tbf library crate. I moved the types into their own file, and all of the parsing code into its own file. This makes it much more straightforward to add code to create tbfs in the future.

@hudson-ayers hudson-ayers added the last-call Final review period for a pull request. label Jan 19, 2021
@hudson-ayers
Copy link
Contributor

bors r+

@bors
Copy link
Contributor

bors bot commented Jan 22, 2021

@bors bors bot merged commit 3165445 into master Jan 22, 2021
@bors bors bot deleted the tbf-library branch January 22, 2021 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kernel last-call Final review period for a pull request. tock-libraries This affects libraries supported by the Tock project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants