62 Commits

Author SHA1 Message Date
Pawel Langowski
8fbd2a9f42 scripts/dts: Wait for user input on exit codes other than 0
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2024-11-21 14:28:42 +01:00
Pawel Langowski
23c6ed7f2a Use uppercase Enter
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2024-11-21 14:28:16 +01:00
Pawel Langowski
a4d3029a37 UI/UX improvements
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2024-11-21 14:22:01 +01:00
Daniil Klimuk
fd823a96b5 scripts: dasharo-deploy: got to handle_fw_switching in case of Heads
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-20 12:52:07 +01:00
Daniil Klimuk
0cd3f0a534 Ask only for enter to continue
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-20 12:52:01 +01:00
Daniil Klimuk
750629b88d scripts: dasharo-deploy: fix version comparison in update workflow
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 17:43:06 +01:00
Daniil Klimuk
e85031f1a2 scripts: dasharo-deploy: rework update routine to always reboot
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:47 +01:00
Daniil Klimuk
79e40334f9 check for Capsule Update compatibility with currently installed firm
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:47 +01:00
Daniil Klimuk
c4e607a015 scripts: dasharo-deploy: send logs before trying to reboot
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:47 +01:00
Daniil Klimuk
55256f51e5 do not use flashrom with QEMU
flashrom does not support QEMU and fails every time. I have not found a
better way to handle it, but we should not place hardwere related
configs all around the code.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:47 +01:00
Daniil Klimuk
965a1bf8e1 scripts: dasharo-deploy: standardize firmware access warn
This warning serves as a checkpoint in tests in Dasharo/OSFV repo, it
was unconvenient to have different warnings all other dasharo-deploy
script, so this commit brings it to one format.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:46 +01:00
Daniil Klimuk
4f7f237998 scripts: dasharo-deploy: check for EC firmware in update_workflow
Some platforms do not have EC firmware, so update for them would fail
without this commit.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:45 +01:00
Daniil Klimuk
0004f910ef scripts: dasharo-deploy: add check_flash_chip
Size of flashchip should be checked before board_config func. because the
func. assigns some configs based on the chip size detected for ASUS boards.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:52:45 +01:00
Daniil Klimuk
5d310535f5 fix sourcing libs
Cause of this patch: After I have added and integrated HAL - I have
added following line in dts-boot:

source $DTS_HAL

This was needed because I have used some fuctions from the HAL in the
script.

Inside DTS_HAL I had following line:

source $DTS_ENV

Because I have used some vars from the DTS_ENV in the HAL.

The problem was, that I had another line in DTS_ENV:

source $DTS_HAL

So, I got following boot workflow:

Boot
|
v
dts-boot
|   /-------\
v   v       |
DTS_HAL->DTS_ENV
           .
............
v
dts

Instead of sourcing some scripts and then launching dts script - I got a
loop betwee DTS_HAL and DTS_ENV. Therefore I decided to clean up
sourcing a bit.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:17:36 +01:00
Daniil Klimuk
6d53e2cf05 integrate HAL
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-18 16:17:36 +01:00
Daniil Klimuk
a99ba0254d scripts: dasharo-deploy: installation_workflow: fix downloading and
verifying

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:39 +01:00
Daniil Klimuk
3910890fe4 scripts: dasharo-deploy: add some collors to output
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:39 +01:00
Daniil Klimuk
61f68f01b0 remove -x flag from all files permissions
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
97aebd817f scripts: dasharo-deploy: pre-commit fixes
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
2aef6c34f4 Add more comments
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
05606c728d scripts: dasharo-deploy: delete backup option
This code is currently used inside dasharo-deploy only.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
1e152dc6fd scripts: ec_transition: delete surplus definitions
These veriables are already defined in dts-environment.sh, and the
ec_transition sources it.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
6b3eee91a3 scripts: dasharo-deploy: pre-commit fixes
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:38 +01:00
Daniil Klimuk
fd45d4e408 scripts: dasharo-deploy: add UEFI Capsule Update workflows
Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:37 +01:00
Daniil Klimuk
bebd97bf18 scripts: dasharo-deploy: clean up installation and update funcs
The installation workflows must be as linear as possbile for better
readability and scalability.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2024-11-14 10:39:37 +01:00