Skip to content

Commit 03ee64b

Browse files
palmer-dabbeltglemco
authored andcommitted
rv: Support systems with time64-only syscalls
Some systems (like 32-bit RISC-V) only have the 64-bit time_t versions of syscalls. So handle the 32-bit time_t version of those being undefined. Fixes: f74f8bb ("rv: Add rtapp_sleep monitor") Closes: https://lore.kernel.org/oe-kbuild-all/202508160204.SsFyNfo6-lkp@intel.com Signed-off-by: Palmer Dabbelt <palmer@dabbelt.com> Acked-by: Nam Cao <namcao@linutronix.de> Link: https://lore.kernel.org/r/20250804194518.97620-2-palmer@dabbelt.com Signed-off-by: Gabriele Monaco <gmonaco@redhat.com>
1 parent 76eeb9b commit 03ee64b

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

  • kernel/trace/rv/monitors/sleep

kernel/trace/rv/monitors/sleep/sleep.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,9 @@ static void handle_sys_enter(void *data, struct pt_regs *regs, long id)
127127
mon = ltl_get_monitor(current);
128128

129129
switch (id) {
130+
#ifdef __NR_clock_nanosleep
130131
case __NR_clock_nanosleep:
132+
#endif
131133
#ifdef __NR_clock_nanosleep_time64
132134
case __NR_clock_nanosleep_time64:
133135
#endif
@@ -138,7 +140,9 @@ static void handle_sys_enter(void *data, struct pt_regs *regs, long id)
138140
ltl_atom_update(current, LTL_CLOCK_NANOSLEEP, true);
139141
break;
140142

143+
#ifdef __NR_futex
141144
case __NR_futex:
145+
#endif
142146
#ifdef __NR_futex_time64
143147
case __NR_futex_time64:
144148
#endif

0 commit comments

Comments
 (0)