Commit Graph

238 Commits

Author SHA1 Message Date
Dan Scott e8db09d7b4 Add additional warning codition for sgx_check module
Signed-off-by: Dan Scott <dan.scott@intel.com>
2026-01-29 11:59:38 -08:00
Tamas K Lengyel 1d3b8c5ec1 access_uefispec: accept both hex and base-10 formatted attr input
Beside the functional improvement, converting the input to int is required
depending on what Python version is being used to avoid the variable
propagating down the call-chain as a str.

Signed-off-by: Tamas K Lengyel <tamas.lengyel@oracle.com>
2026-01-29 11:59:38 -08:00
Tamas K Lengyel 1c30511638 Make uefi variable modification test more configurable
Currently the common.uefi.access_uefispec -a modify test modifications to variables
with the default variable attribute of nv | bs | rs (0x7). In this patch we make
this behavior more configurable.

By default the -a modify option will attempt to modify only the content of the variable,
but will not attempt to change the existing attributes of the variable. We have observed
cases where the test used this way uncovered more issues on variables where different
attributes were used and we did not attempt changing the attribute.

By specifying an optional attribute with -a modify,<attribute> the user can now test
variable modification with any attribute instead of just the currently hard-coded one.

Signed-off-by: Tamas K Lengyel <tamas.lengyel@oracle.com>
2026-01-29 11:59:38 -08:00
Nathaniel Mitchell 98fc5c3b35 Minor module updates
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2026-01-29 11:59:24 -08:00
Nathaniel Mitchell 1259e568de Change all HAL objects in cs.hals to be lowercase
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-12-09 13:49:37 -08:00
Nathaniel Mitchell e2e060d390 Update chipsec so XML names are not case sensitive
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-10-30 14:08:03 -07:00
brentholtsclaw 92cfae82fb dev/chipsec2 fixes
Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2025-09-02 10:20:38 -07:00
Tamas K Lengyel ff41621178 OsIndicationsSupported is only RO after ExitBootServices
The access_uefispec module currently reports OsIndicationsSupported should be
read-only even when the module is ran from UEFI shell before ExitBootServices
has been called. This is a false positive, OsIndicationsSupported is expected
to be read-write before ExitBootServices.

See https://uefi.org/specs/UEFI/2.10/03_Boot_Manager.html, variables that
should be read-only in all cases are specifically called out as:
"Should be treated as read-only". OsIndicationsSupported is not listed as such.

After ExitBootServices the following applies, as specified in
https://uefi.org/specs/UEFI/2.10/08_Services_Runtime_Services.html#setvariable:

"Once ExitBootServices() is performed, only variables that have
EFI_VARIABLE_RUNTIME_ACCESS and EFI_VARIABLE_NON_VOLATILE set can be set with
SetVariable()."

Signed-off-by: Tamas K Lengyel <tamas.lengyel@oracle.com>
2025-07-30 23:58:27 -07:00
Nathaniel Mitchell d3b15da507 Update remap module to look at multiple MCHBARs
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-08 01:07:54 +08:00
Nathaniel Mitchell 0671da48d7 Update spi modules to point to 8086.spi.spibar
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-08 01:07:54 +08:00
Nathaniel Mitchell e2139e954d Fixup framework with platform object
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-08 01:07:54 +08:00
Nathaniel Mitchell 56dc29328e Update modules set_scope to set the scope correctly (register only on the left)
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-08 01:07:54 +08:00
Nathaniel Mitchell 7f669cfd2d Add register specific functions to platform.py
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-08 01:07:54 +08:00
Nathaniel Mitchell b8d11ca5d9 Initial commit for new Cfg.platform object and register structure
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-05-02 09:06:31 -07:00
Nathaniel Mitchell a84b17ca53 Update sgx_check registers to match config data (all upper case)
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-04-24 09:08:44 -07:00
Sara Batllori d9a8265fc5 Remove MTAG prefix from module tags and add metadata tags
Signed-off-by: Sara Batllori <sara.batllori@intel.com>
2025-03-18 16:46:35 -07:00
Sara Batllori 40c60dce69 Add archiving status for modules
Signed-off-by: Sara Batllori <sara.batllori@intel.com>
2025-03-18 16:45:27 -07:00
Nathaniel Mitchell 2a8092ed60 Fix debugenable module with enable and debug_occured checks
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-18 16:29:37 -07:00
Nathaniel Mitchell bea2860e8e Update device functions and port register.read*/write* functions
Updated the device.get_obj/objlist functions to match the other types e.g. "get_list_by_name" and "get_instance_by_name".

