Files
Arnd Bergmann 6bc58b04fa err.h: use __always_inline on all error pointer helpers
commit 94bfc7f3b0 upstream.

While testing randconfig builds on s390, I came across a link failure with
CONFIG_DMA_SHARED_BUFFER disabled:

ERROR: modpost: "dma_buf_put" [drivers/iommu/iommufd/iommufd.ko] undefined!

The problem here is that IS_ERR() is not inlined and dead code elimination
fails as a consequence.

The err.h helpers all turn into a trivial assignment of a bit mask and
should never result in a function call, so force them to always be inline.
This should generally result in better object code aside from avoiding
the link failure above.

Link: https://lore.kernel.org/20260526101851.2495110-1-arnd@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Reviewed-by: Alexander Lobakin <aleksander.lobakin@intel.com>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Tested-by: Tamir Duberstein <tamird@kernel.org>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Cc: Andriy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Ansuel Smith <ansuelsmth@gmail.com>
Cc: Bjorn Andersson <andersson@kernel.org>
Cc: Heiko Carstens <hca@linux.ibm.com>
Cc: Vasily Gorbik <gor@linux.ibm.com>
Cc: <stable@vger.kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2026-07-04 13:43:32 +02:00
..
2026-03-04 07:19:39 -05:00
2026-03-04 07:20:22 -05:00
2026-07-04 13:43:31 +02:00
2026-03-04 07:19:26 -05:00
2026-05-23 13:04:35 +02:00
2026-07-04 13:43:31 +02:00
2026-06-19 13:42:17 +02:00
2026-07-04 13:43:31 +02:00
2026-07-04 13:43:31 +02:00
2026-04-11 14:24:32 +02:00
2026-02-11 13:40:25 +01:00
2026-05-23 13:04:49 +02:00
2026-07-04 13:43:31 +02:00
2026-02-11 13:40:25 +01:00