Another DDK toaster driver question

Hello,
I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??
Thanks and regards, Vasili N Galchin


Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now

You can’t. Toaster provides an example of a virtual bus driver (i.e. there is no physical bus). I currently am using it’s architecture as a model for my device driver which provides Serial communications over a network attachment, using either MAC or TCP/IP modes of addressing the device.

Toaster provided a fine example because unlike PCI or USB, TCP/IP has neither any requirements for devices attached to the network to announce themselves nor for a system utilizing the protocol to recognize and support Plug and Play drivers for devices newly attached to the network. So, the onus is upon the user to define to what devices a virtual bus driver like toaster should be communicating with. You of course could use the command line example of Toaster, or you could do as I have done and implement Add/New Hardware Wizard post processing pages to be displayed in order to collect necessary information for adding a new device to the virtual bus when the bus is first installed into the system. I have also provided Device Manager property page support for adding and removing devices from a virtual bus once it has been supported.

The rational for me investing the effort to provide a more graphical interface for adding and removing devices is that the command line method utilized by the Toaster sample would not be user friendly for our customer base.

Keep in mind WDM is a model which defines how a driver interacts with Plug and Play manager, Power Management manager, Windows Management Instrumentation manager, Device Manager, and other such aspects of the system. It explains various states or processing, when, how, and why of transitions between states, various queries which need to be supported, how and where those queries are responded to, and an overall layered driver architecture.

“Galchin Vasili” wrote in message news:xxxxx@ntdev…
Hello,

I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??

Thanks and regards, Vasili N Galchin

So can I use the ROOT bus driver to load a driver for a non PnP device? If so, where can I find out more about the ROOT bus driver? (There isn’t much in the DDK).
Regards, Vasili
Del Fredricks wrote:You can’t. Toaster provides an example of a virtual bus driver (i.e. there is no physical bus). I currently am using it’s architecture as a model for my device driver which provides Serial communications over a network attachment, using either MAC or TCP/IP modes of addressing the device. Toaster provided a fine example because unlike PCI or USB, TCP/IP has neither any requirements for devices attached to the network to announce themselves nor for a system utilizing the protocol to recognize and support Plug and Play drivers for devices newly attached to the network. So, the onus is upon the user to define to what devices a virtual bus driver like toaster should be communicating with. You of course could use the command line example of Toaster, or you could do as I have done and implement Add/New Hardware Wizard post processing pages to be displayed in order to collect necessary information for adding a new device to the virtual bus when the bus isfirst installed into the system. I have also provided Device Manager property page support for adding and removing devices from a virtual bus once it has been supported. The rational for me investing the effort to provide a more graphical interface for adding and removing devices is that the command line method utilized by the Toaster sample would not be user friendly for our customer base. Keep in mind WDM is a model which defines how a driver interacts with Plug and Play manager, Power Management manager, Windows Management Instrumentation manager, Device Manager, and other such aspects of the system. It explains various states or processing, when, how, and why of transitions between states, various queries which need to be supported, how and where those queries are responded to, and an overall layered driver architecture. “Galchin Vasili” wrote in message news:xxxxx@ntdev…
Hello,
I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??
Thanks and regards, Vasili N Galchin

You are currently subscribed to ntdev as: xxxxx@yahoo.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

---------------------------------
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now

In fact, WDM/PnP definitely lacks the ability of creating a non-persistent devnode with given data entries and starting the device off it. For instance, by a command-line tool.

Also IoReportDetectedDevice stuff seems to be a bit strange. The better solution would be:

  • yet another callback of “FindLegacyDevices” after AddDevice
  • at first pass, the PnP drivers are loaded to satisfy stack building needs for enumerated devices
  • then the SC database is consulted, and rest of PnP drivers are loaded.
  • then “FindLegacyDevices” is called for each driver, it must fail if the PnP device have already claimed the addresses of the legacy one (like PCI IDE - enumerated as PCI child, so, FindLegacyDevices path of the IDE driver will fail).
  • FindLegacyDevices just reports the resource descriptors from the values hardcoded to the driver (like 0x60 for 8042 driver). The devnode is then created, and started by usual PnP way.

