Hi,
I am working on USB driver.It also supports firmware upgrade feature.
I tried to read the status of my DFU device through deviceiocontrol
calls.
My driver works fine ,it gets loaded.After I run the application to get
the status it also reads the status from the device.I ran my
application for 5 to 6 times.nothing happened.After few minutes my
system gets crashed.
I get a blue screen error
stop:0x0000000a(0x00000004,0x00000002,0x00000000,0x804e97af).
It maps to IRQL_NOT_LESS_OR_EQUAL error code.
sometimes I get blue screen while running my application.some times I
get it later when the system is idle.ie, I even unloaded my driver,even
then my system gives the blue screen message.
msdn tells the below things for the stop error 0x0000000a.
Stop error 0x0000000A (Stop 0x0A) indicates that there was an attempt
in kernel mode to touch pageable memory at too high a process internal
request level (IRQL). Typically, this error occurs when a driver uses
an incorrect memory address. Other possible causes of this error are an
incompatible device driver, a general hardware problem, and
incompatible software
on seeing this I scanned my code.In my code I have allocated buffers
using ExAllocatePool fn.
from application I make this call
bResult =
DeviceIoControl(devicehandle,IOCTL_XXX,NULL,0,NULL,0,&nbytes,(LPOVERLAPPED)
NULL);
In driver dispatch routine:
case IOCTL_XXX:
ULONG *length;
PVOID data;
ULONG packetsize = 10;
length = &packetsize;
data =(PVOID) ExAllocatePool(NonPagedPool,10);
memset(data,0,packetsize);
myfunction(fdo, 0,
data,length);
ExFreePool(data);
break;
Is there any thing wrong in allocating like this.But then I even freed
the allocated pool at the end.
Is the error because of the allocation or something else.
help me out with this.I am new to windows device driver.
I am not able to figure out much from the stop message.
Thanks in advance
>> Stay informed about: stop error