Skip to contentSkip to conversation

m68k: don't comment out syscalls used by glibc

PATCH In review Andreas Schwab 2 participants 6 messages Nov 1, 2011 – Nov 20, 2011 m68k architecture

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 m68k: don't comment out syscalls used by glibc

Define again the syscalls that are used by glibc so that it is possible to compile a feature-complete glibc with the newest kernel headers.

---
 arch/m68k/include/asm/unistd.h |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)
arch/m68k/include/asm/unistd.h +5 -5
index 43f984e..d97234b 100644
@@ -132,10 +132,10 @@
 #define __NR_adjtimex		124
 #define __NR_mprotect		125
 #define __NR_sigprocmask	126
-/*#define __NR_create_module	127*/
+#define __NR_create_module	127
 #define __NR_init_module	128
 #define __NR_delete_module	129
-/*#define __NR_get_kernel_syms	130*/
+#define __NR_get_kernel_syms	130
 #define __NR_quotactl		131
 #define __NR_getpgid		132
 #define __NR_fchdir		133
@@ -172,7 +172,7 @@
 #define __NR_setresuid		164
 #define __NR_getresuid		165
 #define __NR_getpagesize	166
-/*#define __NR_query_module	167*/
+#define __NR_query_module	167
 #define __NR_poll		168
 #define __NR_nfsservctl		169
 #define __NR_setresgid		170
@@ -193,8 +193,8 @@
 #define __NR_capset		185
 #define __NR_sigaltstack	186
 #define __NR_sendfile		187
-/*#define __NR_getpmsg		188*/	/* some people actually want streams */
-/*#define __NR_putpmsg		189*/	/* some people actually want streams */
+#define __NR_getpmsg		188	/* some people actually want streams */
+#define __NR_putpmsg		189	/* some people actually want streams */
 #define __NR_vfork		190
 #define __NR_ugetrlimit		191
 #define __NR_mmap2		192
Signature · 7 lines
1.7.7.1


-- 
Andreas Schwab, [email protected]
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
#1 lore raw

Hi Andreas,

Quoted 2 lines · Andreas Schwab

Define again the syscalls that are used by glibc so that it is possible to compile a feature-complete glibc with the newest kernel headers.

I'm a bit puzzled by this. What exactly is your objective? To build a glibc that runs on any possible kernel version ever released?

Quoted 23 lines

---
 arch/m68k/include/asm/unistd.h |   10 +++++-----

 1 files changed, 5 insertions(+), 5 deletions(-)
arch/m68k/include/asm/unistd.h +2 -2
index 43f984e..d97234b 100644
@@ -132,10 +132,10 @@
  #define __NR_adjtimex          124
  #define __NR_mprotect          125
  #define __NR_sigprocmask       126
-/*#define __NR_create_module   127*/
+#define __NR_create_module     127
  #define __NR_init_module       128
  #define __NR_delete_module     129
-/*#define __NR_get_kernel_syms 130*/
+#define __NR_get_kernel_syms   130
  #define __NR_quotactl          131
  #define __NR_getpgid           132
  #define __NR_fchdir            133

arch/m68k/include/asm/unistd.h line 175

Quoted 5 lines
arch/m68k/include/asm/unistd.h +1 -1
@@ -172,7 +172,7 @@
  #define __NR_setresuid         164
  #define __NR_getresuid         165
  #define __NR_getpagesize       166
-/*#define __NR_query_module    167*/
+#define __NR_query_module      167

Support for the three syscalls above got removed day to day 10 years ago, when adding support for Rusty's "In-kernel Module Loader" for 2.5.48. So I guess you need them for 2.4? I can understand that.

Quoted 4 lines
arch/m68k/include/asm/unistd.h +0 -0
  #define __NR_poll              168
  #define __NR_nfsservctl                169
  #define __NR_setresgid         170

arch/m68k/include/asm/unistd.h line 200

Quoted 10 lines
arch/m68k/include/asm/unistd.h +2 -2
@@ -193,8 +193,8 @@
  #define __NR_capset            185
  #define __NR_sigaltstack       186
  #define __NR_sendfile          187
-/*#define __NR_getpmsg         188*/   /* some people actually want streams */
-/*#define __NR_putpmsg         189*/   /* some people actually want streams */
+#define __NR_getpmsg           188     /* some people actually want streams */
+#define __NR_putpmsg           189     /* some people actually want streams */
  #define __NR_vfork             190
  #define __NR_ugetrlimit                191
  #define __NR_mmap2             192

AFAIK, the upstream kernel never had an implementation for sys_{get,put}msg(). I did find "[Linux-streams] [PATCH] Linux-streams registration 2.5.46"
(http://www.mail-archive.com/[email protected]/msg00639.html)

2.1.115pre1 added placeholders on i386, and we just followed suit. Why do you need these?

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

#2 lore raw
Quoted 8 lines · Geert Uytterhoeven

Hi Andreas,

Quoted 2 lines · Andreas Schwab

Define again the syscalls that are used by glibc so that it is possible to compile a feature-complete glibc with the newest kernel headers.

I'm a bit puzzled by this. What exactly is your objective? To build a glibc that runs on any possible kernel version ever released?

When building glibc it needs to know these numbers. Otherwise only stubs are generated that never try to use them.

Andreas.

Signature · 3 lines
Andreas Schwab, [email protected]
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
#3 lore raw

Hi Andreas,

Quoted 10 lines · Andreas Schwab
Quoted 6 lines · Geert Uytterhoeven
Quoted 2 lines · Andreas Schwab

Define again the syscalls that are used by glibc so that it is possible to compile a feature-complete glibc with the newest kernel headers.

I'm a bit puzzled by this. What exactly is your objective? To build a glibc that runs on any possible kernel version ever released?

When building glibc it needs to know these numbers.  Otherwise only stubs are generated that never try to use them.

Yes, I know that.

What's the user experience advantage of glibc knowing about the syscall numbers for (never implemented) streams?

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds

#4 lore raw
Quoted 2 lines · Geert Uytterhoeven

What's the user experience advantage of glibc knowing about the syscall numbers for (never implemented) streams?

It will try to use them, instead of denying their existence.

There is no advantage in removing these definitions.

Andreas.

Signature · 3 lines
Andreas Schwab, [email protected]
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
#5 lore raw

Hi Andreas,

Quoted 8 lines · Andreas Schwab
Quoted 2 lines · Geert Uytterhoeven

What's the user experience advantage of glibc knowing about the syscall numbers for (never implemented) streams?

It will try to use them, instead of denying their existence.

There is no advantage in removing these definitions.

You convinced me. Queued for 3.3.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds