Usenet comp.sys.dec (1990-2013)
 help / color / mirror / Atom feed
* Driver Question
@ 1993-03-24  1:58 cts
  1993-03-24 23:23 ` David L. Cathey
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: cts @ 1993-03-24  1:58 UTC (permalink / raw)


I have a system where a real time application drives custom hardware via
a DRV11-W and a custom driver.

One of the requirements of the system is that the hardware on the other
end of the DRV11-W see an output several times a second to remain online.
Right now, we're using a process to send out this "idle" message;  however,
some of the other tasks that need to execute at a high priority (realtime,
remember) sometimes prevent the idle task from doing its thing.  
Setting the idle task to a higher priority is not desirable;  the 
question has been asked - could this idle function be incorporated at
the driver in such a fashion that the driver would handle the idle
message without being delayed by the other processing on the system.

One method suggested casually was capturing the IRP of an idle message,
and continually queueing it up over and over again.  I'm uncomfortable
with this approach.  Any ideas or suggestions from the net?

--
Charles T. Smith, Jr.                         | "Beam me up, Scotty, there's no 
VMS & Network Consulting                      |  intelligent life down here..."
cts@dragon.com                                |
{gatech,emory}!dragon!cts                     |



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Driver Question
  1993-03-24  1:58 Driver Question cts
@ 1993-03-24 23:23 ` David L. Cathey
  1993-03-25 18:32 ` Bob Koehler
  1993-03-27  2:24 ` jeh
  2 siblings, 0 replies; 5+ messages in thread
From: David L. Cathey @ 1993-03-24 23:23 UTC (permalink / raw)


In article <1993Mar23.205833.1057@dragon.com>, cts@dragon.com writes:
> I have a system where a real time application drives custom hardware via
> a DRV11-W and a custom driver.
> 
> One of the requirements of the system is that the hardware on the other
> end of the DRV11-W see an output several times a second to remain online.
>
> One method suggested casually was capturing the IRP of an idle message,
> and continually queueing it up over and over again.  I'm uncomfortable
> with this approach.  Any ideas or suggestions from the net?

	DECnet does something like this with "hello" messages already :-)

> Charles T. Smith, Jr.                         | "Beam me up, Scotty, there's no 
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 
David L. Cathey		                |INET: davidc@montagar.com
Montagar Software Concepts              |UUCP: ...!montagar!davidc
P. O. Box 260772, Plano TX  75026-0772  |Fone: (214)-618-2117


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Driver Question
  1993-03-24  1:58 Driver Question cts
  1993-03-24 23:23 ` David L. Cathey
@ 1993-03-25 18:32 ` Bob Koehler
  1993-03-29 13:02   ` Paul Repacholi
  1993-03-27  2:24 ` jeh
  2 siblings, 1 reply; 5+ messages in thread
From: Bob Koehler @ 1993-03-25 18:32 UTC (permalink / raw)


In article <1993Mar23.205833.1057@dragon.com>, cts@dragon.com writes...
>I have a system where a real time application drives custom hardware via
>a DRV11-W and a custom driver.
> 
>One of the requirements of the system is that the hardware on the other
>end of the DRV11-W see an output several times a second to remain online.
>Right now, we're using a process to send out this "idle" message;  however,
>some of the other tasks that need to execute at a high priority (realtime,
>remember) sometimes prevent the idle task from doing its thing.  
>Setting the idle task to a higher priority is not desirable;  the 
>question has been asked - could this idle function be incorporated at
>the driver in such a fashion that the driver would handle the idle
>message without being delayed by the other processing on the system.
> 
>One method suggested casually was capturing the IRP of an idle message,
>and continually queueing it up over and over again.  I'm uncomfortable
>with this approach.  Any ideas or suggestions from the net?
> 
>--
>Charles T. Smith, Jr.                         | "Beam me up, Scotty, there's no 
>VMS & Network Consulting                      |  intelligent life down here..."
>cts@dragon.com                                |
>{gatech,emory}!dragon!cts                     |
> 

1) Any reason it can't be done in an AST in the "other tasks"?

2) If you have to do it in the driver, you're on the right track.  Study how to
do the timing a good bit though, most of the easy timing available to device
drivers involes either a busy loop, or a ganularity of not better than 1 second
or 2.  Maybe take a look at Hanrahan and Leahy's "VMS Advanced Device Driver 
Techniques" (start around section 2.6) if you can get a copy (Professional
Press).

------------------------------------------------------------------------------
Bob Koehler                     |   Any illusion to these opinions being other
rkoehler@author.gsfc.nasa.gov   |   than just mine alone is just that.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Driver Question
  1993-03-24  1:58 Driver Question cts
  1993-03-24 23:23 ` David L. Cathey
  1993-03-25 18:32 ` Bob Koehler
