IOUSBControllerListElement.cpp [plain text]
#include <IOKit/usb/IOUSBControllerListElement.h>
#include <IOKit/usb/IOUSBLog.h>
#define IOUSBCONTROLLERLISTELEMENT_USE_KPRINTF 0
#if IOUSBCONTROLLERLISTELEMENT_USE_KPRINTF
#undef USBLog
#undef USBError
void kprintf(const char *format, ...)
__attribute__((format(printf, 1, 2)));
#define USBLog( LEVEL, FORMAT, ARGS... ) if ((LEVEL) <= IOUSBCONTROLLERLISTELEMENT_USE_KPRINTF) { kprintf( FORMAT "\n", ## ARGS ) ; }
#define USBError( LEVEL, FORMAT, ARGS... ) { kprintf( FORMAT "\n", ## ARGS ) ; }
#endif
#define super OSObject
OSDefineMetaClass( IOUSBControllerListElement, OSObject )
OSDefineAbstractStructors(IOUSBControllerListElement, OSObject)
void
IOUSBControllerListElement::print(int level)
{
#pragma unused (level)
USBLog(level, "IOUSBControllerListElement[%p]::print - _sharedPhysical[%p]", this, (void *)_sharedPhysical);
USBLog(level, "IOUSBControllerListElement::print - _sharedLogical[%p]", _sharedLogical);
USBLog(level, "IOUSBControllerListElement::print - _logicalNext[%p]", _logicalNext);
}
#undef super
#define super IOUSBControllerListElement
OSDefineMetaClass( IOUSBControllerIsochListElement, IOUSBControllerListElement )
OSDefineAbstractStructors( IOUSBControllerIsochListElement, IOUSBControllerListElement )
void
IOUSBControllerIsochListElement::print(int level)
{
super::print(level);
USBLog(level, "IOUSBControllerIsochListElement::print - _pEndpoint[%p]", _pEndpoint);
USBLog(level, "IOUSBControllerIsochListElement::print - _pFrames[%p]", _pFrames);
USBLog(level, "IOUSBControllerIsochListElement::print - completion[%p, %p, %p]", _completion.action, _completion.target, _completion.parameter);
USBLog(level, "IOUSBControllerIsochListElement::print - _lowLatency[%s]", _lowLatency ? "true" : "false");
USBLog(level, "IOUSBControllerIsochListElement::print - frameNumber[%Ld]", _frameNumber);
USBLog(level, "IOUSBControllerIsochListElement::print - frameIndex[%d]", (uint32_t)_frameIndex);
}
#undef super
#define super OSObject
OSDefineMetaClassAndStructors(IOUSBControllerIsochEndpoint, OSObject)
bool
IOUSBControllerIsochEndpoint::init()
{
toDoList = toDoEnd = NULL;
doneQueue = doneEnd = NULL;
deferredQueue = deferredEnd = NULL;
firstAvailableFrame = 0;
maxPacketSize = 0;
inSlot = 0;
activeTDs = 0;
onToDoList = 0;
onDoneQueue = 0;
scheduledTDs = 0;
deferredTDs = 0;
onProducerQ = 0;
onReversedList = 0;
inSlot = 0;
functionAddress = 0;
endpointNumber = 0;
accumulatedStatus = kIOReturnSuccess;
interval = 0;
direction = 0;
aborting = false;
return true;
}