Updated register.read/read_field/write/write_field functions to first get the register objects, then read*/write* from there.

Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-18 16:29:21 -07:00
Nathaniel Mitchell de6ffa0409 Update smbus hal, cmd and unit tests
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-17 09:07:19 -07:00
Nathaniel Mitchell 4b65243d9c Fix more unit tests
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-10 09:06:35 -07:00
Nathaniel Mitchell 74818ec960 Fix up more modules. Adl now matching legacy run
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-07 21:08:24 -08:00
Nathaniel Mitchell 9d3e2842f0 fix iobar, and a few modules
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-05 07:59:36 -08:00
Nathaniel Mitchell 443b019f32 Few fixes, mostly WRT mmio
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-05 07:59:36 -08:00
Nathaniel Mitchell b5a34ffd49 Update rtclock module
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-03-03 09:04:08 -08:00
Nathaniel Mitchell 89488d514e Fix up rtclock and smm_dma modules and cpu hal+unit tests
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-02-25 10:37:52 -08:00
Nathaniel Mitchell 7d459745ac Fix modules debugenabled and me_mfg_mode
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-02-18 13:19:38 -08:00
Nathaniel Mitchell 7725ebe841 Enable bios_wp module to run successfully on ADL
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-02-18 13:19:38 -08:00
Nathaniel Mitchell 6164ca86db Update to enable mmio
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-02-18 13:19:38 -08:00
Dan Scott a64ae4263e Add module result assignment to sample part checking logic
Signed-off-by: Dan Scott <dan.scott@intel.com>
2025-02-18 10:37:44 -08:00
Dan Scott 263934f79e Sgx_sample_check 2025-02-18 10:37:06 -08:00
Dan Scott c30175a311 Check CPU for sample part during sgx_check module
Signed-off-by: Dan Scott <dan.scott@intel.com>
2025-02-18 10:37:04 -08:00
BrentHoltsclaw 0165a61fec Dev/uefi hal (#2377)
* Add Win Cert types to uefi_fv and spi_uefi
* Move uefi search to library.uefi folder
* Move uefi_fv to library.uefi
* Move uefi_compression to library.uefi>
* Move uefi_common to library.uefi
* Move uefi_platform to library.uefi
* Move spi_uefi to library.uefi
* Add library.uefi.sleep_scripts file
* Move S3 functionality into sleep_state file
* Add varstore and variable files to library.uefi
* Fixup Flake8 suggestions
* Rename library uefi files to remove uefi_
* This change changes the filename of any file under the library.uefi to remove the uefi as part of the name.
* Fix Errors when testing changes

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2025-02-12 09:13:50 -08:00
Nathaniel Mitchell aaaa9e58a2 Update hal references to use cs.hals
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-10 12:22:31 -08:00
Nathaniel Mitchell 53cb4720f2 More module updates
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-03 12:50:38 -08:00
Nathaniel Mitchell f7409804b4 HAL Update - Enable multitenant HALs
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-03 12:50:36 -08:00
Dan Scott 25e124a47b Mob Session: Module updates for config changes 2024-12-03 12:50:35 -08:00
Nathaniel Mitchell 7c64276210 Post platformdetect updates
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-03 12:50:35 -08:00
Nathaniel Mitchell 6aecea8c43 Post platformdetect updates
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-03 12:50:35 -08:00
Nathaniel Mitchell 847f02daa1 initial commit of cfg changes
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-12-03 12:50:34 -08:00
Dan Scott b34fd4f4b2 Add check for SamplePart control
Signed-off-by: Dan Scott <dan.scott@intel.com>
2024-11-22 14:41:36 -08:00
coudrant 7247978cfb Initial submission of AMD common modules (#2343)
* Initial submission of AMD common modules

* Corrected Copyright and Email for AMD modules.  Major fixes to spectre module.  Timeout added to PSP.  Added rom_armor.

* Corrected Copyright and Email for AMD modules.  Major fixes to spectre module.  Timeout added to PSP.  Added rom_armor.

* Corrected Platform Configuration.  Corrected cpu_info for Intel.

* Corrected register checks in spectre module

* Comestic changes to strix.xml. Code quality improvements to psp and smm_addr.  smm_base is redundant and removed

* Corrected smm_addr use of SMMMASK.  Added PATCH_LEVEL.  Added psp to chipset.

* Cleaned up results.id smm_addr.py

* <sku code> now matches <configuration> in strix.xml
2024-10-30 13:49:20 -07:00
Frinzell, Aaron aa7fc5d145 Clean up cpu modules
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2024-08-26 16:40:18 -07:00
Frinzell, Aaron fb3c58d5f5 Clean up variables.py
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2024-08-26 16:39:44 -07:00
Frinzell, Aaron da8ff136bf Clean up common modules
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2024-08-26 16:39:27 -07:00
Dan Scott f19760c63c Replace print() with logger.log()
Signed-off-by: Dan Scott <dan.scott@intel.com>
2024-08-05 16:35:54 -07:00
Jason Zhou 1be3edf6de Add remap lock bit condition check
Signed-off-by: Jason Zhou <jun2.zhou@intel.com>
2024-07-16 16:36:51 -07:00
Nathaniel Mitchell e397aca0f9 Update mmio to check if Base Address is valid
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-06-27 14:54:01 -07:00
Nathaniel Mitchell 016b3b50e4 Fix case of SMM_CODE_CHK_EN field
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-06-24 16:37:00 -07:00
Sae86 efccddd739 WIP: Add feature to automatically generate url for return codes
Signed-off-by: Sae86 <sara.batllori@intel.com>
2024-05-29 10:44:04 -07:00