#include <XrdXrootdAio.hh>
Inheritance diagram for XrdXrootdAioReq:
Public Member Functions | |
void | DoIt () |
XrdXrootdAio * | getAio () |
XrdXrootdAio * | Pop () |
void | Push (XrdXrootdAio *newp) |
int | Read () |
void | Recycle (int deref=1, XrdXrootdAio *aiop=0) |
int | Write (XrdXrootdAio *aiop) |
XrdXrootdAioReq () | |
~XrdXrootdAioReq () | |
Static Public Member Functions | |
static XrdXrootdAioReq * | Alloc (XrdXrootdProtocol *p, char iot, int numaio=0) |
static void | Init (int iosize, int maxaiopr, int maxaio=-80) |
Private Member Functions | |
void | Clear (XrdLink *lnkp) |
void | endRead () |
void | endWrite () |
void | Lock () |
void | Scuttle (const char *opname) |
void | sendError (char *tident) |
void | UnLock () |
Static Private Member Functions | |
static XrdXrootdAioReq * | addBlock () |
Private Attributes | |
XrdSysMutex | aioMutex |
XrdXrootdAioReq * | Next |
off_t | myOffset |
int | myIOLen |
unsigned int | Instance |
XrdLink * | Link |
XrdXrootdFile * | myFile |
XrdXrootdAio * | aioDone |
XrdXrootdAio * | aioFree |
int | numActive |
int | aioTotal |
int | aioError |
char | aioType |
char | respDone |
char | isLocked |
char | reDrive |
XrdXrootdResponse | Response |
Static Private Attributes | |
static const char * | TraceID |
static XrdSysError * | eDest |
static XrdSysMutex | rqMutex |
static XrdXrootdAioReq * | rqFirst |
static int | QuantumMin |
static int | Quantum |
static int | QuantumMax |
static int | maxAioPR |
static int | maxAioPR2 |
Friends | |
class | XrdXrootdAio |
Definition at line 80 of file XrdXrootdAio.hh.
XrdXrootdAioReq::XrdXrootdAioReq | ( | ) | [inline] |
XrdXrootdAioReq::~XrdXrootdAioReq | ( | ) | [inline] |
Definition at line 109 of file XrdXrootdAio.hh.
XrdXrootdAioReq * XrdXrootdAioReq::Alloc | ( | XrdXrootdProtocol * | p, | |
char | iot, | |||
int | numaio = 0 | |||
) | [static] |
Definition at line 222 of file XrdXrootdAio.cc.
References addBlock(), XrdXrootdAio::Alloc(), Clear(), i, XrdLink::Inst(), XrdXrootdProtocol::Link, XrdSysMutex::Lock(), maxAioPR, maxAioPR2, XrdXrootdProtocol::myFile, XrdXrootdProtocol::myIOLen, XrdXrootdProtocol::myOffset, Next, XrdXrootdAio::Next, Quantum, QuantumMax, QuantumMin, XrdXrootdAio::Recycle(), XrdXrootdProtocol::Response, rqFirst, rqMutex, XrdLink::setRef(), and XrdSysMutex::UnLock().
Referenced by XrdXrootdProtocol::aio_Read(), and XrdXrootdProtocol::aio_Write().
void XrdXrootdAioReq::DoIt | ( | ) | [inline, virtual] |
Implements XrdJob.
Definition at line 87 of file XrdXrootdAio.hh.
References aioType, endRead(), and endWrite().
XrdXrootdAio * XrdXrootdAioReq::getAio | ( | ) |
Definition at line 290 of file XrdXrootdAio.cc.
References aioFree, Lock(), XrdXrootdAio::Next, reDrive, and UnLock().
Referenced by XrdXrootdProtocol::aio_WriteAll().
XrdXrootdAio* XrdXrootdAioReq::Pop | ( | ) | [inline] |
Definition at line 93 of file XrdXrootdAio.hh.
References aioDone, and XrdXrootdAio::Next.
Referenced by XrdXrootdProtocol::aio_WriteCont().
void XrdXrootdAioReq::Push | ( | XrdXrootdAio * | newp | ) | [inline] |
Definition at line 97 of file XrdXrootdAio.hh.
References aioDone, and XrdXrootdAio::Next.
Referenced by XrdXrootdProtocol::aio_WriteAll().
void XrdXrootdAioReq::Init | ( | int | iosize, | |
int | maxaiopr, | |||
int | maxaio = -80 | |||
) | [static] |
Definition at line 310 of file XrdXrootdAio.cc.
References addBlock(), XrdXrootdAio::addBlock(), XrdXrootdAio::BPool, XrdXrootdProtocol::BPool, Clear(), DEBUG, eDest, XrdXrootdProtocol::eDest, XrdXrootdAio::maxAio, maxAioPR, maxAioPR2, XrdXrootdProtocol::maxBuffsz, Quantum, QuantumMax, QuantumMin, XrdXrootdAio::Recycle(), Recycle(), XrdXrootdProtocol::Sched, XrdXrootdAio::Sched, XrdXrootdAio::SI, XrdXrootdProtocol::SI, and TRACE.
Referenced by XrdXrootdProtocol::Configure().
int XrdXrootdAioReq::Read | ( | ) |
Definition at line 355 of file XrdXrootdAio.cc.
References aiocb::aio_nbytes, aiocb::aio_offset, aioFree, XrdBuffer::bsize, XrdXrootdAio::buffp, ENOBUFS, myFile, myIOLen, myOffset, XrdXrootdAio::Next, numActive, XrdSfsFile::read(), Recycle(), XrdSfsAio::sfsAio, and XrdXrootdFile::XrdSfsp.
Referenced by XrdXrootdProtocol::aio_Read(), and endRead().
void XrdXrootdAioReq::Recycle | ( | int | deref = 1 , |
|
XrdXrootdAio * | aiop = 0 | |||
) |
Definition at line 394 of file XrdXrootdAio.cc.
References aioDone, aioError, aioFree, aioType, isLocked, Link, XrdSysMutex::Lock(), Lock(), Next, XrdXrootdAio::Next, numActive, XrdXrootdAio::Recycle(), respDone, rqFirst, rqMutex, XrdLink::setRef(), XrdSysMutex::UnLock(), and UnLock().
Referenced by XrdXrootdProtocol::aio_WriteAll(), endRead(), endWrite(), Init(), XrdXrootdProtocol::Process(), Read(), Scuttle(), and Write().
int XrdXrootdAioReq::Write | ( | XrdXrootdAio * | aiop | ) |
Definition at line 442 of file XrdXrootdAio.cc.
References Lock(), myFile, numActive, Recycle(), UnLock(), XrdSfsFile::write(), and XrdXrootdFile::XrdSfsp.
Referenced by XrdXrootdProtocol::aio_WriteAll(), and XrdXrootdProtocol::aio_WriteCont().
void XrdXrootdAioReq::Clear | ( | XrdLink * | lnkp | ) | [private] |
XrdXrootdAioReq * XrdXrootdAioReq::addBlock | ( | ) | [static, private] |
Definition at line 472 of file XrdXrootdAio.cc.
References DEBUG, i, Next, rqFirst, TRACE, and XrdXrootdAioReq().
void XrdXrootdAioReq::endRead | ( | ) | [private] |
Definition at line 514 of file XrdXrootdAio.cc.
References aioDone, aioError, aioFree, aioTotal, XrdBuffer::bsize, XrdBuffer::buff, XrdXrootdAio::buffp, Instance, XrdLink::isInstance(), kXR_oksofar, Link, Lock(), myFile, myIOLen, XrdXrootdAio::Next, numActive, Read(), XrdXrootdFile::readCnt, Recycle(), respDone, Response, XrdSfsAio::Result, Scuttle(), XrdXrootdResponse::Send(), sendError(), XrdSfsAio::TIdent, and UnLock().
Referenced by DoIt().
void XrdXrootdAioReq::endWrite | ( | ) | [private] |
Definition at line 571 of file XrdXrootdAio.cc.
References aioError, aioTotal, XrdLink::ID, Instance, XrdLink::isInstance(), Link, myFile, Recycle(), Response, Scuttle(), XrdXrootdResponse::Send(), sendError(), and XrdXrootdFile::writeCnt.
Referenced by DoIt().
void XrdXrootdAioReq::Lock | ( | ) | [inline, private] |
Definition at line 118 of file XrdXrootdAio.hh.
References aioMutex, isLocked, and XrdSysMutex::Lock().
Referenced by XrdXrootdAio::doneWrite(), endRead(), getAio(), Recycle(), and Write().
void XrdXrootdAioReq::Scuttle | ( | const char * | opname | ) | [private] |
Definition at line 600 of file XrdXrootdAio.cc.
References eDest, XrdSysError::Emsg(), XrdLink::ID, Link, and Recycle().
Referenced by endRead(), and endWrite().
void XrdXrootdAioReq::sendError | ( | char * | tident | ) | [private] |
Definition at line 619 of file XrdXrootdAio.cc.
References aioError, aioType, XrdSysError::ec2text(), eDest, XrdSysError::Emsg(), XrdSfsFile::FName(), XrdXrootdProtocol::mapError(), myFile, respDone, Response, XrdXrootdResponse::Send(), snprintf, and XrdXrootdFile::XrdSfsp.
Referenced by endRead(), and endWrite().
void XrdXrootdAioReq::UnLock | ( | void | ) | [inline, private] |
Definition at line 121 of file XrdXrootdAio.hh.
References aioMutex, isLocked, and XrdSysMutex::UnLock().
Referenced by XrdXrootdAio::doneWrite(), endRead(), getAio(), Recycle(), and Write().
friend class XrdXrootdAio [friend] |
Definition at line 82 of file XrdXrootdAio.hh.
const char * XrdXrootdAioReq::TraceID [static, private] |
Definition at line 123 of file XrdXrootdAio.hh.
XrdSysError * XrdXrootdAioReq::eDest [static, private] |
XrdSysMutex XrdXrootdAioReq::rqMutex [static, private] |
XrdXrootdAioReq * XrdXrootdAioReq::rqFirst [static, private] |
int XrdXrootdAioReq::QuantumMin [static, private] |
int XrdXrootdAioReq::Quantum [static, private] |
int XrdXrootdAioReq::QuantumMax [static, private] |
int XrdXrootdAioReq::maxAioPR [static, private] |
int XrdXrootdAioReq::maxAioPR2 [static, private] |
XrdSysMutex XrdXrootdAioReq::aioMutex [private] |
XrdXrootdAioReq* XrdXrootdAioReq::Next [private] |
Definition at line 134 of file XrdXrootdAio.hh.
Referenced by addBlock(), Alloc(), Clear(), and Recycle().
off_t XrdXrootdAioReq::myOffset [private] |
int XrdXrootdAioReq::myIOLen [private] |
Definition at line 137 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneWrite(), endRead(), and Read().
unsigned int XrdXrootdAioReq::Instance [private] |
XrdLink* XrdXrootdAioReq::Link [private] |
Definition at line 139 of file XrdXrootdAio.hh.
Referenced by XrdXrootdAio::Alloc(), Clear(), XrdXrootdAio::doneWrite(), endRead(), endWrite(), Recycle(), and Scuttle().
XrdXrootdFile* XrdXrootdAioReq::myFile [private] |
Definition at line 140 of file XrdXrootdAio.hh.
Referenced by Clear(), endRead(), endWrite(), Read(), sendError(), and Write().
XrdXrootdAio* XrdXrootdAioReq::aioDone [private] |
Definition at line 142 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneRead(), endRead(), Pop(), Push(), and Recycle().
XrdXrootdAio* XrdXrootdAioReq::aioFree [private] |
Definition at line 143 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneWrite(), endRead(), getAio(), Read(), and Recycle().
int XrdXrootdAioReq::numActive [private] |
Definition at line 144 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneWrite(), endRead(), Read(), Recycle(), and Write().
int XrdXrootdAioReq::aioTotal [private] |
Definition at line 145 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneRead(), XrdXrootdAio::doneWrite(), endRead(), and endWrite().
int XrdXrootdAioReq::aioError [private] |
Definition at line 146 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneRead(), XrdXrootdAio::doneWrite(), endRead(), endWrite(), Recycle(), and sendError().
char XrdXrootdAioReq::aioType [private] |
Definition at line 147 of file XrdXrootdAio.hh.
Referenced by Clear(), DoIt(), Recycle(), and sendError().
char XrdXrootdAioReq::respDone [private] |
Definition at line 148 of file XrdXrootdAio.hh.
Referenced by Clear(), endRead(), Recycle(), and sendError().
char XrdXrootdAioReq::isLocked [private] |
char XrdXrootdAioReq::reDrive [private] |
Definition at line 150 of file XrdXrootdAio.hh.
Referenced by Clear(), XrdXrootdAio::doneWrite(), and getAio().
XrdXrootdResponse XrdXrootdAioReq::Response [private] |
Definition at line 152 of file XrdXrootdAio.hh.
Referenced by endRead(), endWrite(), and sendError().