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

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

Merged
merged 16 commits into from Mar 6, 2019

Conversation

Projects
None yet
10 participants
@theotherjimmy
Copy link
Contributor

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 added the needs: review label Feb 15, 2019

@cmonr cmonr requested review from bridadan and ARMmbed/mbed-os-storage Feb 15, 2019

@bridadan
Copy link
Contributor

left a comment

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

This comment has been minimized.

Copy link
@bridadan

bridadan Feb 15, 2019

Contributor

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?

This comment has been minimized.

Copy link
@theotherjimmy

theotherjimmy Feb 19, 2019

Author Contributor

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

@theotherjimmy

This comment has been minimized.

Copy link
Contributor Author

commented Feb 19, 2019

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

@bridadan
Copy link
Contributor

left a comment

Good stuff!

@cmonr

This comment has been minimized.

Copy link
Contributor

commented Feb 19, 2019

@ARMmbed/mbed-os-storage Please review.

@cmonr

This comment has been minimized.

Copy link
Contributor

commented Feb 25, 2019

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

@bulislaw Fyi

@cmonr

This comment has been minimized.

Copy link
Contributor

commented Feb 25, 2019

@theotherjimmy And now this needs a rebase.

@cmonr cmonr added needs: work and removed needs: review labels Feb 25, 2019

@theotherjimmy theotherjimmy force-pushed the theotherjimmy:reorder-bl-hooks branch Feb 25, 2019

@theotherjimmy

This comment has been minimized.

Copy link
Contributor Author

commented Feb 25, 2019

@cmonr Rebase done.

@cmonr

This comment has been minimized.

Copy link
Contributor

commented Feb 25, 2019

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

@mbed-ci

This comment has been minimized.

Copy link

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

This comment has been minimized.

Copy link
Member

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

This comment has been minimized.

Copy link
Contributor

commented Feb 26, 2019

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

This comment has been minimized.

Copy link

commented Feb 26, 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

@theotherjimmy

This comment has been minimized.

Copy link
Contributor Author

commented Feb 26, 2019

Errors seem to be CI passing in unsupported platforms.

@theotherjimmy

This comment has been minimized.

Copy link
Contributor Author

commented Feb 26, 2019

@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

This comment has been minimized.

Copy link
Contributor Author

commented Feb 26, 2019

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

@theotherjimmy theotherjimmy force-pushed the theotherjimmy:reorder-bl-hooks branch Feb 26, 2019

@cmonr

This comment has been minimized.

Copy link
Contributor

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

This comment has been minimized.

Copy link
Contributor

commented Feb 27, 2019

@theotherjimmy This needs a rebase.

@theotherjimmy theotherjimmy force-pushed the theotherjimmy:reorder-bl-hooks branch Feb 27, 2019

@theotherjimmy

This comment has been minimized.

Copy link
Contributor Author

commented Feb 27, 2019

@cmonr rebase done

@0xc0170 0xc0170 added needs: review and removed needs: work labels Feb 27, 2019

@theotherjimmy theotherjimmy force-pushed the theotherjimmy:reorder-bl-hooks branch to c9b613c Mar 4, 2019

@adbridge

This comment has been minimized.

Copy link
Contributor

commented Mar 4, 2019

Ci started

@mbed-ci

This comment has been minimized.

Copy link

commented Mar 4, 2019

Test run: SUCCESS

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

@cmonr

This comment has been minimized.

Copy link
Contributor

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

This comment has been minimized.

Copy link
Contributor

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

This comment has been minimized.

Copy link
Contributor

commented Mar 4, 2019

CI restarted

@mbed-ci

This comment has been minimized.

Copy link

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

This comment has been minimized.

Copy link
Contributor

commented Mar 6, 2019

CI restarted.
Merge commit needs to use updated master

@mbed-ci

This comment has been minimized.

Copy link

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

This comment has been minimized.

Copy link
Member

commented Mar 6, 2019

exporters green 👍

@0xc0170 0xc0170 added ready for merge and removed needs: CI labels Mar 6, 2019

@0xc0170 0xc0170 merged commit 9d72a5c into ARMmbed:master Mar 6, 2019

28 checks passed

continuous-integration/jenkins/pr-head This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
jenkins-ci/build-ARMC5 Success
Details
jenkins-ci/build-ARMC6 Success
Details
jenkins-ci/build-GCC_ARM Success
Details
jenkins-ci/build-IAR8 Success
Details
jenkins-ci/cloud-client-test Success
Details
jenkins-ci/dynamic-memory-usage RTOS ROM(+0 bytes) RAM(+0 bytes)
Details
jenkins-ci/exporter Success
Details
jenkins-ci/greentea-test Success
Details
jenkins-ci/mbed2-build-ARMC5 Success
Details
jenkins-ci/mbed2-build-ARMC6 Success
Details
jenkins-ci/mbed2-build-GCC_ARM Success
Details
jenkins-ci/mbed2-build-IAR8 Success
Details
jenkins-ci/unittests Success
Details
travis-ci/astyle Local astyle testing has passed
Details
travis-ci/docs Local docs testing has passed
Details
travis-ci/doxy-spellcheck Local doxy-spellcheck testing has passed
Details
travis-ci/events Passed, runtime is 9339 cycles (-1192 cycles)
Details
travis-ci/gitattributestest Local gitattributestest testing has passed
Details
travis-ci/include_check Local include_check testing has passed
Details
travis-ci/licence_check Local licence_check testing has passed
Details
travis-ci/littlefs Passed, code size is 8408B (+0.00%)
Details
travis-ci/psa-autogen Local psa-autogen testing has passed
Details
travis-ci/tools-py2.7 Local tools-py2.7 testing has passed
Details
travis-ci/tools-py3.5 Local tools-py3.5 testing has passed
Details
travis-ci/tools-py3.6 Local tools-py3.6 testing has passed
Details
travis-ci/tools-py3.7 Local tools-py3.7 testing has passed
Details

@0xc0170 0xc0170 removed the ready for merge label Mar 6, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.