Skip to content

Commit 1d65a23

Browse files
Grzegorz SwiderskiChromeos LUCI
authored andcommitted
scripts: ci: check_compliance: Remove HWMv1 dead code
HWMv1-specific Kconfig checks were meant to be removed before HWMv2 was merged into `main` (see `collab-hwm` history), but some traces remained. Do another round of cleanup. (cherry picked from commit c0d5e85) Original-Signed-off-by: Grzegorz Swiderski <[email protected]> GitOrigin-RevId: c0d5e85 Cr-Build-Id: 8725452993329915921 Cr-Build-Url: https://cr-buildbucket.appspot.com/build/8725452993329915921 Copybot-Job-Name: zephyr-main-copybot-downstream Change-Id: Id48f5b7981bb12aefeb3b8dffac35906da17cd30 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/zephyr/+/6183329 Commit-Queue: Jonathon Murphy <[email protected]> Tested-by: ChromeOS Prod (Robot) <[email protected]> Reviewed-by: Jonathon Murphy <[email protected]>
1 parent 9bae8bf commit 1d65a23

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

scripts/ci/check_compliance.py

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -469,32 +469,6 @@ def get_kconfig_dts(self, kconfig_dts_file, settings_file):
469469
except subprocess.CalledProcessError as ex:
470470
self.error(ex.output.decode("utf-8"))
471471

472-
def get_v1_model_syms(self, kconfig_v1_file, kconfig_v1_syms_file):
473-
"""
474-
Generate a symbol define Kconfig file.
475-
This function creates a file with all Kconfig symbol definitions from
476-
old boards model so that those symbols will not appear as undefined
477-
symbols in hardware model v2.
478-
479-
This is needed to complete Kconfig compliance tests.
480-
"""
481-
os.environ['HWM_SCHEME'] = 'v1'
482-
# 'kconfiglib' is global
483-
# pylint: disable=undefined-variable
484-
485-
try:
486-
kconf_v1 = kconfiglib.Kconfig(filename=kconfig_v1_file, warn=False)
487-
except kconfiglib.KconfigError as e:
488-
self.failure(str(e))
489-
raise EndTest
490-
491-
with open(kconfig_v1_syms_file, 'w') as fp_kconfig_v1_syms_file:
492-
for s in kconf_v1.defined_syms:
493-
if s.type != kconfiglib.UNKNOWN:
494-
fp_kconfig_v1_syms_file.write('config ' + s.name)
495-
fp_kconfig_v1_syms_file.write('\n\t' + kconfiglib.TYPE_TO_STR[s.type])
496-
fp_kconfig_v1_syms_file.write('\n\n')
497-
498472
def get_v2_model(self, kconfig_dir, settings_file):
499473
"""
500474
Get lists of v2 boards and SoCs and put them in a file that is parsed by
@@ -537,9 +511,6 @@ def get_v2_model(self, kconfig_dir, settings_file):
537511
)
538512

539513
with open(kconfig_file, 'w') as fp:
540-
fp.write(
541-
'osource "' + (Path(kconfig_dir) / 'boards' / 'Kconfig.syms.v1').as_posix() + '"\n'
542-
)
543514
for board in v2_boards:
544515
for board_dir in board.directories:
545516
fp.write('osource "' + (board_dir / 'Kconfig').as_posix() + '"\n')

0 commit comments

Comments
 (0)