Skip to contentSkip to conversation

System call select on R4600

DISCUSSION Macleod 2 participants 2 messages Aug 22, 2004 MIPS

lore
Share & tools
lore

Macleod

author
#0 lore raw

My problem is "select" system call always return -1 and errno is -4142, but sys_select has never been called. Think, it has some problem on handling system call. Because if I change SYS(sys_select, 5) to 4 arguments, sys_select will be executed.
Thanks!

Compiler: gcc-3.3.3
Kernel: mips-linux-2.4.25/mips-linux-2.4.26
Compile parameter:
-Wno-inline \
-Werror-implicit-function-declarations \
-fno-PIC \
-fno-common \
-mno-abicalls \
-mlong-calls \
-march=r4600 \
-mtune=r4600 \
-G 0 \
-Wa,--trap

#1 lore raw
Quoted 6 lines · Macleod

My problem is "select" system call always return -1 and errno is -4142, but sys_select has never been called. Think, it has some problem on handling system call. Because if I change SYS(sys_select, 5) to 4 arguments, sys_select will be executed.
Thanks!

This is a bug which was fixed a while ago. I assume your application is picking up a bad definition from an old kernel header package or so. Still doing syscalls directly is a fragily; better avoid and use your libc's select(3).

Ralf