Hi,
I am trying to develop a SDIO device driver using Evc++.
The target device is an imate PPC. I am not using platform builder, as
i am not to use a development board, but just write a driver for the
PPC device which has an OS already.
My device has an SDBusdriver.dll
So i am thinking that i should develop a host controller driver and a
client driver.
Initially i am doing an SD card Client Driver and will try to modify it
from there.( Dont know if this is a good way to proceed)
I am currently modifying the registry in the
HKLM/Drivers/...../SDMemory_Class to replace the existing sdmemory.dll
client driver with my own SD card driver called MySD.dll.
I encountered the following problem in my driver code.
in the xxx_init, i have called the SDGetDeviceHandle(param1,param2)
API.
I get the HKLM/...../SDMemory_Class path in the param2 variable and got
a value for the handle returned by the API.
I used the Remote tools from EVC++ and in remote registry editor i
checked the active list of drivers. It showed one subkey as 'Hnd' and
onemore subkey as 'ClientInfo'. The handle value got from the API is
the same as the value in ClientInfo and not the one in Hnd.I expected
the value to be the one in 'Hnd' and not the one in 'ClientInfo'.
Is this a problem? if so how to correct it?
Next, i called the SDRegisterClient(...) API with the handle returned
by the SDGetDeviceHandle API as one of the parameters to
SDRegisterClient.
But this is causing an error, and the error code is 0xC0000006. I
understand that this status implies an INVALID HANDLE.
However, since the SDGetDeviceHandle API returned me the correct
registry path, i think the handle must also be correct. I cant
understand why the handle is invalid.
I hope someone can help me out on this one.
Thanks,
Nag