Skip to contentSkip to conversation

system calls not intended for user space

DISCUSSION Alejandro Colomar (man-pages) 2 participants 5 messages May 13, 2021 – May 17, 2021 Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

lore
Share & tools
lore
#0 lore raw

Hello Michael,

There are some syscalls that are not intended to be used from user space. See restart_syscall(2). Should I document those as syscall(SYS_...) or not? How are they called within the kernel? As sys_restart_syscall()?

Thanks,

Alex

Signature · 3 lines
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/
#1 lore raw

Hi Alex,

Quoted 6 lines · Alejandro Colomar (man-pages)

Hello Michael,

There are some syscalls that are not intended to be used from user space. See restart_syscall(2). Should I document those as syscall(SYS_...) or not?

Yes, this function is an odd case. (Are there others? Perhaps sigreturn(2) also.)

I think I would just ignore these two. (That is, no changes.)

Quoted 2 lines

How are they called within the kernel? As
sys_restart_syscall()?

I'm not sure of the details, I'm sorry.

Thanks,

Michael

#2 lore raw

Hi Michael,

Quoted 5 lines · Michael Kerrisk (man-pages)

Hi Alex,

Quoted 1 line · Alejandro Colomar (man-pages)
Quoted 8 lines
Quoted 5 lines

Hello Michael,

There are some syscalls that are not intended to be used from user space. See restart_syscall(2). Should I document those as syscall(SYS_...) or not?

Yes, this function is an odd case. (Are there others? Perhaps sigreturn(2) also.)

rt_sigqueueinfo.2 maybe, for which, by the way, I sent a patch recently, so you may prefer to ingore it.

Quoted 2 lines

I think I would just ignore these two. (That is, no changes.)

Agree. I sent the patch for rt_sigqueueinfo.2 because in NOTES it already talked about syscall(2), and by the DESCRIPTION it looks like it's used by library writers (that's user space).

Thanks,

Alex

Signature · 3 lines
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/
#3 lore raw

Hi Michael,

Quoted 17 lines · Alejandro Colomar (man-pages)

Hi Michael,

Quoted 5 lines · Michael Kerrisk (man-pages)

Hi Alex,

Quoted 1 line · Alejandro Colomar (man-pages)
Quoted 8 lines
Quoted 5 lines

Hello Michael,

There are some syscalls that are not intended to be used from user space.  See restart_syscall(2).  Should I document those as syscall(SYS_...) or not?

Yes, this function is an odd case. (Are there others? Perhaps sigreturn(2) also.)

Quoted 6 lines

rt_sigqueueinfo.2 maybe, for which, by the way, I sent a patch recently, so you may prefer to ingore it.

Quoted 2 lines

I think I would just ignore these two. (That is, no changes.)

Agree.  I sent the patch for rt_sigqueueinfo.2 because in NOTES it already talked about syscall(2), and by the DESCRIPTION it looks like it's used by library writers (that's user space).

I see you've applied the patch (it was 2/8 that you applied today (<https://lore.kernel.org/linux-man/[email protected]/T/#u>)).
Check this before pushing and decide :)

Cheers,

Alex

Signature · 3 lines
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/
#4 lore raw

Hi Alex,

Quoted 27 lines · Alejandro Colomar (man-pages)

Hi Michael,

Quoted 23 lines · Alejandro Colomar (man-pages)

Hi Michael,

Quoted 5 lines · Michael Kerrisk (man-pages)

Hi Alex,

Quoted 1 line · Alejandro Colomar (man-pages)
Quoted 8 lines
Quoted 5 lines

Hello Michael,

There are some syscalls that are not intended to be used from user space. See restart_syscall(2). Should I document those as syscall(SYS_...) or not?

Yes, this function is an odd case. (Are there others? Perhaps sigreturn(2) also.)

rt_sigqueueinfo.2 maybe, for which, by the way, I sent a patch recently, so you may prefer to ingore it.

Quoted 2 lines

I think I would just ignore these two. (That is, no changes.)

Quoted 8 lines
Quoted 3 lines

Agree. I sent the patch for rt_sigqueueinfo.2 because in NOTES it already talked about syscall(2), and by the DESCRIPTION it looks like it's used by library writers (that's user space).

I see you've applied the patch (it was 2/8 that you applied today
(<https://lore.kernel.org/linux-man/[email protected]/T/#u>)).
Check this before pushing and decide :)

D'oh! Thanks for catching that. In the meantime, I will drop that patch.

Cheers,

Michael

Signature · 3 lines
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
Linux/UNIX System Programming Training: http://man7.org/training/