Timeout in SCSI_REQUEST_BLOCK

Is there a way for the Storport Miniport driver,

To get a larger timeout value in the SRB
or
Complete the SRB even after the timeout, without leading to LUN reset?

The disk class timeout in registry, increases the timeout for all disk class devices. I want to increase the timeout only for the devices exported by this storport miniport driver.

Thanks in Advance,
Nirranjan

Hi Nirranjan,

I came across your post and am facing a similar problem right now that I want to increase the BusyRetryCount of my specific virtual Storport HBA only for attached disks. I seem have identified the correct registry values under HKLM/SYSTEM/CurrentControlSet/SCSI///Device Parameters/Storport, where if I understand correctly also the SRB default timeout values reside.

Have you found a way to set these values programatically from your Storport Miniport driver ?

Have you found a way to set these values programatically

Change the registry value? Programmatically? Or during install?

Peter

Hi Peter,

My understanding is that the registry key HKLM/System/CurrentControlSet/SCSI/DeviceID/Instance/DeviceParameters/Storport
is created during mount and attachment of the Disk to the to the SCSI Adapter. Since the underlying disk driver is out of my control, I think I have to do this programatically unless I can configure disks attaching to my SCSI adapter.

Do you know of any way?

Best wishes
Bjoern

Don’t you guys want IoTimeoutValue … which is in the services key? I assume you saw this page?

Peter

Hey Peter,

Yes, I know this page very well. The IoTimeoutValue can be set or modified e.g. with the DDInstall.Services section in the INF file, which is, what the original post was asking about nine years ago.

If you scroll on the MSDN page further down you find the BusyRetryCount value I am interested in.

I tried IoOpenDeviceRegistryKey with the Physical Device Object of the SCSI Adapter Miniport or StorPortRegistryWriteAdapterKey with the device Extension and the DDInstall.HW section in the INF file, but of course only modify the corresponding values of the SCSIAdapter and not the ones of the attached disks in the SCSI registry key.

Maybe there is a very simple solution and I am just to blind to see it.

Best wishes
Bjoern

So… The only way I can think of to do this, not having done it myself, is you need to build the registry path yourself… And the names of the keys are parts of the Device Instance ID.

IIRC, the “right” way to do this is using IoGetDevicePropertyData and query for the Device Property you want… which would be DEVPKEY_Device_InstanceId. I think.

Sorry to take so long to get here… Does that help at all??

Peter


My basic problem in this thread is that I’ve been having trouble understanding what your question is. Maybe I’ve been reading too fast… Heck, I didn’t even NOTICE that this was a necropost!

Dear Peter,

Thank you for your effort answering my question. It is highly appreciated.
Yes, it seems like I will go back to my version where I constructed the registry key my self. I was worried that MSDN says that these keys should never be modified directly, so I was looking for the correct function calls for doing the task the “right” way.
In my opinion the right way would be to start from the HBA device node and go up (???) the device stack until you derive at the correct SCSI disk and then access this devices registry keys.

I also tried the other way, starting with the volume device and moving down the stack to find the HBA and hopefully the correct SCSI device in between. However, this rewarded me with a bluescreen concerning memory mapping if I am not mistaken. So I did not follow this approach further. I guess my knowledge regarding moving in the device stack is still not existing :wink:

Nevertheless, I think I have a working solution know. Again, thank you very much for your time and effort.

Necropost closed. :wink: