lib/ucs2_string: Suppress modinfo when __DISABLE_EXPORTS is set

Allow the UCS-2 string library to be reused in the EFI stub, by
suppressing the modinfo data that is usually emitted so that the library
can be built as a module.

Reviewed-by: Vincent Mailhol <mailhol@kernel.org>
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
This commit is contained in:
Ard Biesheuvel 2026-09-08 09:08:08 +02:00
parent d56ae62459
commit 4c0209bc31

View File

@ -163,5 +163,7 @@ ucs2_as_utf8(u8 *dest, const ucs2_char_t *src, unsigned long maxlength)
}
EXPORT_SYMBOL(ucs2_as_utf8);
#ifndef __DISABLE_EXPORTS
MODULE_DESCRIPTION("UCS2 string handling");
MODULE_LICENSE("GPL v2");
#endif