From e5a6c3f62dde6bc1b6a26957b866c3f27dc28c3a Mon Sep 17 00:00:00 2001 From: Steven Jenkins Date: Tue, 20 Jan 2009 03:29:01 +0000 Subject: [PATCH] undo-rename-residency-from-mrafs-to-osd-20090119 LICENSE IPL10 FIXES 124130 restore the mr-afs names until such time as the pioctl registrations are addressed. --- src/afs/afs_pioctl.c | 22 +++++++++++----------- src/config/vioc.h | 5 ++--- src/fsint/afsint.xg | 10 +++++----- src/viced/afsfileprocs.c | 18 ++++-------------- 4 files changed, 22 insertions(+), 33 deletions(-) diff --git a/src/afs/afs_pioctl.c b/src/afs/afs_pioctl.c index adb314f68c..5e5a5c06f9 100644 --- a/src/afs/afs_pioctl.c +++ b/src/afs/afs_pioctl.c @@ -114,7 +114,7 @@ DECL_PIOCTL(PFlushMount); DECL_PIOCTL(PRxStatProc); DECL_PIOCTL(PRxStatPeer); DECL_PIOCTL(PPrefetchFromTape); -DECL_PIOCTL(PFsCmd); +DECL_PIOCTL(PResidencyCmd); DECL_PIOCTL(PCallBackAddr); DECL_PIOCTL(PDiscon); DECL_PIOCTL(PNFSNukeCreds); @@ -219,7 +219,7 @@ static pioctlFunction VpioctlSw[] = { PBogus, /* 64 -- arla: force cache check */ PBogus, /* 65 -- arla: break callback */ PPrefetchFromTape, /* 66 -- MR-AFS: prefetch file from tape */ - PFsCmd, /* 67 -- RXOSD: generic commnd interface */ + PResidencyCmd, /* 67 -- MR-AFS: generic commnd interface */ PBogus, /* 68 -- arla: fetch stats */ PGetVnodeXStatus2, /* 69 - get caller access and some vcache status */ }; @@ -4421,21 +4421,21 @@ DECL_PIOCTL(PPrefetchFromTape) return code; } -DECL_PIOCTL(PFsCmd) +DECL_PIOCTL(PResidencyCmd) { register afs_int32 code; struct conn *tc; struct vcache *tvc; - struct FsCmdInputs *Inputs; - struct FsCmdOutputs *Outputs; + struct ResidencyCmdInputs *Inputs; + struct ResidencyCmdOutputs *Outputs; struct VenusFid tfid; struct AFSFid *Fid; - Inputs = (struct FsCmdInputs *)ain; - Outputs = (struct FsCmdOutputs *)aout; + Inputs = (struct ResidencyCmdInputs *)ain; + Outputs = (struct ResidencyCmdOutputs *)aout; if (!avc) return EINVAL; - if (!ain || ainSize != sizeof(struct FsCmdInputs)) + if (!ain || ainSize != sizeof(struct ResidencyCmdInputs)) return EINVAL; Fid = &Inputs->fid; @@ -4459,8 +4459,8 @@ DECL_PIOCTL(PFsCmd) if (tc) { RX_AFS_GUNLOCK(); code = - RXAFS_FsCmd(tc->id, Fid, Inputs, - (struct FsCmdOutputs *)aout); + RXAFS_ResidencyCmd(tc->id, Fid, Inputs, + (struct ResidencyCmdOutputs *)aout); RX_AFS_GLOCK(); } else code = -1; @@ -4484,7 +4484,7 @@ DECL_PIOCTL(PFsCmd) afs_PutVCache(tvc); if (!code) { - *aoutSize = sizeof(struct FsCmdOutputs); + *aoutSize = sizeof(struct ResidencyCmdOutputs); } return code; } diff --git a/src/config/vioc.h b/src/config/vioc.h index b3b4a73fcb..58ac92aedb 100644 --- a/src/config/vioc.h +++ b/src/config/vioc.h @@ -87,9 +87,8 @@ #define VIOC_RXSTAT_PEER _VICEIOCTL(54) /* Control peer RX stats */ #define VIOC_GETRXKCRYPT _VICEIOCTL(55) /* Set rxkad enc flag */ #define VIOC_SETRXKCRYPT _VICEIOCTL(56) /* Set rxkad enc flag */ -#define VIOC_PREFETCHTAPE _VICEIOCTL(66) /* osd prefetch from tape */ -#define VIOC_FS_CMD _VICEIOCTL(67) /* fs extensions for osd etc. */ - +#define VIOC_PREFETCHTAPE _VICEIOCTL(66) /* MR-AFS prefetch from tape */ +#define VIOC_RESIDENCY_CMD _VICEIOCTL(67) /* generic MR-AFS cmds */ #define VIOC_STATISTICS _VICEIOCTL(68) /* arla: fetch statistics */ #define VIOC_GETVCXSTATUS2 _VICEIOCTL(69) /* vcache statistics */ diff --git a/src/fsint/afsint.xg b/src/fsint/afsint.xg index 709f392642..f65916364e 100644 --- a/src/fsint/afsint.xg +++ b/src/fsint/afsint.xg @@ -389,7 +389,7 @@ struct AccessHistoryOld { afs_uint32 Residency4; }; -struct FsCmdInputs { +struct ResidencyCmdInputs { afs_int32 command; struct AFSFid fid; afs_int64 int64s[MAXCMDINT64S]; @@ -397,7 +397,7 @@ struct FsCmdInputs { char chars[MAXCMDCHARS]; }; -struct FsCmdOutputs { +struct ResidencyCmdOutputs { afs_int32 code; struct AFSFetchStatus status; afs_int64 int64s[MAXCMDINT64S]; @@ -656,10 +656,10 @@ DFSSymlink( AFSVolSync *Sync ) = 163; -FsCmd( +ResidencyCmd( IN AFSFid *Fid, - IN struct FsCmdInputs *Inputs, - OUT struct FsCmdOutputs *Outputs + IN struct ResidencyCmdInputs *Inputs, + OUT struct ResidencyCmdOutputs *Outputs ) = 220; InlineBulkStatus( diff --git a/src/viced/afsfileprocs.c b/src/viced/afsfileprocs.c index 104ff73b9e..d2f418b076 100644 --- a/src/viced/afsfileprocs.c +++ b/src/viced/afsfileprocs.c @@ -1938,21 +1938,11 @@ SRXAFS_DFSSymlink(struct rx_call *acall, struct AFSFid *DirFid, char *Name, } afs_int32 -SRXAFS_FsCmd(struct rx_call * acall, struct AFSFid * Fid, - struct FsCmdInputs * Inputs, - struct FsCmdOutputs * Outputs) +SRXAFS_ResidencyCmd(struct rx_call * acall, struct AFSFid * Fid, + struct ResidencyCmdInputs * Inputs, + struct ResidencyCmdOutputs * Outputs) { - afs_int32 code = 0; - struct AFSCallBack callback; - struct AFSVolSync sync; - - switch (Inputs->command) { - default: - code = EINVAL; - } - ViceLog(1,("FsCmd: cmd = %d, code=%d\n", - Inputs->command, Outputs->code)); - return code; + return EINVAL; } #ifdef AFS_NT40_ENV