@ 1993-03-27  2:24 ` jeh
  2 siblings, 0 replies; 5+ messages in thread
From: jeh @ 1993-03-27  2:24 UTC (permalink / raw)


In article <1993Mar23.205833.1057@dragon.com>, cts@dragon.com writes:
>the 
>question has been asked - could this idle function be incorporated at
>the driver in such a fashion that the driver would handle the idle
>message without being delayed by the other processing on the system.

(I answered this via mail a day or two ago, but forgot to post the reply)

Certainly.  Instead of having the process issue a QIO to send each idle message,
have it do a QIO which causes the driver to start sending idle messages.  
If you want to get fancy a Pn parameter on the QIO could specify the delay. 
Just set up a repeating TQE to cause a routine in the driver to get 
called repeatedly.  When the TQE fires it can pass itself to the driver's
start I/O routine (or queue to the IRP wait queue if the driver is busy). 

You don't even need to allocate a TQE from pool - just make it part of the
UCB extension. 

When the "idle daemon" process goes away, the driver's cancel entry point will
get called, and this can be the signal to stop issuing the messages. 

Most of the details on using TQEs from drivers are in [shameless plug follows!]
Lee's and my book on VMS driver techniques. 

	--- Jamie Hanrahan, Kernel Mode Systems, San Diego CA
drivers, internals, networks, applications, and training for VMS and Windows NT
uucp 'g' protocol guru and release coordinator, VMSnet (DECUS uucp) W.G., and 
Chair, Programming and Internals Working Group, U.S. DECUS VMS Systems SIG 
Internet:  jeh@cmkrnl.com  Uucp: uunet!cmkrnl!jeh  CIS: 74140,2055

In article <1993Mar23.205833.1057@dragon.com>, cts@dragon.com writes:
> I have a system where a real time application drives custom hardware via
> a DRV11-W and a custom driver.
> 
> One of the requirements of the system is that the hardware on the other
> end of the DRV11-W see an output several times a second to remain online.
> Right now, we're using a process to send out this "idle" message;  however,
> some of the other tasks that need to execute at a high priority (realtime,
> remember) sometimes prevent the idle task from doing its thing.  
> Setting the idle task to a higher priority is not desirable;  the 
> question has been asked - could this idle function be incorporated at
> the driver in such a fashion that the driver would handle the idle
> message without being delayed by the other processing on the system.
> 
> One method suggested casually was capturing the IRP of an idle message,
> and continually queueing it up over and over again.  I'm uncomfortable
> with this approach.  Any ideas or suggestions from the net?
> 
> --
> Charles T. Smith, Jr.                         | "Beam me up, Scotty, there's no 
> VMS & Network Consulting                      |  intelligent life down here..."
> cts@dragon.com                                |
> {gatech,emory}!dragon!cts                     |
> 

	--- Jamie Hanrahan, Kernel Mode Systems, San Diego CA
drivers, internals, networks, applications, and training for VMS and Windows NT
uucp 'g' protocol guru and release coordinator, VMSnet (DECUS uucp) W.G., and 
Chair, Programming and Internals Working Group, U.S. DECUS VMS Systems SIG 
Internet:  jeh@cmkrnl.com  Uucp: uunet!cmkrnl!jeh  CIS: 74140,2055


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Driver Question
  1993-03-25 18:32 ` Bob Koehler
@ 1993-03-29 13:02   ` Paul Repacholi
  0 siblings, 0 replies; 5+ messages in thread
From: Paul Repacholi @ 1993-03-29 13:02 UTC (permalink / raw)


In article <25MAR199313325730@author.gsfc.nasa.gov>, rkoehler@author.gsfc.nasa.gov (Bob Koehler) writes:
> In article <1993Mar23.205833.1057@dragon.com>, cts@dragon.com writes...
>>I have a system where a real time application drives custom hardware via
>>a DRV11-W and a custom driver.
>> 
>>One of the requirements of the system is that the hardware on the other
>>end of the DRV11-W see an output several times a second to remain online.
>>Right now, we're using a process to send out this "idle" message;  however,
>>some of the other tasks that need to execute at a high priority (realtime,
>>remember) sometimes prevent the idle task from doing its thing.  

I would look at 2 ways of doing it. First is the queue a timer entry from the
DR driver. The second would be to add a 'class driver' for these aplications
to go through. This means your DR driver is 'uncontaminated' for other uses.
You can also add the various initalization and retransmit stuff here so the
aps are simple. Much more work in the driver though...

~Paul



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~1993-03-29 13:02 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1993-03-24  1:58 Driver Question cts
1993-03-24 23:23 ` David L. Cathey
1993-03-25 18:32 ` Bob Koehler
1993-03-29 13:02   ` Paul Repacholi
1993-03-27  2:24 ` jeh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox