Skip to content

Commit dc19cb0

Browse files
committed
pkg/kconfig: support transitional line
See https://www.phoronix.com/news/Linux-6.18-Transitional . First used in: config CFI_CLANG bool transitional help Transitional config for CFI_CLANG to CFI migration.
1 parent 96a211b commit dc19cb0

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

pkg/kconfig/kconfig.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,10 @@ func (kp *kconfigParser) parseProperty(prop string) {
337337
kp.ConsumeLine()
338338
case "modules":
339339
case "optional":
340+
// transitional is used for the configs backward compatibility.
341+
// We can ignore them. After the config final removal we'll see the kconf error.
342+
// https://www.phoronix.com/news/Linux-6.18-Transitional
343+
case "transitional":
340344
case "default":
341345
kp.parseDefaultValue()
342346
case "range":

pkg/kconfig/kconfig_test.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,13 @@ func TestParseKConfig(t *testing.T) {
2121
mainmenu "test"
2222
config FOO
2323
default "$(shell,$(srctree)/scripts/gcc-plugin.sh "$(preferred-plugin-hostcc)" "$(HOSTCXX)" "$(CC)")" if CC_IS_GCC
24+
`,
25+
},
26+
{
27+
in: `
28+
mainmenu "test_transitional"
29+
config FOO
30+
transitional
2431
`,
2532
},
2633
}

0 commit comments

Comments
 (0)