Commit Graph

78 Commits

Author SHA1 Message Date
Nathaniel Mitchell ee551aa168 Populate lists for -p and --pch
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-12-09 10:17:11 -08: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 0ebc53f09c Change default logger file name to 'entry'-yearMonDay-Time.log
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2025-02-18 13:19:38 -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
Nathaniel Mitchell 3a832e89c2 Update chipsec_util to check if a cfg is loaded when it's needed
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-09-20 00:00:10 -07:00
Frinzell, Aaron 2181416bd9 Update type hints
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2024-09-10 16:38:28 -07:00
Nathaniel Mitchell cc8e9f3876 Refactor main/util parsing of logger flags
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-04-22 16:37:51 -07:00
Nathaniel Mitchell b7da500d1f Add default_helper to util_config option section
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2024-04-16 16:34:49 -07:00
Dan Scott 0e8192cfd0 Move files to library folder 2024-03-22 14:26:59 -07:00
Dan Scott a933b1337d Update references to functions in new library files 2024-03-22 14:26:59 -07:00
mavas ca41c89d51 Reorder standard Python import statements
Reorder the standard Python library import statements into alphabetical order.
2024-01-17 16:36:35 -08:00
Dan Scott 009622740d Update config parsing
Signed-off-by: Dan Scott <dan.scott@intel.com>
2023-07-28 09:34:00 -07:00
Nathaniel Mitchell 96d5409688 Update BaseCommand, chipsec_util with new util structure
Additional changes to enhance utils usage

Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-07-27 11:39:28 -07:00
Nathaniel Mitchell 27ee5eeb66 Clean up helper create/start/stop/delete functions
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-07-19 16:33:59 -07:00
Nathaniel Mitchell 190655b290 Fixup how -i, -n and --skip_config are used
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-07-05 16:36:58 -07:00
Sara Batllori 9b2e491597 Add return codes mode option to main and util
Signed-off-by: Sara Batllori <sara.batllori@intel.com>
2023-06-27 09:30:04 -07:00
Nathaniel Mitchell dc3f78d38d Update useage help messages and help documentation
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-06-26 11:54:00 -07:00
brentholtsclaw cdfa91b840 Add -nl option to chipsec_util
Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2023-06-20 16:37:26 -07:00
Nicolas Iooss a01d537a75 Make OsHelper.get_available_helpers return a sorted list
`OsHelper.get_available_helpers` is returning a list of helper names in
the order they are stored in the dict `self.avail_helpers`. This order
seems to come from the order in which `os.listdir(helper_dir)` reads the
content of the directory.

To make this order more predictible and meaningful, sort the list in
`get_available_helpers`. This function was only called when generating
the documentation ofi option `--helper` and this makes it more
reproducible too.

