2 * Copyright 2000, International Business Machines Corporation and others.
3 * Copyright 2011, Your File System Inc
6 * This software has been released under the terms of the IBM Public
7 * License. For details, see the LICENSE file in the top-level source
8 * directory or online at http://www.openafs.org/dl/license10.html
11 #include <afsconfig.h>
12 #include <afs/param.h>
19 #include "rx_atomic.h"
20 #include "rx_internal.h"
22 struct rx_connection *
23 rx_ConnectionOf(struct rx_call *call)
29 rx_Error(struct rx_call *call)
35 rx_GetRemoteStatus(struct rx_call *call)
37 return call->remoteStatus;
41 rx_SetLocalStatus(struct rx_call *call, int status)
43 call->localStatus = status;
47 rx_GetCallAbortCode(struct rx_call *call)
49 return call->abortCode;
53 rx_SetCallAbortCode(struct rx_call *call, int code)
55 call->abortCode = code;
59 rx_RecordCallStatistics(struct rx_call *call, unsigned int rxInterface,
60 unsigned int currentFunc, unsigned int totalFunc,
67 clock_Sub(&exec, &call->startTime);
68 queue = call->startTime;
69 clock_Sub(&queue, &call->queueTime);
71 rxi_IncrementTimeAndCount(call->conn->peer, rxInterface, currentFunc,
72 totalFunc, &queue, &exec, call->app.bytesSent,
73 call->app.bytesRcvd, isServer);
77 * Accessor for VolMonitor 'vos status'
78 * note: the rx_call members are all unsigned, but our return targets
79 * in wire struct transDebugInfo are all signed. Sigh.
82 rx_GetCallStatus(struct rx_call *call, afs_int32 *readNext,
83 afs_int32 *transmitNext, int *lastSendTime,
87 *readNext = call->rnext;
88 if (transmitNext != NULL)
89 *transmitNext = call->tnext;
90 if (lastSendTime != NULL)
91 *lastSendTime = call->lastSendTime;
92 if (lastReceiveTime != NULL)
93 *lastReceiveTime = call->lastReceiveTime;