lkml.org 
[lkml]   [2020]   [May]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v4 09/18] x86/static_call: Add out-of-line static call implementation
On Fri, May 01, 2020 at 10:28:58PM +0200, Peter Zijlstra wrote:

> +#define ARCH_DEFINE_STATIC_CALL_TRAMP(name, func) \
> + asm(".pushsection .text, \"ax\" \n" \
> + ".align 4 \n" \
> + ".globl " STATIC_CALL_TRAMP_STR(name) " \n" \
> + STATIC_CALL_TRAMP_STR(name) ": \n" \
> + " jmp.d32 " #func " \n" \

I remembered Nick asked this to be .byte 0xe9; .long #func - (.+4); last
time, now done.

> + ".type " STATIC_CALL_TRAMP_STR(name) ", @function \n" \
> + ".size " STATIC_CALL_TRAMP_STR(name) ", . - " STATIC_CALL_TRAMP_STR(name) " \n" \
> + ".popsection \n")

\
 
 \ /
  Last update: 2020-05-06 18:17    [W:0.245 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site