Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Mar 2000 13:09:10 -0800
From:      Eric Peterson <ericp@troikanetworks.com>
To:        'Samuel Tardieu' <sam@inf.enst.fr>
Cc:        "'hackers@freebsd.org'" <hackers@freebsd.org>, 'Mike Smith' <msmith@freebsd.org>
Subject:   RE: Deferred procedure call available?
Message-ID:  <C7CA595F9B9FD311A40D009027DC4A856E7E3E@host03.troikanetworks.com>

next in thread | raw e-mail | index | archive | help


> -----Original Message-----
Samuel Tardieu [mailto:sam@inf.enst.fr] writes:
> Sent: Thursday, March 30, 2000 11:46 AM
> To: Eric Peterson
> Cc: 'hackers@freebsd.org'
> Subject: Re: Deferred procedure call available?
> 
> 
> >>>>> "Eric" == Eric Peterson <ericp@troikanetworks.com> writes:
> 
> Eric> Sometimes called "task queues" or "deferred callbacks", they
> Eric> allow an interrupt handler to schedule a (possibly predefined)
> Eric> function to be called outside the context of the interrupt.
> 
> (not an answer, just a suggestion) Is there anything you cannot do
> with a userland program, that will be resumed by the interrupt
> handler? Doing this even gives you the possibility of choosing the
> priority of the deferred handler relative to other handler and regular
> processes (as eCos does).

Sam,
	Thanks for the response. With regard to your suggestion (my
ignorance of
	FreeBSD drivers certainly shows through here, but...): 

		1. I'm porting an existing driver, so am trying to keep its
basic 
		structure intact. I don't believe that a user-mode entity
has
		access to the memory/device address space I need to get to.

		2. I suspect that going from kernel to (even high priority)
user
		mode entails a non-trivial performance penalty (somebody
please correct
		me if not!)

	One other approach I was thinking about was to have a sleeping
kernel thread
	that I could wakeup when I needed to schedule a function to be
called.
	
	I'm going to try out the timeout(9) routine that Mike Smith
suggested, looks like
	just the ticket (thanks again, Mike).

Regards,
Eric

--
Eric Peterson     WB6PYK
ericp@troikanetworks.com
PGP: http://pgp5.ai.mit.edu:11371/pks/lookup?op=get&search=0x4DA8EEF1


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?C7CA595F9B9FD311A40D009027DC4A856E7E3E>