Message ID | 1389616402-21126-1-git-send-email-riku.voipio@linaro.org |
---|---|
State | New |
Headers | show |
On 13 January 2014 12:33, <riku.voipio@linaro.org> wrote: > From: Riku Voipio <riku.voipio@linaro.org> > > All others updated except unicore, which doesn't look right to > begin with. Yes, I've noticed before that the Unicore syscall numbers are just completely wrong. Guan, would you like to submit a patch to fix them or should we just rip out the linux-user support for unicore completely? There's no point carrying something around that won't be able to do even basic syscalls... thanks -- PMM
The syscall numbers in unicore32 are correct because we have two ABIs for 32 bits. In qemu, it's old ABI, while in kernel, it's new ABI. However, for now, old ABI is widely used for unicore32's applications. Thanks and Regards, Xuetao Guan ----- Peter Maydell <peter.maydell@linaro.org> 写道: > On 13 January 2014 12:33, <riku.voipio@linaro.org> wrote: > > From: Riku Voipio <riku.voipio@linaro.org> > > > > All others updated except unicore, which doesn't look right to > > begin with. > > Yes, I've noticed before that the Unicore syscall numbers are > just completely wrong. Guan, would you like to submit a patch > to fix them or should we just rip out the linux-user support > for unicore completely? There's no point carrying something > around that won't be able to do even basic syscalls... > > thanks > -- PMM
On 13 January 2014 15:14, 管雪涛 <gxt@pku.edu.cn> wrote: > The syscall numbers in unicore32 are correct because we have two ABIs for 32 bits. > In qemu, it's old ABI, while in kernel, it's new ABI. > However, for now, old ABI is widely used for unicore32's applications. I don't think upstream QEMU should be supporting an ABI which isn't used by upstream Linux. If you didn't get it upstream into the kernel we should never have accepted it into QEMU to start with, really. thanks -- PMM
I'm sorry, but what's exactly your meaning? Change linux-user/unicore32/syscall_nr.h to be the same as linux kernel. Or, we will use include/*/unistd.h in linux kernel directly, by copying or referencing. Thanks, Guan Xuetao ----- Peter Maydell <peter.maydell@linaro.org> 写道: > On 13 January 2014 15:14, 管雪涛 <gxt@pku.edu.cn> wrote: > > The syscall numbers in unicore32 are correct because we have two ABIs for 32 bits. > > In qemu, it's old ABI, while in kernel, it's new ABI. > > However, for now, old ABI is widely used for unicore32's applications. > > I don't think upstream QEMU should be supporting an ABI > which isn't used by upstream Linux. If you didn't get > it upstream into the kernel we should never have accepted > it into QEMU to start with, really. > > thanks > -- PMM
On 14 January 2014 01:33, 管雪涛 <gxt@pku.edu.cn> wrote: > I'm sorry, but what's exactly your meaning? > Change linux-user/unicore32/syscall_nr.h to be the same as linux kernel. This. We should support the same set of binaries you can run on the upstream kernel. thanks -- PMM
On 14 January 2014 12:50, Peter Maydell <peter.maydell@linaro.org> wrote: > On 14 January 2014 01:33, 管雪涛 <gxt@pku.edu.cn> wrote: > > I'm sorry, but what's exactly your meaning? > > Change linux-user/unicore32/syscall_nr.h to be the same as linux kernel. > > This. We should support the same set of binaries you can > run on the upstream kernel. > I agree in principle, but qemu should also support running the binaries that people actually use. So if old unicore32 abi is widely used, we should support that also. Guam, the new ABI has been in mainline linux for quite a long time - is there even a plan to move to the new abi in unicore community? Riku
diff --git a/linux-user/alpha/syscall_nr.h b/linux-user/alpha/syscall_nr.h index d52d76e..625f301 100644 --- a/linux-user/alpha/syscall_nr.h +++ b/linux-user/alpha/syscall_nr.h @@ -433,3 +433,10 @@ #define TARGET_NR_open_by_handle_at 498 #define TARGET_NR_clock_adjtime 499 #define TARGET_NR_syncfs 500 +#define TARGET_NR_setns 501 +#define TARGET_NR_accept4 502 +#define TARGET_NR_sendmmsg 503 +#define TARGET_NR_process_vm_readv 504 +#define TARGET_NR_process_vm_writev 505 +#define TARGET_NR_kcmp 506 +#define TARGET_NR_finit_module 507 diff --git a/linux-user/arm/syscall_nr.h b/linux-user/arm/syscall_nr.h index 42d6855..bef847c 100644 --- a/linux-user/arm/syscall_nr.h +++ b/linux-user/arm/syscall_nr.h @@ -378,3 +378,9 @@ #define TARGET_NR_open_by_handle_at (371) #define TARGET_NR_clock_adjtime (372) #define TARGET_NR_syncfs (373) +#define TARGET_NR_sendmmsg (374) +#define TARGET_NR_setns (375) +#define TARGET_NR_process_vm_readv (376) +#define TARGET_NR_process_vm_writev (377) +#define TARGET_NR_kcmp (378) +#define TARGET_NR_finit_module (379) diff --git a/linux-user/cris/syscall_nr.h b/linux-user/cris/syscall_nr.h index 98f1a0b..694bd02 100644 --- a/linux-user/cris/syscall_nr.h +++ b/linux-user/cris/syscall_nr.h @@ -335,3 +335,4 @@ #define TARGET_NR_inotify_init1 332 #define TARGET_NR_preadv 333 #define TARGET_NR_pwritev 334 +#define TARGET_NR_setns 335 diff --git a/linux-user/i386/syscall_nr.h b/linux-user/i386/syscall_nr.h index f080305..c8f7302 100644 --- a/linux-user/i386/syscall_nr.h +++ b/linux-user/i386/syscall_nr.h @@ -347,3 +347,9 @@ #define TARGET_NR_open_by_handle_at 342 #define TARGET_NR_clock_adjtime 343 #define TARGET_NR_syncfs 344 +#define TARGET_NR_sendmmsg 345 +#define TARGET_NR_setns 346 +#define TARGET_NR_process_vm_readv 347 +#define TARGET_NR_process_vm_writev 348 +#define TARGET_NR_kcmp 349 +#define TARGET_NR_finit_module 350 diff --git a/linux-user/m68k/syscall_nr.h b/linux-user/m68k/syscall_nr.h index 4d0937e..25f8521 100644 --- a/linux-user/m68k/syscall_nr.h +++ b/linux-user/m68k/syscall_nr.h @@ -344,3 +344,8 @@ #define TARGET_NR_open_by_handle_at 341 #define TARGET_NR_clock_adjtime 342 #define TARGET_NR_syncfs 343 +#define TARGET_NR_setns 344 +#define TARGET_NR_process_vm_readv 345 +#define TARGET_NR_process_vm_writev 346 +#define TARGET_NR_kcmp 347 +#define TARGET_NR_finit_module 348 diff --git a/linux-user/microblaze/syscall_nr.h b/linux-user/microblaze/syscall_nr.h index f1fe0e7..6f530f9 100644 --- a/linux-user/microblaze/syscall_nr.h +++ b/linux-user/microblaze/syscall_nr.h @@ -376,4 +376,9 @@ #define TARGET_NR_open_by_handle_at 372 #define TARGET_NR_clock_adjtime 373 #define TARGET_NR_syncfs 374 - +#define TARGET_NR_setns 375 +#define TARGET_NR_sendmmsg 376 +#define TARGET_NR_process_vm_readv 377 +#define TARGET_NR_process_vm_writev 378 +#define TARGET_NR_kcmp 379 +#define TARGET_NR_finit_module 380 diff --git a/linux-user/mips/syscall_nr.h b/linux-user/mips/syscall_nr.h index fbdc348..2d1a13e 100644 --- a/linux-user/mips/syscall_nr.h +++ b/linux-user/mips/syscall_nr.h @@ -345,3 +345,9 @@ #define TARGET_NR_open_by_handle_at (TARGET_NR_Linux + 340) #define TARGET_NR_clock_adjtime (TARGET_NR_Linux + 341) #define TARGET_NR_syncfs (TARGET_NR_Linux + 342) +#define TARGET_NR_sendmmsg (TARGET_NR_Linux + 343) +#define TARGET_NR_setns (TARGET_NR_Linux + 344) +#define TARGET_NR_process_vm_readv (TARGET_NR_Linux + 345) +#define TARGET_NR_process_vm_writev (TARGET_NR_Linux + 346) +#define TARGET_NR_kcmp (TARGET_NR_Linux + 347) +#define TARGET_NR_finit_module (TARGET_NR_Linux + 348) diff --git a/linux-user/mips64/syscall_nr.h b/linux-user/mips64/syscall_nr.h index 0f4a6b1..004232a 100644 --- a/linux-user/mips64/syscall_nr.h +++ b/linux-user/mips64/syscall_nr.h @@ -310,6 +310,12 @@ #define TARGET_NR_open_by_handle_at (TARGET_NR_Linux + 304) #define TARGET_NR_clock_adjtime (TARGET_NR_Linux + 305) #define TARGET_NR_syncfs (TARGET_NR_Linux + 306) +#define TARGET_NR_sendmmsg (TARGET_NR_Linux + 307) +#define TARGET_NR_setns (TARGET_NR_Linux + 308) +#define TARGET_NR_process_vm_readv (TARGET_NR_Linux + 309) +#define TARGET_NR_process_vm_writev (TARGET_NR_Linux + 310) +#define TARGET_NR_kcmp (TARGET_NR_Linux + 311) +#define TARGET_NR_finit_module (TARGET_NR_Linux + 312) #else /* * Linux 64-bit syscalls are in the range from 5000 to 5999. @@ -617,4 +623,11 @@ #define TARGET_NR_open_by_handle_at (TARGET_NR_Linux + 299) #define TARGET_NR_clock_adjtime (TARGET_NR_Linux + 300) #define TARGET_NR_syncfs (TARGET_NR_Linux + 301) +#define TARGET_NR_sendmmsg (TARGET_NR_Linux + 302) +#define TARGET_NR_setns (TARGET_NR_Linux + 303) +#define TARGET_NR_process_vm_readv (TARGET_NR_Linux + 304) +#define TARGET_NR_process_vm_writev (TARGET_NR_Linux + 305) +#define TARGET_NR_kcmp (TARGET_NR_Linux + 306) +#define TARGET_NR_finit_module (TARGET_NR_Linux + 307) +#define TARGET_NR_getdents64 (TARGET_NR_Linux + 308) #endif diff --git a/linux-user/openrisc/syscall_nr.h b/linux-user/openrisc/syscall_nr.h index f4ac91e..4c386ea 100644 --- a/linux-user/openrisc/syscall_nr.h +++ b/linux-user/openrisc/syscall_nr.h @@ -378,9 +378,13 @@ #define TARGET_NR_syncfs 267 #define TARGET_NR_setns 268 #define TARGET_NR_sendmmsg 269 +#define TARGET_NR_process_vm_readv 270 +#define TARGET_NR_process_vm_writev 271 +#define TARGET_NR_kcmp 272 +#define TARGET_NR_finit_module 273 #undef TARGET_NR_syscalls -#define TARGET_NR_syscalls 270 +#define TARGET_NR_syscalls 274 /* * All syscalls below here should go away really, diff --git a/linux-user/ppc/syscall_nr.h b/linux-user/ppc/syscall_nr.h index 0673b7d..1e1736e 100644 --- a/linux-user/ppc/syscall_nr.h +++ b/linux-user/ppc/syscall_nr.h @@ -362,3 +362,9 @@ #define TARGET_NR_open_by_handle_at 346 #define TARGET_NR_clock_adjtime 347 #define TARGET_NR_syncfs 348 +#define TARGET_NR_sendmmsg 349 +#define TARGET_NR_setns 350 +#define TARGET_NR_process_vm_readv 351 +#define TARGET_NR_process_vm_writev 352 +#define TARGET_NR_finit_module 353 +#define TARGET_NR_kcmp 354 diff --git a/linux-user/s390x/syscall_nr.h b/linux-user/s390x/syscall_nr.h index d4529ac..7c0b8b2 100644 --- a/linux-user/s390x/syscall_nr.h +++ b/linux-user/s390x/syscall_nr.h @@ -265,6 +265,12 @@ #define TARGET_NR_open_by_handle_at 336 #define TARGET_NR_clock_adjtime 337 #define TARGET_NR_syncfs 338 +#define TARGET_NR_setns 339 +#define TARGET_NR_process_vm_readv 340 +#define TARGET_NR_process_vm_writev 341 +#define TARGET_NR_s390_runtime_instr 342 +#define TARGET_NR_kcmp 343 +#define TARGET_NR_finit_module 344 /* * There are some system calls that are not present on 64 bit, some @@ -355,4 +361,3 @@ #define TARGET_NR_newfstatat 293 #endif - diff --git a/linux-user/sh4/syscall_nr.h b/linux-user/sh4/syscall_nr.h index 365db58..bdf8742 100644 --- a/linux-user/sh4/syscall_nr.h +++ b/linux-user/sh4/syscall_nr.h @@ -366,3 +366,9 @@ #define TARGET_NR_open_by_handle_at 360 #define TARGET_NR_clock_adjtime 361 #define TARGET_NR_syncfs 362 +#define TARGET_NR_sendmmsg 363 +#define TARGET_NR_setns 364 +#define TARGET_NR_process_vm_readv 365 +#define TARGET_NR_process_vm_writev 366 +#define TARGET_NR_kcmp 367 +#define TARGET_NR_finit_module 368 diff --git a/linux-user/sparc/syscall_nr.h b/linux-user/sparc/syscall_nr.h index 534e6e9..181cd32 100644 --- a/linux-user/sparc/syscall_nr.h +++ b/linux-user/sparc/syscall_nr.h @@ -302,3 +302,10 @@ #define TARGET_NR_open_by_handle_at 333 #define TARGET_NR_clock_adjtime 334 #define TARGET_NR_syncfs 335 +#define TARGET_NR_sendmmsg 336 +#define TARGET_NR_setns 337 +#define TARGET_NR_process_vm_readv 338 +#define TARGET_NR_process_vm_writev 339 +#define TARGET_NR_kern_features 340 +#define TARGET_NR_kcmp 341 +#define TARGET_NR_finit_module 342 diff --git a/linux-user/sparc64/syscall_nr.h b/linux-user/sparc64/syscall_nr.h index 70988b2..34a984c 100644 --- a/linux-user/sparc64/syscall_nr.h +++ b/linux-user/sparc64/syscall_nr.h @@ -334,3 +334,10 @@ #define TARGET_NR_open_by_handle_at 333 #define TARGET_NR_clock_adjtime 334 #define TARGET_NR_syncfs 335 +#define TARGET_NR_sendmmsg 336 +#define TARGET_NR_setns 337 +#define TARGET_NR_process_vm_readv 338 +#define TARGET_NR_process_vm_writev 339 +#define TARGET_NR_kern_features 340 +#define TARGET_NR_kcmp 341 +#define TARGET_NR_finit_module 342 diff --git a/linux-user/x86_64/syscall_nr.h b/linux-user/x86_64/syscall_nr.h index 947e961..7c59e3a 100644 --- a/linux-user/x86_64/syscall_nr.h +++ b/linux-user/x86_64/syscall_nr.h @@ -305,3 +305,10 @@ #define TARGET_NR_open_by_handle_at 304 #define TARGET_NR_clock_adjtime 305 #define TARGET_NR_syncfs 306 +#define TARGET_NR_sendmmsg 307 +#define TARGET_NR_setns 308 +#define TARGET_NR_getcpu 309 +#define TARGET_NR_process_vm_readv 310 +#define TARGET_NR_process_vm_writev 311 +#define TARGET_NR_kcmp 312 +#define TARGET_NR_finit_module 313