Re: NDIS 5.0 driver on Win98

Tech-Archive recommends: Fix windows errors by optimizing your registry



Ajay,

Two other things occured to me after I posted this below (and re-read your
OP for another pass at the details).

1. Make sure you have not somehow placed your send handler in 'paged' code.

2. Get the Win98 DDK / Debug Build & Symbols and run your driver on it
using the system debugger (see the Win98 DDK docs). The Debug Build of the
system components can tell you plenty about what is going on at that time.

Adding another VM (by opening a DOS box) places additional stress on memory
and may simply be paging out something that does not otherwise get paged out
when running without the DOS box active.

Good Luck,
Dave Cattley
Consulting Engineer
Systems Software Development

"Dave Cattley" wrote:

> Ajay,
>
> The reason it breaks when opening a DOS box is due to the extra layer of
> 'Virtual Machine' (VM) instantiation & scheduling that is present in Win9x.
> When a DOS box is created, a VM is created to 'virtualize' the machine and
> run MS-DOS. A Windows Console process is also created as well to display the
> virtual machine screen in a window. An NDIS driver is loaded into memory
> ultimately as a VxD. Most NDIS Miniport drivers can be blissfully ignorant
> of the subtlties of running in a VM context of other than the VM running
> 'Windows' (the system VM). It sounds like your driver cannot be so
> 'unaware'. For the most part, you can only call certain services while the
> VM scheduler context is the 'system VM' and not an arbitrary VM (like when
> the DOS VM is scheduled).
>
> Try queueing the request to your MiniportSend and scheduling a WORK_ITEM to
> process it later. A protocol may very well be making the NdisSend() call
> while running in the DOS VM (not an illegal thing to do) but if you, for
> instance, were to try and do some thing like submit an IRP to a WDM driver,
> complete an IRP pending in your driver, or some other thing, you could easily
> be calling into a system service that is assuming (and requiring) that the
> System VM be scheduled. Windows 98 includes support for NDIS Work Items and
> implements them as a 'restricted event' which (as I recall) ensures that the
> System VM is scheduled when the event callback occurs (as well as ensuring
> that the WDM subsystem can be called in general).
>
> Good Luck,
> Dave Cattley
> Consulting Engineer
> Systems Software Development
.



Relevant Pages

  • Re: NDIS 5.0 driver on Win98
    ... When a DOS box is created, a VM is created to 'virtualize' the machine and ... 'Windows'. ... It sounds like your driver cannot be so ... VM scheduler context is the 'system VM' and not an arbitrary VM (like when ...
    (microsoft.public.development.device.drivers)
  • Re: NDIS 5.0 driver on Win98
    ... Driver works fine otherwise but as ... > when running without the DOS box active. ... A Windows Console process is also created as well to display ... >> VM scheduler context is the 'system VM' and not an arbitrary VM (like ...
    (microsoft.public.development.device.drivers)
  • Re: To the Brotherhood of the Consoles (Warning contains Wibble)
    ... > yet all versions of windows and DOS do with the default drivers. ... Because I started out with one of those, and it needed dos to be booted to ... a disagreement between the device driver in X and the graphics card. ... Bet you have to use a driver CD provided by the manufacturers though, ...
    (comp.sys.sinclair)
  • Re: Printing a.gif from a Batch File
    ... Windows XP's "Command Window" is cmd.exe not command.com. ... It is also true that the most common language interpreted by printers is PCL ... a printer can have only one driver. ... BATch files use DOS instead, ...
    (microsoft.public.windowsxp.basics)
  • Re: dos functions behave differently under windows XP
    ... > But afaik many do still provide a bootimage with some flavour of DOS, ... companies have released windows flashers, ... For drivers for the hardware it would be a good idea I ... > these drivers must comply to the rules of the driver APIs defined. ...
    (comp.lang.asm.x86)