Loading...
Searching...
No Matches
XrdOssCsiFileAio Class Reference

`#include <XrdOssCsiFileAio.hh>`

Inheritance diagram for XrdOssCsiFileAio:
Collaboration diagram for XrdOssCsiFileAio:

## Public Member Functions

| XrdOssCsiFileAio (XrdOssCsiFileAioStore *store)
| ~XrdOssCsiFileAio ()
virtual void | doneRead ()
virtual void | doneWrite ()
void | Init (XrdSfsAio *aiop, XrdOssCsiFile *file, bool isPgOp, uint64_t opts, bool isread)
virtual void | Recycle ()
void | SchedReadJob ()
void | SchedReadJob2 ()
void | SchedWriteJob ()
void | SchedWriteJob2 ()
Public Member Functions inherited from XrdSfsAio
| XrdSfsAio ()
virtual | ~XrdSfsAio ()

## Static Public Member Functions

static XrdOssCsiFileAio * | Alloc (XrdOssCsiFileAioStore *store)

## Public Attributes

uint64_t | pgOpts_
XrdOssCsiRangeGuard | rg_
Public Attributes inherited from XrdSfsAio
uint32_t * | cksVec
ssize_t | Result
struct aiocb | sfsAio
const char * | TIdent

## Friends

class | XrdOssCsiFileAioStore

## Detailed Description

Definition at line 109 of file XrdOssCsiFileAio.hh.

## Constructor & Destructor Documentation

## XrdOssCsiFileAio()

XrdOssCsiFileAio::XrdOssCsiFileAio | ( | XrdOssCsiFileAioStore * | store | ) |

inline

Definition at line 205 of file XrdOssCsiFileAio.hh.

: store_(store) { }

References XrdOssCsiFileAioStore.

Referenced by Alloc().

Here is the call graph for this function:
Here is the caller graph for this function:

## ~XrdOssCsiFileAio()

XrdOssCsiFileAio::~XrdOssCsiFileAio | ( |  | ) |

inline

Definition at line 206 of file XrdOssCsiFileAio.hh.

{ }

## Member Function Documentation

## Alloc()

XrdOssCsiFileAio * XrdOssCsiFileAio::Alloc | ( | XrdOssCsiFileAioStore * | store | ) |

inline static

Definition at line 171 of file XrdOssCsiFileAio.hh.

{
XrdOssCsiFileAio *p=NULL;
if (store)
{
std::lock_guard<std::mutex> guard(store->mtx_);
if ((p = store->list_)) store->list_ = p->next_;
}
if (!p) p = new XrdOssCsiFileAio(store);
return p;
}
XrdOssCsiFileAioStore::list_
XrdOssCsiFileAio * list_
Definition XrdOssCsi.hh:53
XrdOssCsiFileAioStore::mtx_
std::mutex mtx_
Definition XrdOssCsi.hh:52
XrdOssCsiFileAio::XrdOssCsiFileAio
XrdOssCsiFileAio(XrdOssCsiFileAioStore *store)
Definition XrdOssCsiFileAio.hh:205

References XrdOssCsiFileAio(), XrdOssCsiFileAioStore::list_, XrdOssCsiFileAioStore::mtx_, and XrdOssCsiFileAioStore.

Referenced by XrdOssCsiFile::pgRead(), XrdOssCsiFile::pgWrite(), XrdOssCsiFile::Read(), and XrdOssCsiFile::Write().

Here is the call graph for this function:
Here is the caller graph for this function:

## doneRead()

virtual void XrdOssCsiFileAio::doneRead | ( |  | ) |

inline virtual

Implements XrdSfsAio.

Definition at line 117 of file XrdOssCsiFileAio.hh.

{
parentaio_->Result = this->Result;
// schedule the result check and verify/fetchrange
SchedReadJob2();
}
XrdOssCsiFileAio::SchedReadJob2
void SchedReadJob2()
Definition XrdOssCsiFileAio.hh:194
XrdSfsAio::Result
ssize_t Result
Definition XrdSfsAio.hh:65

References XrdSfsAio::Result, and SchedReadJob2().

Here is the call graph for this function:

## doneWrite()

virtual void XrdOssCsiFileAio::doneWrite | ( |  | ) |

inline virtual

Implements XrdSfsAio.

Definition at line 124 of file XrdOssCsiFileAio.hh.

{
parentaio_->Result = this->Result;
// schedule the result check and write any extra
SchedWriteJob2();
}
XrdOssCsiFileAio::SchedWriteJob2
void SchedWriteJob2()
Definition XrdOssCsiFileAio.hh:183

References XrdSfsAio::Result, and SchedWriteJob2().

Here is the call graph for this function:

## Init()

void XrdOssCsiFileAio::Init | ( | XrdSfsAio * | aiop,
|  | XrdOssCsiFile * | file,
|  | bool | isPgOp,
|  | uint64_t | opts,
|  | bool | isread )

inline

Definition at line 153 of file XrdOssCsiFileAio.hh.

