StorportGetUncachedExtension Fails to Allocate Memory

Chirag Chinmay 1 Reputation point
2021-08-11T15:35:45.387+00:00

I am working on a storport-miniport driver.
I need to allocate approximately 132KB of memory via StorportGetUncachedExtension in my FindAdapter Function.

I have 32 devices connected to a Windows 10 x64 System. 32 driver instances try to load and memory allocation is successful for 15-18 devices. After that for the rest devices, StorportGetUncachedExtension returns NULL.

However if I reduce the size to 4KB, the StorportGetUncachedExtension results in successive allocation for all devices. But, after 15-18 devices, rest devices show a yellow bang in device manager with the error code as " The device Cannot Start (Code 10). { Not enough Quota } Not enough virtual memory or paging file quota is available to complete the specified operation ".
From further debugging i can see that HWInitialize function is successful but immediately Storport is calling AdapterControl function with controlType as SCSIStopAdapter.

System Memory Statistics:
Total RAM - 32GB RAM
In Use - 4GB
Available Memory - 25.8GB
Virtual Memory Paging Size - 16GB

Device:
Only BAR 0 is exposed. BAR Size is 32KB.

I request help in understanding what might be the issue.

Windows Hardware Performance
Windows Hardware Performance
Windows: A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.Hardware Performance: Delivering / providing hardware or hardware systems or adjusting / adapting hardware or hardware systems.
1,541 questions
0 comments No comments
{count} votes