-
Notifications
You must be signed in to change notification settings - Fork 2k
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
periph/flashpage: remove deprecated flashpage_*_free functions #18093
periph/flashpage: remove deprecated flashpage_*_free functions #18093
Conversation
Those functions came in handy to get the current image with |
If we need a way to tell which flash pages correspond to the text section, let's use that (introducing first_used / last_used, or just feed the relevant linker symbols through the mapped address to flash page conversion -- a bootloader needs to understand some section stuff anyway). These functions invite usage patterns that conflict between parts of an application, and should go. |
I can change the functions to reflect this but it should be first_used / last_used based on the whole firmware not just the .text section right ? |
That's really what whoever does the firmware dump needs to concern itself with (is it dumping firmware? or everything allocated by the linker? also pages used through the deprecated functions? or the full ROM?) -- another reason why I'd rather not have these functions used for that purpose. |
@benpicco what is your opinion? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me (didn't test, all relevant tests should be doable by CI), please rebase and let's get this merged.
tests/periph_flashpage/main.c
Outdated
@@ -31,6 +31,14 @@ | |||
|
|||
#define LINE_LEN (16) | |||
|
|||
/* For MSP430 cpu's the last page holds the interrupt vector, although the api |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should fix our tests to not depend on this, but while they are as they are, this looks like a viable workaround.
@benpicco what is your call ? If you are fine with the functions being removed I will rebase. |
But since that has not been merged and there is currently no use for this, I'm fine with dropping those functions. I can re-introduce the function under a different name if the need for single-slot updates with external storage arises again. |
9b63368
to
10c987e
Compare
I think that's unrelated. We might have bug in the samr21-xpro timer implementation, maybe related to #10019 |
The problem was probably fixed in #20548. |
All green now :) |
Contribution description
With the 2022.04 release being out this PR removes the
flashpage_*_free
functions deprecated with #17860.I reverted all the changes I introduced with #16972 except for be254d4 since I this was a kind of fix that is still valid in my opinion.
Testing procedure
tests/periph_flashpage
Issues/PRs references
#17860
#16972