AioSignalScheduler.cpp File Reference

Go to the source code of this file.

Classes

class  AioSignalHandlerThread

Functions

 FENNEL_BEGIN_CPPFILE ("$Id: //open/dev/fennel/device/AioSignalScheduler.cpp#11 $")
static void aio_handler (int, siginfo_t *pSiginfo, void *)
 FENNEL_END_CPPFILE ("$Id: //open/dev/fennel/device/AioSignalScheduler.cpp#11 $")


Function Documentation

static void aio_handler ( int  ,
siginfo_t *  pSiginfo,
void *   
) [static]

Definition at line 49 of file AioSignalScheduler.cpp.

References RandomAccessRequestBinding::notifyTransferCompletion().

Referenced by AioSignalScheduler::AioSignalScheduler().

00050 {
00051     assert(pSiginfo->si_code == SI_ASYNCIO);
00052     RandomAccessRequestBinding *pBinding =
00053         static_cast<RandomAccessRequestBinding *>(pSiginfo->si_value.sival_ptr);
00054 
00055     // static_cast assigned to lpBinding is a workaround
00056     // for a gcc bug that shows up on Ubuntu 8.04 when
00057     // passing pBinding to aio_* methods
00058     aiocb *lpBinding = static_cast<aiocb *>(pBinding);
00059 
00060     int rc = aio_error(lpBinding);
00061     if (rc != EINPROGRESS) {
00062         rc = aio_return(lpBinding);
00063         pBinding->notifyTransferCompletion(rc >= 0);
00064     }
00065     // TODO:  chain?
00066 }

FENNEL_BEGIN_CPPFILE ( "$Id: //open/dev/fennel/device/AioSignalScheduler.cpp#11 $"   ) 

FENNEL_END_CPPFILE ( "$Id: //open/dev/fennel/device/AioSignalScheduler.cpp#11 $"   ) 


Generated on Mon Jun 22 04:00:22 2009 for Fennel by  doxygen 1.5.1