43 Commits
Author SHA1 Message Date
Mateusz Kusiak 4535b622c4 hcl-report: add progress bar wrapper
Add progress bar wrapper to avoid code repetition.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-12-15 11:45:58 +01:00
Mateusz Kusiak 6b94ee388b dts-functions: move progress bar
Move drawing progress bar function to dts-functions.sh

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-12-15 11:22:45 +01:00
Mateusz Kusiak f54f63d2bb hcl-report: Standalone progress bar
Make progress bar standalone to be reusable. It should be used only for
drawing the progress bar, and not contain any logic.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-12-15 11:22:42 +01:00
Michał Iwanicki 7fe36838d8 hcl: move PCRs dumping to function and add mocking
Signed-off-by: Michał Iwanicki <michal.iwanicki@3mdeb.com>
2025-12-11 16:35:08 +01:00
Michał Iwanicki 11e16413bc reports: hcl: dump TPM PCRs
Signed-off-by: Michał Iwanicki <michal.iwanicki@3mdeb.com>
2025-12-11 14:58:45 +01:00
Daniil Klimuk c311556792 reports: dasharo-hcl-report: do not send HCL for mocked hardware
Otherwise databases are polluted with HCLs that contain nothing more
that mocks and are useless.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2025-12-09 10:33:55 +01:00
Mateusz Kusiak 18cb9d7ca6 mock: amdtool: mock exit status
Add mockup funtion for amdtool to simualte failures on intel platform.
This is to be consistant with hardware behavior.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-11-17 11:42:39 +01:00
Kamil Aronowski 7b43513360 reports: dasharo-hcl-report: add amdtool to HCL
include: hal: dts-hal.sh: add AMDTOOL

Signed-off-by: Kamil Aronowski <kamil.aronowski@3mdeb.com>
2025-10-10 10:13:40 +02:00
Mateusz Kusiak 69f289f875 reports: psptool: Update HCL string
"PSPTool" is not meaningful string, update to "PSP firmware entries".

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-10-10 09:15:22 +02:00
Mateusz Kusiak 38b7991d72 reports: store FW dump path in var
Store default firmware dump path in a variable. This makes logical
connection on which file flashroom shall create and which file is
actualy used by psptool.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-10-09 10:51:42 +02:00
Mateusz Kusiak 00b0601d23 reports: psptool: add fixme
Add note that for psptool to return valid "Success" status in the HCL
report, it must be fixed at sources. Current limitations that cause
"UNKNOWN" status:
* All warnings are directed to sterr
* The tool mostly print warnings, not errors. This includes non-AMD
  binaries or just files full of zeros.
* The tool almos allways returns sucess status code, including the
  situtations described above.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-10-08 14:42:27 +02:00
Mateusz Kusiak 35c926cb1c reports: Add psptool to hcl report
This commit adds psptool support to HCL reports. The psptool is either
run on dumped firmware if available, but users can also place firmware
binaries from elsewhere in /firmware/external. This is a workaround as
on some platforms flashrom does not work under stock firmware.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-10-08 14:07:39 +02:00
Michał Iwanicki ef667ec7b2 Use ask_for_confirmation function when asking for user choice
Signed-off-by: Michał Iwanicki <michal.iwanicki@3mdeb.com>
2025-09-29 15:50:54 +02:00
Michał Iwanicki 3d0083aae3 dts-functions & dasharo-hcl-report: replace minio prints with 3mdeb
Users don't care or even know about implementation details

Signed-off-by: Michał Iwanicki <michal.iwanicki@3mdeb.com>
2025-09-24 11:16:29 +02:00
Mateusz Kusiak 2652858a6e hcl-report: Add FIXMEs for enforced unknows
3 tasks in hcl report logic are enforced to finish with UNKNOWN status,
due to the fact they not produce single STDERR and STDOUT logs. The
issues have been submitted. Link those issues in the source code.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-09-11 15:28:47 +02:00
Mateusz Kusiak 0f98325574 hcl-report: Add dynamic progress bar
The current progress bar implementation disallows for easy moving tasks
around and adding or removing them. Implement dynamic progress bar,
so the tasks can be easily altered.

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-09-11 14:54:11 +02:00
Mateusz Kusiak f00b6782db reports: enforce UNKNOWN keyword
The logic for checking if test should fail by default is reversed, thus
all passes or errors are treated as unknowns. Enforce checking the
keyword "UNKNOWN" for the tests.

Fixes:
https://github.com/Dasharo/dasharo-issues/issues/1304

Signed-off-by: Mateusz Kusiak <mateusz.kusiak@3mdeb.com>
2025-09-10 16:10:48 +02:00
Pawel Langowski 39021f596c Fix files to conform to shfmt
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-04-15 14:48:13 +02:00
Pawel Langowski 9439fc3bea Add .sh to all scripts
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-04-15 14:31:13 +02:00
Pawel Langowski 07d1953f4d Fix indentation and error messages
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-03-24 14:03:56 +01:00
Pawel Langowski 33060738cc Don't create minio alias when DPP email is empty
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-03-24 12:56:42 +01:00
Pawel Langowski fb01744bc5 Add public MinIO credentials for HCL reports
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-03-24 11:32:24 +01:00
Pawel Langowski 7813db0696 Use MinIO for HCL reports
Signed-off-by: Pawel Langowski <pawel.langowski@3mdeb.com>
2025-03-21 10:18:17 +01:00
Daniil Klimuk f0ff464694 Make functions in HCL Report not to exit
HCL report collects information, if smth is missing or not working - it
still should be collected by HCL report. Therefore there should be no
exit on error inside HCL report.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2025-01-15 17:15:47 +01:00
Daniil Klimuk e69ca6c8a4 reports: dasharo-hcl-report: mock checking for sound card presence
This loop takes too much time during tests (5s * 12 = 1m). The sound
card presence should be mocked to true by default to optimize HCL report
execution time.

Signed-off-by: Daniil Klimuk <daniil.klimuk@3mdeb.com>
2025-01-15 14:29:12 +01:00