mm-commits.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* + mm-mremap-fix-build_bug_on-error-in-get_extent.patch added to -mm tree
@ 2021-02-04  0:20 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2021-02-04  0:20 UTC (permalink / raw)
  To: arnd, arnd, mm-commits


The patch titled
     Subject: mm/mremap: fix BUILD_BUG_ON() error in get_extent
has been added to the -mm tree.  Its filename is
     mm-mremap-fix-build_bug_on-error-in-get_extent.patch

This patch should soon appear at
    https://ozlabs.org/~akpm/mmots/broken-out/mm-mremap-fix-build_bug_on-error-in-get_extent.patch
and later at
    https://ozlabs.org/~akpm/mmotm/broken-out/mm-mremap-fix-build_bug_on-error-in-get_extent.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Arnd Bergmann <arnd@kernel.org>
Subject: mm/mremap: fix BUILD_BUG_ON() error in get_extent


clang cannt evaluate this function argument at compile time
when the function is not inlined, which leads to a link
time failure:

ld.lld: error: undefined symbol: __compiletime_assert_414
>>> referenced by mremap.c
>>>               mremap.o:(get_extent) in archive mm/built-in.a

Mark the function as __always_inline to avoid it.

Link: https://lkml.kernel.org/r/20201230154104.522605-1-arnd@kernel.org
Fixes: 9ad9718bfa41 ("mm/mremap: calculate extent in one place")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 mm/mremap.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

--- a/mm/mremap.c~mm-mremap-fix-build_bug_on-error-in-get_extent
+++ a/mm/mremap.c
@@ -336,8 +336,9 @@ enum pgt_entry {
  * valid. Else returns a smaller extent bounded by the end of the source and
  * destination pgt_entry.
  */
-static unsigned long get_extent(enum pgt_entry entry, unsigned long old_addr,
-			unsigned long old_end, unsigned long new_addr)
+static __always_inline unsigned long get_extent(enum pgt_entry entry,
+			unsigned long old_addr, unsigned long old_end,
+			unsigned long new_addr)
 {
 	unsigned long next, extent, mask, size;
 
_

Patches currently in -mm which might be from arnd@kernel.org are

mm-mremap-fix-build_bug_on-error-in-get_extent.patch


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-02-04  0:21 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-04  0:20 + mm-mremap-fix-build_bug_on-error-in-get_extent.patch added to -mm tree akpm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).