Re: [PATCH] ubifs: Fix build errors as symbol undefined

From: Richard Weinberger
Date: Sat Nov 19 2022 - 16:26:19 EST


----- Ursprüngliche Mail -----
> Von: "Lihua (lihua, ran)" <hucool.lihua@xxxxxxxxxx>
>> diff --git a/fs/ubifs/Kconfig b/fs/ubifs/Kconfig
>> index 45d3d207fb99..93bda1057fdc 100644
>> --- a/fs/ubifs/Kconfig
>> +++ b/fs/ubifs/Kconfig
>> @@ -13,6 +13,7 @@ config UBIFS_FS
>> select CRYPTO_HASH_INFO
>> select UBIFS_FS_XATTR if FS_ENCRYPTION
>> select FS_ENCRYPTION_ALGS if FS_ENCRYPTION
>> + select UBIFS_FS_AUTHENTICATION

I fear this is not a proper fix.
This changes does not longer allow building UBIFS without the authentication feature.
With what configuration do you see this error?

I just tried with:
CONFIG_UBIFS_FS=m
CONFIG_UBIFS_FS_ADVANCED_COMPR=y
CONFIG_UBIFS_FS_LZO=y
CONFIG_UBIFS_FS_ZLIB=y
CONFIG_UBIFS_FS_ZSTD=y
CONFIG_UBIFS_ATIME_SUPPORT=y
CONFIG_UBIFS_FS_XATTR=y
CONFIG_UBIFS_FS_SECURITY=y
# CONFIG_UBIFS_FS_AUTHENTICATION is not set

But don't get the error and, as expected, fs/ubifs/ubifs.o has no
reference to ubifs_bad_hash.

Thanks,
//richard