Re: [PATCH] MIPS: boot/compressed/: add __bswapdi2() to target for ZSTD decompression
From: Arnd Bergmann
Date: Wed Nov 10 2021 - 06:28:32 EST
On Wed, Nov 10, 2021 at 4:09 AM Randy Dunlap <rdunlap@xxxxxxxxxxxxx> wrote:
>
> For MIPS pre-boot, when CONFIG_KERNEL_ZSTD=y, the decompressor
> function uses __bswapdi2(), so this object file should be added to
> the target object file.
>
> Fixes these build errors:
>
> mips-linux-ld: arch/mips/boot/compressed/decompress.o: in function `xxh64':
> decompress.c:(.text+0x8be0): undefined reference to `__bswapdi2'
> mips-linux-ld: decompress.c:(.text+0x8c78): undefined reference to `__bswapdi2'
> mips-linux-ld: decompress.c:(.text+0x8d04): undefined reference to `__bswapdi2'
> mips-linux-ld: arch/mips/boot/compressed/decompress.o:decompress.c:(.text+0xa010): more undefined references to `__bswapdi2' follow
>
> Signed-off-by: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Cc: Arnd Bergmann <arnd@xxxxxxxx>
> Cc: Thomas Bogendoerfer <tsbogend@xxxxxxxxxxxxxxxx>
> Cc: linux-mips@xxxxxxxxxxxxxxx
Thank you for the fix, it looks like I missed it when I patched the xz version.
Acked-by: Arnd Bergmann <arnd@xxxxxxxx>
Fixes: 0652035a5794 ("asm-generic: unaligned: remove byteshift helpers")
Fixes: cddc40f5617e ("mips: always link byteswap helpers into decompressor")
Arnd