Skip to content

Commit 32a2c2d

Browse files
committed
[nrf fromtree] 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. Signed-off-by: Grzegorz Swiderski <[email protected]> (cherry picked from commit c0d5e85)
1 parent e79f989 commit 32a2c2d

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
@@ -485,32 +485,6 @@ def get_kconfig_dts(self, kconfig_dts_file, settings_file):
485485
except subprocess.CalledProcessError as ex:
486486
self.error(ex.output.decode("utf-8"))
487487

488-
def get_v1_model_syms(self, kconfig_v1_file, kconfig_v1_syms_file):
489-
"""
490-
Generate a symbol define Kconfig file.
491-
This function creates a file with all Kconfig symbol definitions from
492-
old boards model so that those symbols will not appear as undefined
493-
symbols in hardware model v2.
494-
495-
This is needed to complete Kconfig compliance tests.
496-
"""
497-
os.environ['HWM_SCHEME'] = 'v1'
498-
# 'kconfiglib' is global
499-
# pylint: disable=undefined-variable
500-
501-
try:
502-
kconf_v1 = kconfiglib.Kconfig(filename=kconfig_v1_file, warn=False)
503-
except kconfiglib.KconfigError as e:
504-
self.failure(str(e))
505-
raise EndTest
506-
507-
with open(kconfig_v1_syms_file, 'w') as fp_kconfig_v1_syms_file:
508-
for s in kconf_v1.defined_syms:
509-
if s.type != kconfiglib.UNKNOWN:
510-
fp_kconfig_v1_syms_file.write('config ' + s.name)
511-
fp_kconfig_v1_syms_file.write('\n\t' + kconfiglib.TYPE_TO_STR[s.type])
512-
fp_kconfig_v1_syms_file.write('\n\n')
513-
514488
def get_v2_model(self, kconfig_dir, settings_file):
515489
"""
516490
Get lists of v2 boards and SoCs and put them in a file that is parsed by
@@ -553,9 +527,6 @@ def get_v2_model(self, kconfig_dir, settings_file):
553527
)
554528

555529
with open(kconfig_file, 'w') as fp:
556-
fp.write(
557-
'osource "' + (Path(kconfig_dir) / 'boards' / 'Kconfig.syms.v1').as_posix() + '"\n'
558-
)
559530
for board in v2_boards:
560531
for board_dir in board.directories:
561532
fp.write('osource "' + (board_dir / 'Kconfig').as_posix() + '"\n')

0 commit comments

Comments
 (0)