From: David van Moolenbroek Date: Thu, 12 Jan 2012 23:49:37 +0000 (+0100) Subject: vfs/avfs: renumber stat calls so as to be unique X-Git-Tag: v3.2.0~122 X-Git-Url: http://zhaoyanbai.com/repos/%22http:/www.isc.org/icons/doxygen.log?a=commitdiff_plain;h=c89aaf7a87468ee6932e59557fd8d82200cd1830;p=minix.git vfs/avfs: renumber stat calls so as to be unique The old stat call numbers are still supported for a while. --- diff --git a/common/include/minix/callnr.h b/common/include/minix/callnr.h index 2fec5d1d4..519ca4154 100644 --- a/common/include/minix/callnr.h +++ b/common/include/minix/callnr.h @@ -1,5 +1,6 @@ #define NCALLS 114 /* number of system calls allowed */ +/* In case it isn't obvious enough: this list is sorted numerically. */ #define EXIT 1 #define FORK 2 #define READ 3 @@ -48,6 +49,9 @@ #define SIGNAL 48 #define RDLNK 49 #define PREV_LSTAT 50 +#define STAT 51 +#define FSTAT 52 +#define LSTAT 53 #define IOCTL 54 #define FCNTL 55 #define FS_READY 57 @@ -105,11 +109,6 @@ #define GCOV_FLUSH 112 /* flush gcov data from server to gcov files */ -/* Numbers reused intentionally */ -#define STAT 65 -#define FSTAT 66 -#define LSTAT 67 - #define PM_GETSID 113 /* PM getsid() */ #define TASK_REPLY 121 /* to VFS: reply code from drivers, not diff --git a/servers/avfs/table.c b/servers/avfs/table.c index 67cd27089..4429e3192 100644 --- a/servers/avfs/table.c +++ b/servers/avfs/table.c @@ -66,9 +66,9 @@ PUBLIC _PROTOTYPE (int (*call_vec[]), (void) ) = { no_sys, /* 48 = (signal)*/ do_rdlink, /* 49 = readlink*/ do_lstat, /* 50 = lstat (prev)*/ - no_sys, /* 51 = (acct) */ - no_sys, /* 52 = (phys) */ - no_sys, /* 53 = (lock) */ + do_stat, /* 51 = stat */ + do_fstat, /* 52 = fstat */ + do_lstat, /* 53 = lstat */ do_ioctl, /* 54 = ioctl */ do_fcntl, /* 55 = fcntl */ no_sys, /* 56 = (mpx) */ @@ -80,9 +80,9 @@ PUBLIC _PROTOTYPE (int (*call_vec[]), (void) ) = { no_sys, /* 62 = (setsid)*/ no_sys, /* 63 = (getpgrp)*/ no_sys, /* 64 = (itimer)*/ - do_stat, /* 65 = stat */ - do_fstat, /* 66 = fstat */ - do_lstat, /* 67 = lstat */ + do_stat, /* 65 = stat - badly numbered, being phased out */ + do_fstat, /* 66 = fstat - badly numbered, being phased out */ + do_lstat, /* 67 = lstat - badly numbered, being phased out */ no_sys, /* 68 = unused */ no_sys, /* 69 = unused */ no_sys, /* 70 = unused */ diff --git a/servers/pm/table.c b/servers/pm/table.c index 5df101508..b3ebce882 100644 --- a/servers/pm/table.c +++ b/servers/pm/table.c @@ -62,9 +62,9 @@ _PROTOTYPE (int (*call_vec[]), (void) ) = { no_sys, /* 48 = (signal)*/ no_sys, /* 49 = unused */ no_sys, /* 50 = lstat */ - no_sys, /* 51 = unused */ - no_sys, /* 52 = unused */ - no_sys, /* 53 = unused */ + no_sys, /* 51 = (stat) */ + no_sys, /* 52 = (fstat) */ + no_sys, /* 53 = (lstat) */ no_sys, /* 54 = ioctl */ no_sys, /* 55 = fcntl */ no_sys, /* 56 = unused */ diff --git a/servers/vfs/table.c b/servers/vfs/table.c index 629d6501f..5b59ca9b5 100644 --- a/servers/vfs/table.c +++ b/servers/vfs/table.c @@ -66,9 +66,9 @@ PUBLIC _PROTOTYPE (int (*call_vec[]), (void) ) = { no_sys, /* 48 = (signal)*/ do_rdlink, /* 49 = readlink*/ do_lstat, /* 50 = lstat (prev)*/ - no_sys, /* 51 = unused */ - no_sys, /* 52 = unused */ - no_sys, /* 53 = unused */ + do_stat, /* 51 = stat */ + do_fstat, /* 52 = fstat */ + do_lstat, /* 53 = lstat */ do_ioctl, /* 54 = ioctl */ do_fcntl, /* 55 = fcntl */ no_sys, /* 56 = unused */ @@ -80,9 +80,9 @@ PUBLIC _PROTOTYPE (int (*call_vec[]), (void) ) = { no_sys, /* 62 = (setsid)*/ no_sys, /* 63 = (getpgrp)*/ no_sys, /* 64 = (itimer)*/ - do_stat, /* 65 = stat */ - do_fstat, /* 66 = fstat */ - do_lstat, /* 67 = lstat */ + do_stat, /* 65 = stat - badly numbered, being phased out */ + do_fstat, /* 66 = fstat - badly numbered, being phased out */ + do_lstat, /* 67 = lstat - badly numbered, being phased out */ no_sys, /* 68 = unused */ no_sys, /* 69 = unused */ no_sys, /* 70 = unused */