Skip to content

Create version check function - #32

Merged
JohnAZoidberg merged 5 commits into
mainfrom
version_check
Oct 21, 2024
Merged

Create version check function#32
JohnAZoidberg merged 5 commits into
mainfrom
version_check

Conversation

@kiram9

@kiram9 kiram9 commented Apr 30, 2024

Copy link
Copy Markdown
Member

This will check if versions match and return 0 if match or 1 if not match.

This can run in UEFI shell etc.

@kiram9
kiram9 requested a review from JohnAZoidberg April 30, 2024 05:00
@JohnAZoidberg JohnAZoidberg changed the title create version check function Create version check function Apr 30, 2024
@JohnAZoidberg

Copy link
Copy Markdown
Member

If you run --version for EC you get this:

EC Firmware
  Build version:  "marigold-3.0.1-3b77d21 2024-07-05 00:57:22 marigold1@ip-172-26-3-226"
  RO Version:     "marigold-3.0.1-3b77d21"
  RW Version:     "marigold-3.0.1-3b77d21"
  Current image:  RO

Currently the compare command uses the first one. But that's a bit verbose. How about the check just the marigold-3.0.1-3b77d21 part of the RO image?

@JohnAZoidberg
JohnAZoidberg changed the base branch from main to tgl-pd-version August 7, 2024 07:58
@JohnAZoidberg

Copy link
Copy Markdown
Member

I rebased onto #51, rebased conflicts and force-pushed.

@JohnAZoidberg

Copy link
Copy Markdown
Member

I fixed it for TGL, didn't try it on TGL or in UEFI shell yet.
But I tried #51 on TGL UEFI shell yesterday, so I'm rather confident it'll work.

Base automatically changed from tgl-pd-version to main August 9, 2024 02:14
@JohnAZoidberg

Copy link
Copy Markdown
Member

@kiram9 I implemented AC side checking like this.
I've got AC connected on the right, not on the left.

> sudo ./framework_tool --device ac-right --compare-version 1
Target Version "1"
Comparing AcRight "1"
Compared version:   0
 
> sudo ./framework_tool --device ac-left --compare-version 1
Target Version "1"
Comparing AcLeft "0"
Compared version:   1
Error: "Fail"

kiram9 and others added 4 commits October 21, 2024 13:50
This will check if versions match and return 0 if match or 1 if not
match.

This can run in UEFI shell etc.

Signed-off-by: Kieran Levin <ktl@frame.work>
Make sure it's the active one, and use base version on TGL.

Signed-off-by: Daniel Schaefer <dhs@frame.work>
Signed-off-by: Daniel Schaefer <dhs@frame.work>
Signed-off-by: Daniel Schaefer <dhs@frame.work>

@JohnAZoidberg JohnAZoidberg left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

A bit messy but let's get it in now, so we don't have to deal with more conflicts later.

Signed-off-by: Daniel Schaefer <dhs@frame.work>
@JohnAZoidberg
JohnAZoidberg merged commit 6fd13f2 into main Oct 21, 2024
@JohnAZoidberg
JohnAZoidberg deleted the version_check branch October 21, 2024 06:05
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.

2 participants