hybernation problem in W2k

J

john

Here's the problem.
When my WDM driver is called to initialize the hardware due to a
IRP_MN_SET_POWER indicating power has been increased (I set the target
machine to hybernate mode), the memory map of the device I/O doesn't
look right. All registers read contain 0XFFFFFFFF. This is not
correct. When I test Standby mode, it work just find. One of the tasks
I need to perform when waking up from a hybernation is to reload the
device firmware.

Do I need to remap the I/O memory space. At one time, I thought this
was working.

John
 
J

john

I didn't think I had to remap I/O memory space. In fact, I thought I
had this working before, I had to go and work on something else.

I'm new to power management. So by D0, do you mean power down. If
that's the case, I am handle the D0 irp. During Hybernation, I don't
really have to do anything. However, when power is restored, I have to
reload the adapter's firmware and reconfigure the adaptor to it's
original state prior to hybernation. This is where I'm having
problems. I'm reading all F's in the hardware registers. Most of the
register should be zero.


John
 
D

Doron Holan [MS]

D0 is power up. For a power up irp, you need to send it down the stack and
then wait for it to complete back to your driver. this allows the
underlying bus to generically opwer on your device.

I highly suggest you look at KMDF and rewrite your driver using it. You will
get a fully and properly implemented power state machine which takes care of
this for you.

d
 
J

john

I do sent it down the stack and wait for it to complete.

The computer I was using contained System Commander. When I tried
hybernation mode on a system not useing System command, hybernation
worked just find. I tried it again on another computer that boots up
with W2K, not using System Commander, an my driver came up with no
problems.

The computer using System Commander also has Windows XP. I'm going to
try to Hybernation and see if I get the same problem.

I cannot use KMDF. The WDM driver was designed to fit with other
Operating Systems. We call it the Common Driver Design. Since most of
the code is common code between Operating Sytem and the Hardware
module of the driver are basically the same between Operating System,
we just need to write the OS specific functions that are required for
that OS (Unix,linus, and others).. This design works out pretty good.
Now it only takes us a few days to write the code (OS specific
functions). The common code and hardware code has already be debugged
by Windows NT.


John
 
D

Doron Holan [MS]

with the way you designed it so that OS stuff is abstracted out, a KMDF
should be rather quick.

d
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top