From: "Arnd Bergmann" <arnd@arndb.de>
To: "Sasha Levin" <sashal@kernel.org>,
"Dinh Nguyen" <dinguyen@kernel.org>,
"schuster.simon@siemens-energy.com"
<schuster.simon@siemens-energy.com>
Cc: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
linux-kernel@vger.kernel.org, "kernel test robot" <lkp@intel.com>
Subject: Re: [PATCH] nios2: ksyms: Export __divsi3_table
Date: Tue, 27 Oct 2026 01:17:20 +0100 [thread overview]
Message-ID: <1d3a81cc-9b76-4097-b9b3-07e62277aced@app.fastmail.com> (raw)
In-Reply-To: <20261026234452.1086974-1-sashal@kernel.org>
On Tue, Oct 27, 2026, at 00:44, Sasha Levin wrote:
> lib/lz4 is built with -O3, and at -O3 GCC enables -mfast-sw-div, which
> expands divisions by small numbers using __divsi3_table, a lookup table
> in libgcc. Without CONFIG_NIOS2_HW_DIV_SUPPORT that leaves
> lz4_compress.ko with a reference modpost cannot resolve:
>
> ERROR: modpost: lib/lz4/lz4_compress.ko: symbol '__divsi3_table' undefined!
>
> libgcc is linked into vmlinux, so built-in code finds the table, but it
> is not exported to modules. Export it next to __divsi3.
>
> The error predates commit 2180d11e06fb ("nios2: ksyms: Declare __mulsi3
> export"), which only made it visible: before that commit, modpost used
> up its ten unresolved symbol reports on __mulsi3 and suppressed the rest.
>
> Fixes: 2fc8483fdcde ("nios2: Build infrastructure")
> Reported-by: kernel test robot <lkp@intel.com>
> Closes:
> https://lore.kernel.org/oe-kbuild-all/202610270503.NGox5O6j-lkp@intel.com/
> Signed-off-by: Sasha Levin <sashal@kernel.org>
I hope we can address this using a copy of libgcc like the other
architectures:
https://lore.kernel.org/lkml/20261020123149.cyjzz4uo25oiiu2m@dev-vm-schuster/
Your patch is otherwise correct of course, but it may end up
clashing with the other fix.
Arnd
prev parent reply other threads:[~2026-10-27 0:17 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-26 23:44 Sasha Levin
2026-10-27 0:17 ` Arnd Bergmann [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1d3a81cc-9b76-4097-b9b3-07e62277aced@app.fastmail.com \
--to=arnd@arndb.de \
--cc=dinguyen@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=lkp@intel.com \
--cc=sashal@kernel.org \
--cc=schuster.simon@siemens-energy.com \
--cc=thomas.weissschuh@linutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®