]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
x86: Always inline task_size_max()
authorPeter Zijlstra <peterz@infradead.org>
Mon, 21 Jun 2021 11:12:37 +0000 (13:12 +0200)
committerIngo Molnar <mingo@kernel.org>
Tue, 22 Jun 2021 11:56:43 +0000 (13:56 +0200)
Fix:

  vmlinux.o: warning: objtool: handle_bug()+0x10: call to task_size_max() leaves .noinstr.text section

When #UD isn't a BUG, we shouldn't violate noinstr (we'll still
probably die, but that's another story).

Fixes: 025768a966a3 ("x86/cpu: Use alternative to generate the TASK_SIZE_MAX constant")
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Link: https://lore.kernel.org/r/20210621120120.682468274@infradead.org
arch/x86/include/asm/page_64.h

index ca840fec777654fd4be79b0ca0083b26ab445714..4bde0dc66100cd6d8207f317b2eec59ebc5cc57a 100644 (file)
@@ -75,7 +75,7 @@ void copy_page(void *to, void *from);
  *
  * With page table isolation enabled, we map the LDT in ... [stay tuned]
  */
-static inline unsigned long task_size_max(void)
+static __always_inline unsigned long task_size_max(void)
 {
        unsigned long ret;