[BUG?] csky: qemu-user: swapped syscall numbers for getppid and rt_sigreturn

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Guo Ren,

it seems the values of __NR_rt_sigreturn and __NR_getppid are swapped
between csky qemu-user and the kernel.

In qemu-user [0, 1]:
(With context to show the disconuity)

#define TARGET_NR_rt_sigqueueinfo 138
--> #define TARGET_NR_rt_sigreturn 173
#define TARGET_NR_setpriority 140

#define TARGET_NR_getpid 172
--> #define TARGET_NR_getppid 139
#define TARGET_NR_getuid 174

The mainline kernel however uses the generic syscall numbers:

#define __NR_rt_sigreturn 139
#define __NR_getppid 173

Is this intentional? If so, what am I supposed to do about it?


While we are here:

Is there a known bug about upstream gcc 14.2.0 (and earlier) loosing
track of registers, especially r4, during optimizations?
It seems to me that this register gets overwritten sometimes before it
is meant to be used.


Thanks,
Thomas


[0] https://raw.githubusercontent.com/XUANTIE-RV/qemu/refs/heads/xuantie-qemu-6.1.0/linux-user/csky/syscall_nr.h
[1] https://raw.githubusercontent.com/XUANTIE-RV/qemu/refs/heads/xuantie-qemu-8.0/linux-user/csky/syscall_nr.h




[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux