[PATCH] riscv: ftrace: sorttable: fix mcount sorting

Chen Pei cp0613 at linux.alibaba.com
Mon Jun 8 18:30:08 PDT 2026


On Mon,  8 Jun 2026 22:18:27 +0200, martin at kaiser.cx wrote:

> The sorttable helper program does not take into account that the
> -fpatchable-function-entry compiler flag reserves an additional 8 bytes
> before each traceable function. (The size in bytes is the same for
> RV32/64 or compressed/uncompressed instructions).
> 
> Define before_func = 8 to fix the mcount sorting for risc-v, share this
> setting with arm64.
> 
> Fixes: de04fca5d2f8 ("riscv: ftrace: select HAVE_BUILDTIME_MCOUNT_SORT")

Hi Martin,

Thanks for the patch.

This has already been addressed by Wang Han here:
https://lore.kernel.org/linux-riscv/20260527123530.2593918-2-wanghan@linux.alibaba.com/

Thanks,
Pei



More information about the linux-riscv mailing list