Skip to content

Tools: Reoder post-build hooks and bl merging #9738

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

Merged
merged 16 commits into from
Mar 6, 2019

Conversation

theotherjimmy
Copy link
Contributor

@theotherjimmy theotherjimmy commented Feb 15, 2019

Description

On current master, post-build hooks are run before any merging that
managed bootloader mode would do. This puts several targets in a hard
place: they need the post-build hook to run to complute a digest of
the ROM, but when using managed bl mode, these digests are incorrect.

This PR reorders the post-build hooks to run after the merging of
managed bootloader mode, and on the "Image" (as opposed to the
"Update Image"). This should allow post build hooks that generate a
digest of the ROM to compute a correct digest.

Pull request type

[x] Fix
[ ] Refactor
[ ] Target update
[ ] Functionality change
[ ] Docs update
[ ] Test update
[ ] Breaking change

Reviewers

@bridadan, For tools changes
@ARMmbed/mbed-os-storage , This team raised the issue

@cmonr cmonr requested review from bridadan and a team February 15, 2019 15:22
Copy link
Contributor

@bridadan bridadan left a comment

Choose a reason for hiding this comment

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

Nicely done!

# Initialize memap and process map file. This doesn't generate output.
self.mem_stats(mapfile)

self.notify.var("compile_succeded", True)
self.notify.var("binary", filename)

return full_path, needed_update
return full_path, updatable
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we drop needed_update completely then? Doesn't seem to be used in this function.

Also, I can't find a call in our code base that actually uses the updatable result from link_program(). Is it possible to remove it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes. We can remove that too. We may have to update the online compiler to use this new API.

@theotherjimmy
Copy link
Contributor Author

@bridadan Ready for review again, supposing that travis passes.

Copy link
Contributor

@bridadan bridadan left a comment

Choose a reason for hiding this comment

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

Good stuff!

@cmonr
Copy link
Contributor

cmonr commented Feb 19, 2019

@ARMmbed/mbed-os-storage Please review.

@cmonr
Copy link
Contributor

cmonr commented Feb 25, 2019

Still waiting on a review by @ARMmbed/mbed-os-storage

@bulislaw Fyi

@cmonr
Copy link
Contributor

cmonr commented Feb 25, 2019

@theotherjimmy And now this needs a rebase.

@theotherjimmy
Copy link
Contributor Author

@cmonr Rebase done.

@cmonr
Copy link
Contributor

cmonr commented Feb 25, 2019

CI started assuming @ARMmbed/mbed-os-storage will eventually_ be ok with this PR.

@mbed-ci
Copy link

mbed-ci commented Feb 26, 2019

Test run: FAILED

Summary: 3 of 8 test jobs failed
Build number : 2
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_build-GCC_ARM
  • jenkins-ci/mbed-os-ci_build-ARM
  • jenkins-ci/mbed-os-ci_build-IAR

@bulislaw
Copy link
Member

bulislaw commented Feb 26, 2019

This PR is at risk of missing 5.12 release as it's marked as "needs: work". Code freeze is coming! On Friday 1st. Please make necessary updates ASAP and make sure the reviewers are aligned for prompt code inspection.

@yossi2le
Copy link
Contributor

This PR looks fine for me. @theotherjimmy, I have only one question. The changes here originated from the need to compile and build FUTURE_SEQUANA_PSA with bootloader support. in order to do so @bridadan helped us with some tweaks and changes. are all those changes included in the PR or they are not needed here?

@dannybenor
Copy link

@bulislaw please be aware that this PR is related to PSA, and we may need additional changes when the platforms code will be available

@theotherjimmy
Copy link
Contributor Author

Errors seem to be CI passing in unsupported platforms.

@theotherjimmy
Copy link
Contributor Author

@dannybenor You may need additional PRs. This change is complete as is, so long as no bugs are found around the reordering. Please don't hold PRs because you might find that you need changes related to them.

@theotherjimmy
Copy link
Contributor Author

@yossi2le You're going to have to remind me what those changes are. They probably should come in as other PRs though.

@cmonr
Copy link
Contributor

cmonr commented Feb 27, 2019

@bulislaw please be aware that this PR is related to PSA, and we may need additional changes when the platforms code will be available

@dannybenor Which is when? We're running out of days before code freeze...

@cmonr
Copy link
Contributor

cmonr commented Feb 27, 2019

@theotherjimmy This needs a rebase.

@theotherjimmy
Copy link
Contributor Author

@cmonr rebase done

@adbridge
Copy link
Contributor

adbridge commented Mar 4, 2019

Ci started

@mbed-ci
Copy link

mbed-ci commented Mar 4, 2019

Test run: SUCCESS

Summary: 13 of 13 test jobs passed
Build number : 5
Build artifacts

@cmonr
Copy link
Contributor

cmonr commented Mar 4, 2019

CI job restarted: jenkins-ci/exporter

Job config was updated to properly run against list of targets instead of an empty list.

@cmonr
Copy link
Contributor

cmonr commented Mar 4, 2019

Hmmm.... Trying a complete rebuild.

Suspect that the export fix that was recently applied didn't quite do the job.

@cmonr
Copy link
Contributor

cmonr commented Mar 4, 2019

CI restarted

@mbed-ci
Copy link

mbed-ci commented Mar 4, 2019

Test run: FAILED

Summary: 1 of 13 test jobs failed
Build number : 6
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_exporter

@cmonr
Copy link
Contributor

cmonr commented Mar 6, 2019

CI restarted.
Merge commit needs to use updated master

@mbed-ci
Copy link

mbed-ci commented Mar 6, 2019

Test run: FAILED

Summary: 1 of 13 test jobs failed
Build number : 7
Build artifacts

Failed test jobs:

  • jenkins-ci/mbed-os-ci_exporter

@0xc0170
Copy link
Contributor

0xc0170 commented Mar 6, 2019

exporters green 👍

@0xc0170 0xc0170 merged commit 9d72a5c into ARMmbed:master Mar 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants