Skip to content

Conversation

@marc-hb
Copy link
Collaborator

@marc-hb marc-hb commented May 31, 2023

2 commits, please review separately. Main commit:

xtensa-build-zephyr.py: resolve relative --key arguments

Fixes commit a769d39 ("xtensa-build-zephyr.py: stop calling west
sign, rely on west build")

Before that commit, xtensa-build-zephyr.py used to invoke west sign
directly and in the same current directory. This allowed relative key
paths to just work. Now that west sign is indirectly invoked by west build, there is no possible way to make relative key paths work. So we
must resolve them before using them.

Fixes #7718

Fixes commit a769d39 ("xtensa-build-zephyr.py: stop calling west
sign, rely on west build")

Before that commit, `xtensa-build-zephyr.py` used to invoke `west sign`
directly and in the same current directory. This allowed relative key
paths to just work. Now that `west sign` is indirectly invoked by `west
build`, there is no possible way to make relative key paths work. So we
must resolve them before using them.

Fixes thesofproject#7718

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
@marc-hb marc-hb added this to the v2.6 milestone May 31, 2023
@marc-hb marc-hb marked this pull request as ready for review May 31, 2023 18:43
@marc-hb marc-hb requested a review from aborisovich as a code owner May 31, 2023 18:43
@marc-hb marc-hb marked this pull request as draft May 31, 2023 18:44
@marc-hb marc-hb force-pushed the resolve-key-path branch from c9de274 to 97ce774 Compare May 31, 2023 18:56
@marc-hb
Copy link
Collaborator Author

marc-hb commented May 31, 2023

1 suspend/resume timeout in MTL https://sof-ci.01.org/sofpr/PR7721/build8784/devicetest/index.html
1 suspend/resume timeout in cavs25
https://sof-ci.01.org/sofpr/PR7721/build8785/devicetest/index.html

https://sof-ci.01.org/sof-pr-viewer/#/build/PR7721/build12101750 has a single, totally unrealted failure in TestTwoHdaStreams::test_124_20_two_simultaneous_hda_copier_loop, all other tests ran fine.

Everything else green.

Copy link
Collaborator

@aiChaoSONG aiChaoSONG left a comment

Choose a reason for hiding this comment

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

Changes looks good

Copy link
Contributor

@aborisovich aborisovich left a comment

Choose a reason for hiding this comment

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

Tested PR, fixes #7718.
Thanks @marc-hb for the quick correction.

@kv2019i
Copy link
Collaborator

kv2019i commented Jun 1, 2023

Good to go, but need to have the mandatory CI checks to pass.

@marc-hb
Copy link
Collaborator Author

marc-hb commented Jun 1, 2023

Good to go, but need to have the mandatory CI checks to pass.

I spent time looking at all the (rare and isolated) test failures, none is related, see summary above. So there's nothing this PR can do about them. This is a pure build script change.

@lgirdwood
Copy link
Member

@lrudyX @wszypelt pls confirm if we are good to merge. Thanks.

We used to provide the `default_rimage_key` in two places:
1) as a default `RIMAGE_KEY` attribute (newer `otc_private_key_3k`)
2) as an explicit `else` clause that was never run because of 1) (older
   `otc_private_key`)

Remove the redundant `else` clause in 2); it became dead code. This
simplifies the code and makes the script ready for the day when the key
argument will be optional for rimage (more about this in
zephyrproject-rtos/zephyr#58356)

Signed-off-by: Marc Herbert <marc.herbert@intel.com>
@marc-hb marc-hb force-pushed the resolve-key-path branch from 97ce774 to 14dcb00 Compare June 1, 2023 20:32
@marc-hb
Copy link
Collaborator Author

marc-hb commented Jun 1, 2023

I did an empty git commit --amend -C HEAD + force push and now EVERYTHING is unbelievably green, including https://sof-ci.01.org/sof-pr-viewer/#/build/PR7721/build12109911, https://sof-ci.01.org/sofpr/PR7721/build8840/devicetest and https://sof-ci.01.org/sofpr/PR7721/build8841/devicetest

It's so green that it is actually suspicious so I opened all these links and the logs look fine.

@kv2019i kv2019i merged commit 231c4e3 into thesofproject:main Jun 2, 2023
@marc-hb marc-hb deleted the resolve-key-path branch June 2, 2023 19:35
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.

[BUG] xtensa-build-zephyr.py fails to sign fw image using private key with relative path

8 participants