Signed-off-by: Nicolas Iooss <nicolas.iooss_git@polytechnique.org>
2023-06-02 08:48:34 -07:00
Nathaniel Mitchell 0016b0c14c Clean up oshelper
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-05-26 18:32:51 -07:00
Frinzell, Aaron 1ff14fd642 Add .run() commands to chipsec_main.py and chipsec_util.py
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2023-05-22 16:38:13 -07:00
Frinzell, Aaron 5e42ac8c36 CHIPSEC_LOADED_AS_EXE support deprecated
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2023-05-10 11:02:35 -07:00
Nathaniel Mitchell 4b9ab99839 Change the way helper loading is done
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2023-04-26 16:52:26 -07:00
Frinzell, Aaron 187dc49107 Don't display extended_banner if using --skip_config
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2023-02-23 09:34:49 -06:00
Frinzell, Aaron 4f4b82597d Decouple banner routines from logger.py
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2023-01-25 10:42:41 -06:00
brentholtsclaw 2c31254a61 Change level code
level class was moved outside of logger class in #1646

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2023-01-23 16:54:37 -08:00
Sara Batllori b90667275e Update logger to use python logging
Signed-off-by: Sara Batllori <sara.batllori@intel.com>
2022-12-19 14:42:43 -08:00
Frinzell, Aaron 257cecc849 Decouple parse_args() from ChipsecMain and ChipsecUtil classes
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2022-12-05 12:16:00 -06:00
Zhou, Jun2 c9e8a370d3 get cpiud print ":" aligned
Signed-off-by: Zhou Jun, jun2.zhou@intel.com
2022-10-28 08:15:30 -07:00
Zhou, Jun2 c701e7f131 Use CPUID to identify processors instead of PCI Dev ID -- add cpuid printing
Signed-off-by: Zhou, Jun jun2.zhou@intel.com
2022-10-28 08:15:30 -07:00
brentholtsclaw be25ee42ec Create setlevel function
Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2022-09-29 16:03:48 -07:00
Frinzell, Aaron 0a3f98a6f4 Update duplicated logger functions in chipsec_main.py and chipsec_util.py
Signed-off-by: Frinzell, Aaron <aaron.frinzell@intel.com>
2022-06-17 15:21:40 -07:00
Erik Bjorge 81083bca03 Flake8 Cleanup
- Remove unused imports
- Improve spacing of functions/methods for readability
- Indentation updates
- Exception expression updates

Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
2022-02-16 08:23:01 -08:00
brentholtsclaw 0e53326a83 Create exceptions.py for chipsec exceptions
Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2021-08-26 10:50:51 -07:00
Nathaniel Mitchell c8c14e21be Remove shebang from all but the entry points. Update ep to py3
Signed-off-by: Nathaniel Mitchell <nathaniel.p.mitchell@intel.com>
2021-08-12 08:27:33 -07:00
Aaron Frinzell 1331e86c39 Add very verbose command-line option 2021-01-26 16:13:22 -08:00
Nathaniel Mitchell 749de73d38 Merge branch 'master' into nobanner 2020-09-24 15:22:54 -07:00
brentholtsclaw 51ce222498 Add skip_config option
option skips driver load and configuration loading

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2020-09-24 09:54:30 -07:00
brentholtsclaw f23d408abc Add -nb --no_banner option
Will allow to run main and util without a banner

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2020-08-28 14:50:19 -07:00
brentholtsclaw f7fe1be074 More whitespace cleanup
E231, E201, E226

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2020-07-31 13:46:13 -07:00
brentholtsclaw a00b2838e5 Cleanup trailing whitespace
W291,W293,W391

Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2020-07-01 15:44:21 -07:00
brentholtsclaw 3bb2b443b7 Don't display pch information for atom
Signed-off-by: brentholtsclaw <brent.holtsclaw@intel.com>
2020-05-26 12:37:35 -07:00
BrentHoltsclaw 514c23d84d Modify files based upon chipset.py changes
Fixup files that relied on CHIPSET_ID_XXX logic
Modify files for functions moved within cs class

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2020-04-20 08:39:02 -07:00
carlsbad 38829ad819 chipsec_util.py: Warn if Python architecture is different from OS architecture. 2020-03-20 17:47:20 -07:00
BrentHoltsclaw a7754ef7bd Edit chipsec banner information
Add ability to display a message from MESSAGE file within chipsec directory

Modify get version function to check for VERSION files not VERSION and CUSTOM_VERSION files

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2020-03-02 13:45:23 -08:00
Assaf Carlsbad 762b16883b The path to library.zip should be relative to the root executable, not to the current working directory. 2020-02-05 11:06:04 -08:00
BrentHoltsclaw 8819b9a64a Fixup chipsec_util unsupported platform logic
Enforce the -i option

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2020-01-23 08:54:46 -08:00
npmitche 203813a978 Revert "Fixup chipsec_util unsupported platform logic"
This reverts commit 9ec064d08e.
2020-01-22 16:01:28 -08:00
BrentHoltsclaw 9ec064d08e Fixup chipsec_util unsupported platform logic
Enforce the -i option

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2020-01-22 15:54:18 -08:00
Assaf Carlsbad 60eb5b438a Expose the --helper option to chipsec_util as well. 2020-01-13 10:36:16 -08:00