*------------------------------------------------------------------------*/
static int xstat_cm_CleanupInit()
-
-{ /*xstat_cm_CleanupInit*/
-
+{
xstat_cm_ConnInfo = (struct xstat_cm_ConnectionInfo *)0;
xstat_cm_Results.probeNum = 0;
xstat_cm_Results.probeTime = 0;
xstat_cm_Results.probeOK = 0;
return(0);
-
-} /*xstat_cm_CleanupInit*/
+}
/*------------------------------------------------------------------------
* (if so directed).
*------------------------------------------------------------------------*/
-int xstat_cm_Cleanup(a_releaseMem)
- int a_releaseMem;
-
-{ /*xstat_cm_Cleanup*/
-
+int xstat_cm_Cleanup(int a_releaseMem)
+{
static char rn[] = "xstat_cm_Cleanup"; /*Routine name*/
int code; /*Return code*/
int conn_idx; /*Current connection index*/
* Return the news, whatever it is.
*/
return(code);
-
-} /*xstat_cm_Cleanup*/
+}
/*------------------------------------------------------------------------
* Side Effects:
* As advertised.
*------------------------------------------------------------------------*/
-
static void xstat_cm_LWP()
-
-{ /*xstat_cm_LWP*/
-
+{
static char rn[] = "xstat_cm_LWP"; /*Routine name*/
register afs_int32 code; /*Results of calls*/
int oneShotCode; /*Result of one-shot signal*/
rn, code);
} /*Continuous execution*/
} /*Service loop*/
-
-} /*xstat_cm_LWP*/
+}
/*------------------------------------------------------------------------
* Sets up just about everything.
*------------------------------------------------------------------------*/
-int xstat_cm_Init(a_numServers, a_socketArray, a_ProbeFreqInSecs,
- a_ProbeHandler, a_flags, a_numCollections, a_collIDP)
- int a_numServers;
- struct sockaddr_in *a_socketArray;
- int a_ProbeFreqInSecs;
- int (*a_ProbeHandler)();
- int a_flags;
- int a_numCollections;
- afs_int32 *a_collIDP;
-
-{ /*xstat_cm_Init*/
+int xstat_cm_Init(int a_numServers, struct sockaddr_in *a_socketArray,
+ int a_ProbeFreqInSecs, int (*a_ProbeHandler)(), int a_flags,
+ int a_numCollections, afs_int32 *a_collIDP)
+{
static char rn[] = "xstat_cm_Init"; /*Routine name*/
register afs_int32 code; /*Return value*/
return(-2);
else
return(0);
-
-} /*xstat_cm_Init*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
int xstat_cm_ForceProbeNow()
-
-{ /*xstat_cm_ForceProbeNow*/
-
+{
static char rn[] = "xstat_cm_ForceProbeNow"; /*Routine name*/
/*
* We did it, so report the happy news.
*/
return(0);
-
-} /*xstat_cm_ForceProbeNow*/
+}
*------------------------------------------------------------------------*/
static int xstat_fs_CleanupInit()
-
-{ /*xstat_fs_CleanupInit*/
-
+{
afs_int32 code; /*Return code from callback stubs*/
struct rx_call *rxcall; /*Bogus param*/
AFSCBFids *Fids_Array; /*Bogus param*/
return(code);
code = SRXAFSCB_Probe(rxcall);
return(code);
-
-} /*xstat_fs_CleanupInit*/
+}
/*------------------------------------------------------------------------
* (if so directed).
*------------------------------------------------------------------------*/
-int xstat_fs_Cleanup(a_releaseMem)
- int a_releaseMem;
-
-{ /*xstat_fs_Cleanup*/
-
+int xstat_fs_Cleanup(int a_releaseMem)
+{
static char rn[] = "xstat_fs_Cleanup"; /*Routine name*/
int code; /*Return code*/
int conn_idx; /*Current connection index*/
* Return the news, whatever it is.
*/
return(code);
-
-} /*xstat_fs_Cleanup*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
static void xstat_fs_LWP()
-
-{ /*xstat_fs_LWP*/
-
+{
static char rn[] = "xstat_fs_LWP"; /*Routine name*/
register afs_int32 code; /*Results of calls*/
int oneShotCode; /*Result of one-shot signal*/
rn, code);
} /*Continuous execution*/
} /*Service loop*/
-
-} /*xstat_fs_LWP*/
-
+}
/*------------------------------------------------------------------------
* [exported] xstat_fs_Init
* Sets up just about everything.
*------------------------------------------------------------------------*/
-int xstat_fs_Init(a_numServers, a_socketArray, a_ProbeFreqInSecs, a_ProbeHandler,
- a_flags, a_numCollections, a_collIDP)
- int a_numServers;
- struct sockaddr_in *a_socketArray;
- int a_ProbeFreqInSecs;
- int (*a_ProbeHandler)();
- int a_flags;
- int a_numCollections;
- afs_int32 *a_collIDP;
-
-{ /*xstat_fs_Init*/
-
+int xstat_fs_Init(int a_numServers, struct sockaddr_in *a_socketArray,
+ int a_ProbeFreqInSecs, int (*a_ProbeHandler)(), int a_flags,
+ int a_numCollections, afs_int32 *a_collIDP)
+{
static char rn[] = "xstat_fs_Init"; /*Routine name*/
register afs_int32 code; /*Return value*/
static struct rx_securityClass *CBsecobj; /*Callback security object*/
return(-2);
else
return(0);
-
-} /*xstat_fs_Init*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
int xstat_fs_ForceProbeNow()
-
-{ /*xstat_fs_ForceProbeNow*/
-
+{
static char rn[] = "xstat_fs_ForceProbeNow"; /*Routine name*/
/*
* We did it, so report the happy news.
*/
return(0);
-
-} /*xstat_fs_ForceProbeNow*/
+}
*------------------------------------------------------------------------*/
void PrintCallInfo()
-
{ /*PrintCallInfo*/
static char rn[] = "PrintCallInfo"; /*Routine name*/
* As advertised.
*------------------------------------------------------------------------*/
-void PrintOverallPerfInfo(a_ovP)
- struct afs_PerfStats *a_ovP;
-
-{ /*PrintOverallPerfInfo*/
-
+void PrintOverallPerfInfo(struct afs_PerfStats *a_ovP)
+{
printf("\t%10d numPerfCalls\n\n", a_ovP->numPerfCalls);
/*
printf("\t%10d host_ClientBlocks\n\n", a_ovP->host_ClientBlocks);
printf("\t%10d sysname_ID\n", a_ovP->sysname_ID);
-
-} /*PrintOverallPerfInfo*/
+}
/*------------------------------------------------------------------------
* As advertised.
*------------------------------------------------------------------------*/
-void PrintOpTiming(a_opIdx, a_opTimeP)
- int a_opIdx;
- struct fs_stats_opTimingData *a_opTimeP;
-
-{ /*PrintOpTiming*/
-
+void PrintOpTiming(int a_opIdx, struct fs_stats_opTimingData *a_opTimeP)
+{
double fSumTime, avg;
fSumTime = ((double)(a_opTimeP->sumTime.tv_sec)) +
a_opTimeP->sqrTime.tv_sec, a_opTimeP->sqrTime.tv_usec,
a_opTimeP->minTime.tv_sec, a_opTimeP->minTime.tv_usec,
a_opTimeP->maxTime.tv_sec, a_opTimeP->maxTime.tv_usec);
-
-} /*PrintOpTiming*/
+}
/*------------------------------------------------------------------------
* As advertised.
*------------------------------------------------------------------------*/
-void PrintXferTiming(a_opIdx, a_xferP)
- int a_opIdx;
- struct fs_stats_xferData *a_xferP;
-
-{ /*PrintXferTiming*/
-
+void PrintXferTiming(int a_opIdx, struct fs_stats_xferData *a_xferP)
+{
double fSumTime, avg;
fSumTime = ((double)(a_xferP->sumTime.tv_sec)) +
a_xferP->count[6],
a_xferP->count[7],
a_xferP->count[8]);
-
-
-} /*PrintXferTiming*/
+}
/*------------------------------------------------------------------------
* As advertised.
*------------------------------------------------------------------------*/
-void PrintDetailedPerfInfo(a_detP)
- struct fs_stats_DetailedStats *a_detP;
-
-{ /*PrintDetailedPerfInfo*/
-
+void PrintDetailedPerfInfo(struct fs_stats_DetailedStats *a_detP)
+{
int currIdx; /*Loop variable*/
printf("\t%10d epoch\n", a_detP->epoch);
for (currIdx = 0; currIdx < FS_STATS_NUM_XFER_OPS; currIdx++)
PrintXferTiming(currIdx, &(a_detP->xferOpTimes[currIdx]));
-
-} /*PrintDetailedPerfInfo*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
void PrintFullPerfInfo()
-
-{ /*PrintFullPerfInfo*/
+{
static char rn[] = "PrintFullPerfInfo"; /*Routine name*/
static afs_int32 fullPerfInt32s =
PrintOverallPerfInfo(&(fullPerfP->overall));
PrintDetailedPerfInfo(&(fullPerfP->det));
-
-} /*PrintFullPerfInfo*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
void PrintPerfInfo()
-
-{ /*PrintPerfInfo*/
-
+{
static char rn[] = "PrintPerfInfo"; /*Routine name*/
static afs_int32 perfInt32s =
(sizeof(struct afs_PerfStats) >> 2); /*Correct # int32s to rcv*/
printableTime);
PrintOverallPerfInfo(perfP);
-
-} /*PrintPerfInfo*/
+}
/*------------------------------------------------------------------------
*------------------------------------------------------------------------*/
int FS_Handler()
-
-{ /*FS_Handler*/
-
+{
static char rn[] = "FS_Handler"; /*Routine name*/
printf("\n------------------------------------------------------------\n");
* Return the happy news.
*/
return(0);
-
-} /*FS_Handler*/
+}
/*------------------------------------------------------------------------
* As advertised.
*------------------------------------------------------------------------*/
-static int CountListItems(a_firstItem)
- struct cmd_item *a_firstItem;
-
-{ /*CountListItems*/
+static int CountListItems(struct cmd_item *a_firstItem)
+{
int list_len; /*List length*/
struct cmd_item *curr_item; /*Ptr to current item*/
* Return our tally.
*/
return(list_len);
-
-} /*CountListItems*/
+}
/*------------------------------------------------------------------------
* As advertised.
*------------------------------------------------------------------------*/
-int RunTheTest(a_s)
- struct cmd_syndesc *a_s;
-
-{ /*RunTheTest*/
-
+int RunTheTest(struct cmd_syndesc *a_s)
+{
static char rn[] = "RunTheTest"; /*Routine name*/
int code; /*Return code*/
int numFSs; /*# File Servers to monitor*/
code = xstat_fs_Cleanup(1); /*Get rid of malloc'ed data*/
rx_Finalize();
return(0);
-
-} /*RunTheTest*/
+}
#include "AFS_component_version_number.c"
-main(argc, argv)
- int argc;
- char **argv;
-
-{ /*Main routine*/
-
+int main(int argc, char **argv)
+{
static char rn[] = "xstat_fs_test"; /*Routine name*/
register afs_int32 code; /*Return code*/
struct cmd_syndesc *ts; /*Ptr to cmd line syntax desc*/
}
exit(code);
-
-} /*Main routine*/
+}