Skip to content
Commit 6e413124 authored by Mikhail Zhilkin's avatar Mikhail Zhilkin Committed by Greg Kroah-Hartman
Browse files

mtd: parsers: scpart: fix __udivdi3 undefined on mips

[ Upstream commit 105c14b8 ]

This fixes the following compile error on mips architecture with clang
version 16.0.0 reported by the 0-DAY CI Kernel Test Service:
   ld.lld: error: undefined symbol: __udivdi3
   referenced by scpart.c
   mtd/parsers/scpart.o:(scpart_parse) in archive drivers/built-in.a

As a workaround this makes 'offs' a 32-bit type. This is enough, because
the mtd containing partition table practically does not exceed 1 MB. We
can revert this when the [Link] has been resolved.

Link: https://github.com/ClangBuiltLinux/linux/issues/1635
Fixes: 9b78ef0c

 ("mtd: parsers: add support for Sercomm partitions")
Reported-by: default avatarkernel test robot <lkp@intel.com>
Suggested-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarMikhail Zhilkin <csharper2005@gmail.com>
Signed-off-by: default avatarMiquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/805fe58e-690f-6a3f-5ebf-2f6f6e6e4599@gmail.com
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent c5d03248
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment