All of lore.kernel.org
 help / color / mirror / Atom feed
* "upping" a semaphore from interrupt context?
@ 2007-06-22 17:38 Florin Iucha
  2007-06-22 17:34 ` Arnd Bergmann
  2007-06-22 17:50 ` Satyam Sharma
  0 siblings, 2 replies; 15+ messages in thread
From: Florin Iucha @ 2007-06-22 17:38 UTC (permalink / raw)
  To: Linux Kernel Mailing List

[-- Attachment #1: Type: text/plain, Size: 686 bytes --]

Hello,

I am writing a USB driver for some custom hardware, and I need to
synchronize between the user-space and the USB subsystem.  Can I
create a semaphore and "down" it in the reader then "up" it in the
completion handler?

I know the completion handler runs in interrupt context so you are not
allowed to acquire any semaphores: but can you release them?  Will the
waiting tasks wake up after the handler and its caller returned - IOW
will the waking up task run in interrupt context as well?

This is with Linux 2.4 (if it makes a difference).

Thanks,
florin

-- 
Bruce Schneier expects the Spanish Inquisition.
      http://geekz.co.uk/schneierfacts/fact/163

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

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

end of thread, other threads:[~2007-06-24 18:12 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-22 17:38 "upping" a semaphore from interrupt context? Florin Iucha
2007-06-22 17:34 ` Arnd Bergmann
2007-06-23 11:52   ` Robert P. J. Day
2007-06-23 12:02     ` Arnd Bergmann
2007-06-23 12:06       ` Robert P. J. Day
2007-06-23 15:42       ` Satyam Sharma
2007-06-23 15:52         ` Oliver Neukum
2007-06-23 17:02           ` Satyam Sharma
2007-06-23 16:11         ` Robert P. J. Day
2007-06-23 17:16           ` Satyam Sharma
2007-06-24 15:25             ` Robert P. J. Day
2007-06-24 16:45               ` Satyam Sharma
2007-06-24 16:59                 ` Robert P. J. Day
2007-06-24 18:12                   ` Satyam Sharma
2007-06-22 17:50 ` Satyam Sharma

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.