All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Hudec <bulb@ucw.cz>
To: SA <bullet.train@ntlworld.com>, linux-kernel@vger.kernel.org
Subject: Re: device driver / char module interrupt vector -> user space code
Date: Fri, 9 Aug 2002 11:35:49 +0200	[thread overview]
Message-ID: <20020809093549.GF13165@vagabond> (raw)
In-Reply-To: <1028889240.30103.189.camel@irongate.swansea.linux.org.uk>

On Fri, Aug 09, 2002 at 11:34:00AM +0100, Alan Cox wrote:
> On Fri, 2002-08-09 at 09:49, SA wrote:
> > I am writing a char module for a PCI stage controller and want to add the 
> > following functionality; 
> > 
> > The device will generate an interrupt (or software trigger) and I want this to 
> > run a bit of user code with relatively latency.  (<1ms).  I am unclear how to
> > do this while still separating the user from the kernel code and maintaining
> > security - would this usually be handled by issuing a signal to the user space
> > process? if so how and what latency can I expect? 
> 
> You could deliver a signal, or if appropriate you can have a system call
> that blocks until the IRQ. To get good reliable latency, mlockall() the 
> process you need to be real time, and set it to a real time scheduling
> priority.

If you noticed the discussion about signal delivery and context switch
latency, a syscall (can be ioctl on special device) waiting for the
event would be faster than signal.

-------------------------------------------------------------------------------
						 Jan 'Bulb' Hudec <bulb@ucw.cz>

  reply	other threads:[~2002-08-09  9:32 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-08-09  8:49 device driver / char module interrupt vector -> user space code SA
2002-08-09 10:34 ` Alan Cox
2002-08-09  9:35   ` Jan Hudec [this message]
2002-08-09 12:46   ` Gilad Ben-Yossef

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20020809093549.GF13165@vagabond \
    --to=bulb@ucw.cz \
    --cc=bullet.train@ntlworld.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.