- if (doit) {
- IOTimeStampConstant(IODBG_TIMES(IOTIMES_ACTION),
- (unsigned int) doit, (unsigned int) me->owner);
- me->closeGate();
- (*doit)(me->owner, me);
- me->openGate();
+void IOTimerEventSource::timeoutAndRelease(void * self, void * count)
+{
+ IOTimerEventSource *me = (IOTimerEventSource *) self;
+
+ if (me->enabled && me->action)
+ {
+ IOWorkLoop *
+ wl = me->reserved->workLoop;
+ if (wl)
+ {
+ Action doit;
+ wl->closeGate();
+ doit = (Action) me->action;
+ if (doit && (me->reserved->calloutGeneration == (SInt32) count))
+ {
+ IOTimeStampConstant(IODBG_TIMES(IOTIMES_ACTION),
+ (unsigned int) doit, (unsigned int) me->owner);
+ (*doit)(me->owner, me);
+ }
+ wl->openGate();