- IORegistryEntry * next;
- IORegistryIterator * iter;
- OSOrderedSet * all;
- char format[] = "%xxxs";
- IOService * service;
-
- iter = IORegistryIterator::iterateOver( plane );
-
- all = iter->iterateAll();
- if( all) {
- dbugprintf("Count %d\n", all->getCount() );
- all->release();
- } else dbugprintf("Empty\n");
-
- iter->reset();
- while( (next = iter->getNextObjectRecursive())) {
- snprintf(format + 1, sizeof(format) - 1, "%ds", 2 * next->getDepth( plane ));
- dbugprintf( format, "");
- dbugprintf( "%s", next->getName( plane ));
- if( (next->getLocation( plane )))
- dbugprintf("@%s", next->getLocation( plane ));
- dbugprintf(" <class %s", next->getMetaClass()->getClassName());
- if( (service = OSDynamicCast(IOService, next)))
- dbugprintf(", busy %ld", service->getBusyState());
- dbugprintf( ">\n");
- }
- iter->release();