Query on storport-miniport driver

Hi experts,
I have a stor-miniport driver managing a fiber channel adapter. If, at
some point after initialization, my hardware gets into a un-recoverable
error state (for example a firmware crash) is there a mechanism by which the
miniport can notify Storport of such a failure? Basically, I was looking for
a mechanism by which Storport would stop using the adapter which has faulted
and mark it as failed for the rest of the operating system.

Regards,
Girish.

One option may for you to tell storport that there has been a change “StorportNotification(BusChangeDetected…)” and when queried, indicate that all your devices have gone away…

–Mark Cariddi
OSR, Open Systems Resources, Inc.

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Girish Aithal
Sent: Tuesday, May 04, 2010 8:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Query on storport-miniport driver

Hi experts,
I have a stor-miniport driver managing a fiber channel adapter. If, at
some point after initialization, my hardware gets into a un-recoverable
error state (for example a firmware crash) is there a mechanism by which the
miniport can notify Storport of such a failure? Basically, I was looking for
a mechanism by which Storport would stop using the adapter which has faulted
and mark it as failed for the rest of the operating system.

Regards,
Girish.


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

Thanks Mark. My understanding is that StorportNotification with
BusChangeDetected is used to notify the arrival/removal of target devices
(in this case the FC targets and/or disk devices behind them). Even if the
miniport were to fail the subsequent commands on that adapter(such as Report
LUNs, Inquiry etc), the FC adapter will still be considered to be in a
working state, isnt it?

I was looking for a mechanism wherein the miniport notifies the Storport of
a problem with the FC adapter itself, leading to the adapter being marked as
failed.

Regards,
Girish.

“Mark Cariddi” wrote in message news:xxxxx@ntdev…
One option may for you to tell storport that there has been a change
“StorportNotification(BusChangeDetected…)” and when queried, indicate that
all your devices have gone away…

–Mark Cariddi
OSR, Open Systems Resources, Inc.

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Girish Aithal
Sent: Tuesday, May 04, 2010 8:58 AM
To: Windows System Software Devs Interest List
Subject: [ntdev] Query on storport-miniport driver

Hi experts,
I have a stor-miniport driver managing a fiber channel adapter. If, at
some point after initialization, my hardware gets into a un-recoverable
error state (for example a firmware crash) is there a mechanism by which the
miniport can notify Storport of such a failure? Basically, I was looking for
a mechanism by which Storport would stop using the adapter which has faulted
and mark it as failed for the rest of the operating system.

Regards,
Girish.


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

A WDM and probably a KDMF driver can report their device state has changed,
and then in the PnP state query that comes say they have failed. I don’t
know if there is any way to get this to happen to a storport miniport. You
might look at which PnP messages get passed into a miniport.

You certainly can try to write a message to the system event log. Really, if
your firmware crashed, you should try to get it restarted, and your target’s
back online, because if you’re controlling the system disk, you will not
even be able to write a log entry saying your adapter firmware crashed,
taking the system with it. System’s that just die quiet deaths with no data
about why are not much fun. Isn’t this what firmware watchdog timers are
for? Is the real question, can I stall the OS, and not loose I/O’s, while my
firmware reboots?

Jan

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:bounce-410284-
xxxxx@lists.osr.com] On Behalf Of Girish Aithal
Sent: Tuesday, May 04, 2010 7:36 PM
To: Windows System Software Devs Interest List
Subject: Re:[ntdev] Query on storport-miniport driver

Thanks Mark. My understanding is that StorportNotification with
BusChangeDetected is used to notify the arrival/removal of target
devices
(in this case the FC targets and/or disk devices behind them). Even if
the
miniport were to fail the subsequent commands on that adapter(such as
Report
LUNs, Inquiry etc), the FC adapter will still be considered to be in a
working state, isnt it?

I was looking for a mechanism wherein the miniport notifies the
Storport of
a problem with the FC adapter itself, leading to the adapter being
marked as
failed.

Regards,
Girish.

“Mark Cariddi” wrote in message news:xxxxx@ntdev…
> One option may for you to tell storport that there has been a change
> “StorportNotification(BusChangeDetected…)” and when queried, indicate
> that
> all your devices have gone away…
>
> --Mark Cariddi
> OSR, Open Systems Resources, Inc.
>
> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com] On Behalf Of Girish Aithal
> Sent: Tuesday, May 04, 2010 8:58 AM
> To: Windows System Software Devs Interest List
> Subject: [ntdev] Query on storport-miniport driver
>
> Hi experts,
> I have a stor-miniport driver managing a fiber channel adapter. If,
> at
> some point after initialization, my hardware gets into a un-recoverable
> error state (for example a firmware crash) is there a mechanism by
> which the
> miniport can notify Storport of such a failure? Basically, I was
> looking for
> a mechanism by which Storport would stop using the adapter which has
> faulted
> and mark it as failed for the rest of the operating system.
>
> Regards,
> Girish.
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer

I think that reset will be automatically sent by the port if some requests are pended by the miniport for a long time, i.e. the miniport/hardware/firmware is hang.


Maxim S. Shatskih
Windows DDK MVP
xxxxx@storagecraft.com
http://www.storagecraft.com

“Girish Aithal” wrote in message news:xxxxx@ntdev…
> Hi experts,
> I have a stor-miniport driver managing a fiber channel adapter. If, at
> some point after initialization, my hardware gets into a un-recoverable
> error state (for example a firmware crash) is there a mechanism by which the
> miniport can notify Storport of such a failure? Basically, I was looking for
> a mechanism by which Storport would stop using the adapter which has faulted
> and mark it as failed for the rest of the operating system.
>
> Regards,
> Girish.
>
>
>