[LTP] [PATCH] lib: Handle empty saved configuration values

Petr Vorel pvorel@suse.cz
Tue Sep 29 17:23:26 CEST 2026


Hi Andrea,

> Empty string module parameters return EOF on older kernels, causing
> fw_load02 to abort with TBROK on v4.4.

> Accept empty values while retaining read-error handling and the original
> errno. Restore empty strings with a NUL byte: an empty write does not
> invoke the sysfs setter, while a newline would change the saved value.

Thanks for the fix, LGTM.

Reviewed-by: Petr Vorel <pvorel@suse.cz>

> Signed-off-by: Andrea Cervesato <andrea.cervesato@suse.com>
> ---
> Fix the following behaviour on kernel < 4.14 96802e6b1dbf

Could you please put kernel version and git hash to the commit message?

Kind regards,
Petr


More information about the ltp mailing list