Surely this is just a suggestion with nearly zero chances for being implemented, but seems to be a good one.

Max

“Del Fredricks” wrote in message news:LYRIS-542-92551-2003.01.13-11.14.26–maxim#xxxxx@lists.osr.com…
You can’t. Toaster provides an example of a virtual bus driver (i.e. there is no physical bus). I currently am using it’s architecture as a model for my device driver which provides Serial communications over a network attachment, using either MAC or TCP/IP modes of addressing the device.

Toaster provided a fine example because unlike PCI or USB, TCP/IP has neither any requirements for devices attached to the network to announce themselves nor for a system utilizing the protocol to recognize and support Plug and Play drivers for devices newly attached to the network. So, the onus is upon the user to define to what devices a virtual bus driver like toaster should be communicating with. You of course could use the command line example of Toaster, or you could do as I have done and implement Add/New Hardware Wizard post processing pages to be displayed in order to collect necessary information for adding a new device to the virtual bus when the bus is first installed into the system. I have also provided Device Manager property page support for adding and removing devices from a virtual bus once it has been supported.

The rational for me investing the effort to provide a more graphical interface for adding and removing devices is that the command line method utilized by the Toaster sample would not be user friendly for our customer base.

Keep in mind WDM is a model which defines how a driver interacts with Plug and Play manager, Power Management manager, Windows Management Instrumentation manager, Device Manager, and other such aspects of the system. It explains various states or processing, when, how, and why of transitions between states, various queries which need to be supported, how and where those queries are responded to, and an overall layered driver architecture.

“Galchin Vasili” wrote in message news:xxxxx@ntdev…
Hello,

I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??

Thanks and regards, Vasili N Galchin


You are currently subscribed to ntdev as: xxxxx@storagecraft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

Yes you can, and your INF must have a LogConfig section.

----- Original Message -----
From: Galchin Vasili
To: NT Developers Interest List
Sent: Tuesday, January 14, 2003 2:51 AM
Subject: [ntdev] Re: Another DDK toaster driver question

So can I use the ROOT bus driver to load a driver for a non PnP device? If so, where can I find out more about the ROOT bus driver? (There isn’t much in the DDK).

Regards, Vasili

Del Fredricks wrote:

You can’t. Toaster provides an example of a virtual bus driver (i.e. there is no physical bus). I currently am using it’s architecture as a model for my device driver which provides Serial communications over a network attachment, using either MAC or TCP/IP modes of addressing the device.

Toaster provided a fine example because unlike PCI or USB, TCP/IP has neither any requirements for devices attached to the network to announce themselves nor for a system utilizing the protocol to recognize and support Plug and Play drivers for devices newly attached to the network. So, the onus is upon the user to define to what devices a virtual bus driver like toaster should be communicating with. You of course could use the command line example of Toaster, or you could do as I have done and implement Add/New Hardware Wizard post processing pages to be displayed in order to collect necessary information for adding a new device to the virtual bus when the bus is first installed into the system. I have also provided Device Manager property page support for adding and removing devices from a virtual bus once it has been supported.

The rational for me investing the effort to provide a more graphical interface for adding and removing devices is that the command line method utilized by the Toaster sample would not be user friendly for our customer base.

Keep in mind WDM is a model which defines how a driver interacts with Plug and Play manager, Power Management manager, Windows Management Instrumentation manager, Device Manager, and other such aspects of the system. It explains various states or processing, when, how, and why of transitions between states, various queries which need to be supported, how and where those queries are responded to, and an overall layered driver architecture.

“Galchin Vasili” wrote in message news:xxxxx@ntdev…
Hello,

I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??

Thanks and regards, Vasili N Galchin


You are currently subscribed to ntdev as: xxxxx@yahoo.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

------------------------------------------------------------------------------
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now — You are currently subscribed to ntdev as: xxxxx@storagecraft.com To unsubscribe send a blank email to xxxxx@lists.osr.com

