ioregistryentry :: frompath()fail
-
22-09-2019 - |
質問
私のiokit kextは失敗しています 古いiMacsで ioregistryのdevicetree平面内の /optionsパスを見つける。他の誰かがこれに遭遇したか、なぜそれが失敗するのか知っていますか? thx-> adv
IORegistryEntry* regEntry = IORegistryEntry::fromPath("/options", gIODTPlane);
if(NULL == regEntry)
{
regEntry = IORegistryEntry::fromPath("IODeviceTree:/options");
if(NULL == regEntry)
{
DEBUG_LOG("getIORegOptionsEntry: FAILURE TO LOCATE: IODeviceTree:/options\n");
}
}
解決
The path used to create IORegistryEntry is invalid as per the API: it should begins with a ':'. The I/O plane should not be included in the path, but as the second parameter.
所属していません StackOverflow