1

With KEXT it was possible to allocate needed class (i.e. IOUSBHostDevice) do init(), attach(), set needed properties and call registerService() of this object.

With DEXT we have got IOService::Create() method only which accepts property key name from Info.plist. So, it works well for IOUserClient and IOUserHIDDevice but not for USB.

So in DEXT, what is the general way to create arbitrary child objects?

Alex
  • 11
  • 2

1 Answers1

1

This isn't possible with dexts.

pmdj
  • 22,018
  • 3
  • 52
  • 103
  • @TomerShetah Saying something is not possible is still an answer. – Mark Rotteveel Jan 26 '21 at 11:34
  • @pmdj Thank you. I came to the same conclusion digging headers and Darwin sources. – Alex Jan 26 '21 at 11:43
  • @TomerShetah I wasn't able to inherit from IOUSBHostDevice like IOUserClient and IOUserHIDDevice. I was getting warnings like these: `warning: 'CopyDescriptor' overrides a member function but is not marked 'override' [-Winconsistent-missing-override, 2, Semantic Issue] ` and `Iig` errors. – Alex Jan 26 '21 at 11:47
  • @TomerShetah I'm not sure what you'd like me to expand on, really. There's no documentation for functionality that doesn't exist, so there's nothing to link to. `IOUSBHostDevice` simply isn't designed to be subclassed in DriverKit. – pmdj Mar 22 '21 at 12:13