Hi,
This is another question on ddk toaster.
The toaster doc says first to install the toaster bus driver. Then run enum to add toaster devices. For me, when i run enum first time, it asks me to install the toaster deivce.
Is this the way the sample will work?.
If there is no need to install the toaster once before calling enum, why I am getting into installing toaster device separately
-Kas
Galchin Vasili wrote:
So can I use the ROOT bus driver to load a driver for a non PnP device? If so, where can I find out more about the ROOT bus driver? (There isn’t much in the DDK).
Regards, Vasili
Del Fredricks wrote: You can’t. Toaster provides an example of a virtual bus driver (i.e. there is no physical bus). I currently am using it’s architecture as a model for my device driver which provides Serial communications over a network attachment, using either MAC or TCP/IP modes of addressing the device. Toaster provided a fine example because unlike PCI or USB, TCP/IP has neither any requirements for devices attached to the network to announce themselves nor for a system utilizing the protocol to recognize and support Plug and Play drivers for devices newly attached to the network. So, the onus is upon the user to define to what devices a virtual bus driver like toaster should be communicating with. You of course could use the command line example of Toaster, or you could do as I have done and implement Add/New Hardware Wizard post processing pages to be displayed in order to collect necessary information for adding a new device to the virtual bus when the bus i first installed into the system. I have also provided Device Manager property page support for adding and removing devices from a virtual bus once it has been supported. The rational for me investing the effort to provide a more graphical interface for adding and removing devices is that the command line method utilized by the Toaster sample would not be user friendly for our customer base. Keep in mind WDM is a model which defines how a driver interacts with Plug and Play manager, Power Management manager, Windows Management Instrumentation manager, Device Manager, and other such aspects of the system. It explains various states or processing, when, how, and why of transitions between states, various queries which need to be supported, how and where those queries are responded to, and an overall layered driver architecture. “Galchin Vasili” wrote in message news:xxxxx@ntdev…
Hello,
I successfully got the DDK toaster func driver (ntddk\src\general\toaster) to build. I also got it to successfully be loaded by the the toaster bus driver by running the utility Enum. How can I can the toaster func driver to load without human intervention as a WDM driver is intended to do, i.e. don’t run Enum by hand??
Thanks and regards, Vasili N Galchin

You are currently subscribed to ntdev as: xxxxx@yahoo.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

---------------------------------
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now — You are currently subscribed to ntdev as: xxxxx@yahoo.com To unsubscribe send a blank email to xxxxx@lists.osr.com

---------------------------------
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now

Look at the bus subdirectory for the toaster sample. It does not support loading drivers without first receiving an IOCTL_BUSENUM_PLUGIN_HARDWARE call from the enum program. It also does not provide for persistent device installation (i.e. retention between boot cycles). But, it can be achieved if you properly utilize the Registry

Don’t waste time in DDK as I have found that this driver architecture is not described there. There was talk at last years WinHEC to provide a bus driver model instead of having to implement a full blown WDM supported driver when only a fraction of the WDM functionality has any meaning. But as I understood it, that change would be several years out.
“Galchin Vasili” wrote in message news:xxxxx@ntdev…
So can I use the ROOT bus driver to load a driver for a non PnP device? If so, where can I find out more about the ROOT bus driver? (There isn’t much in the DDK).

Regards, Vasili

The toaster bus must be installed as it must receive the IOCTL_BUSENUM_PLUGIN_HARDWARE call from the num program. Keep in mind the enum program is a user mode application which simply provides a means of adding and removing devices from the system. But it is the bus driver which ultimately interfaces with the PnP manager to get the device driver for the toaster device up and running in the system.

This is accomplished by having the bus driver issuing an invalidate bus relations call to PnP, which results in PnP calling back to the bus driver to determine what new hardware is present. Like the PCI bus driver, the toaster bus driver manages the PDO calls for the child devices and with proper responses to the PnP bus queries passes the PDO’s to PnP. PnP will then issue the driverentry and adddevice calls to the toaster driver which results in new FDO’s being created for each child device being enumerated in the system.
“kas s” wrote in message news:xxxxx@ntdev…
Hi,

This is another question on ddk toaster.

The toaster doc says first to install the toaster bus driver. Then run enum to add toaster devices. For me, when i run enum first time, it asks me to install the toaster deivce.

Is this the way the sample will work?.

If there is no need to install the toaster once before calling enum, why I am getting into installing toaster device separately

-Kas