[LTP] fw_load0[12]: Skip on Lockdown and Secure Boot
linuxtestproject.agent@gmail.com
linuxtestproject.agent@gmail.com
Wed Jun 17 23:09:14 CEST 2026
Hi Avinesh,
On Wed, Jun 17 2026, Avinesh Kumar wrote:
> fw_load0[12]: Skip on Lockdown and Secure Boot
> + if (tst_lockdown_enabled() > 0 || tst_secureboot_enabled() > 0)
> + tst_brk(TCONF, "Cannot load unsigned modules in Lockdown/Secure Boot");
Two issues here:
1) The tst_brk() line is indented with two extra tabs (three total) but
should use one extra tab (two total) per kernel coding style.
2) struct tst_test already provides .skip_in_lockdown and
.skip_in_secureboot fields that perform the same
tst_lockdown_enabled()/tst_secureboot_enabled() checks from the
framework initialization path. Using these declarative fields is the
idiomatic approach:
static struct tst_test test = {
...
.skip_in_lockdown = 1,
.skip_in_secureboot = 1,
};
This would replace the manual if-statement in both fw_load01.c and
fw_load02.c.
Verdict - Needs revision
---
Note:
The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.
Regards,
LTP AI Reviewer
More information about the ltp
mailing list