{
parentaio_ = aiop;
this->sfsAio.aio_fildes = aiop->sfsAio.aio_fildes;
this->sfsAio.aio_buf = aiop->sfsAio.aio_buf;
this->sfsAio.aio_nbytes = aiop->sfsAio.aio_nbytes;
this->sfsAio.aio_offset = aiop->sfsAio.aio_offset;
this->sfsAio.aio_reqprio = aiop->sfsAio.aio_reqprio;
this->cksVec = aiop->cksVec;
this->TIdent = aiop->TIdent;
file_ = file;
isPgOp_ = isPgOp;
pgOpts_ = opts;
Sched_ = XrdOssCsi::Sched_;
job_.Init(file, this, aiop, isPgOp, isread);
file_->aioInc();
}
opts
struct myOpts opts
aiocb::aio_offset
off_t aio_offset
Definition XrdSfsAio.hh:49
aiocb::aio_nbytes
size_t aio_nbytes
Definition XrdSfsAio.hh:48
aiocb::aio_reqprio
int aio_reqprio
Definition XrdSfsAio.hh:50
aiocb::aio_fildes
int aio_fildes
Definition XrdSfsAio.hh:46
aiocb::aio_buf
void * aio_buf
Definition XrdSfsAio.hh:47
XrdOssCsiFileAio::pgOpts_
uint64_t pgOpts_
Definition XrdOssCsiFileAio.hh:115
XrdOssCsi::Sched_
static XrdScheduler * Sched_
Definition XrdOssCsi.hh:223
XrdSfsAio::cksVec
uint32_t * cksVec
Definition XrdSfsAio.hh:63
XrdSfsAio::TIdent
const char * TIdent
Definition XrdSfsAio.hh:67
XrdSfsAio::sfsAio
struct aiocb sfsAio
Definition XrdSfsAio.hh:62

References XrdSfsAio::XrdSfsAio(), aiocb::aio_buf, aiocb::aio_fildes, aiocb::aio_nbytes, aiocb::aio_offset, aiocb::aio_reqprio, XrdSfsAio::cksVec, opts, pgOpts_, XrdOssCsi::Sched_, XrdSfsAio::sfsAio, and XrdSfsAio::TIdent.

Referenced by XrdOssCsiFile::pgRead(), XrdOssCsiFile::pgWrite(), XrdOssCsiFile::Read(), and XrdOssCsiFile::Write().

Here is the call graph for this function:
Here is the caller graph for this function:

## Recycle()

virtual void XrdOssCsiFileAio::Recycle | ( |  | ) |

inline virtual

Implements XrdSfsAio.

Definition at line 131 of file XrdOssCsiFileAio.hh.

{
rg_.ReleaseAll();
parentaio_ = NULL;
XrdOssCsiFile *f = file_;
file_ = NULL;
if (store_)
{
std::lock_guard<std::mutex> guard(store_->mtx_);
next_ = store_->list_;
store_->list_ = this;
}
else
{
delete this;
}
if (f)
{
f->aioDec();
}
}
XrdOssCsiFileAio::rg_
XrdOssCsiRangeGuard rg_
Definition XrdOssCsiFileAio.hh:114
XrdOssCsiFile::aioDec
void aioDec()
Definition XrdOssCsi.hh:120

References XrdOssCsiFile::aioDec(), and rg_.

Here is the call graph for this function:

## SchedReadJob()

void XrdOssCsiFileAio::SchedReadJob | ( |  | ) |

inline

Definition at line 200 of file XrdOssCsiFileAio.hh.

{
Sched_->Schedule((XrdJob *)&job_);
}

Referenced by XrdOssCsiFile::pgRead(), and XrdOssCsiFile::Read().

Here is the caller graph for this function:

## SchedReadJob2()

void XrdOssCsiFileAio::SchedReadJob2 | ( |  | ) |

inline

Definition at line 194 of file XrdOssCsiFileAio.hh.

{
job_.PrepareRead2();
Sched_->Schedule((XrdJob *)&job_);
}

Referenced by doneRead().

Here is the caller graph for this function:

## SchedWriteJob()

void XrdOssCsiFileAio::SchedWriteJob | ( |  | ) |

inline

Definition at line 189 of file XrdOssCsiFileAio.hh.

{
Sched_->Schedule((XrdJob *)&job_);
}

Referenced by XrdOssCsiFile::pgWrite(), and XrdOssCsiFile::Write().

Here is the caller graph for this function:

## SchedWriteJob2()

void XrdOssCsiFileAio::SchedWriteJob2 | ( |  | ) |

inline

Definition at line 183 of file XrdOssCsiFileAio.hh.

{
job_.PrepareWrite2();
Sched_->Schedule((XrdJob *)&job_);
}

Referenced by doneWrite().

Here is the caller graph for this function:

## Friends And Related Symbol Documentation

## XrdOssCsiFileAioStore

friend class XrdOssCsiFileAioStore

friend

Definition at line 111 of file XrdOssCsiFileAio.hh.

References XrdOssCsiFileAioStore.

Referenced by XrdOssCsiFileAio(), Alloc(), and XrdOssCsiFileAioStore.

## Member Data Documentation

## pgOpts_

uint64_t XrdOssCsiFileAio::pgOpts_

Definition at line 115 of file XrdOssCsiFileAio.hh.

Referenced by Init().

## rg_

XrdOssCsiRangeGuard XrdOssCsiFileAio::rg_

Definition at line 114 of file XrdOssCsiFileAio.hh.

Referenced by Recycle().

The documentation for this class was generated from the following file:

- XrdOssCsiFileAio.hh