Date: Wed, 29 Nov 1995 03:50:42 +0000 () From: Michael Smith <msmith@atrad.adelaide.edu.au> To: hackers@freebsd.org Subject: more device driver question 8) Message-ID: <199511290350.DAA10336@genesis.atrad.adelaide.edu.au>
next in thread | raw e-mail | index | archive | help
Ok, and another one 8) Driver read routine sets up buffers, etc. Driver enables interrupts on peripheral. Peripheral immediately interrupts, may satisfy whole read request. Driver goes to sleep waiting for read request to be satsified. ... I can't see how to avoid this race; I'm sure it must be possible, but browsing other drivers yields no immediate inspiration. Some sleep at raised interrupt level: spltty() tsleep(...) splx() Does this imply that tsleep() restores the base interrupt level while it's running? Because the peripheral's data rate is entirely dependant on an external source, it's impossible to know how fast or slow it will be 8( -- ]] Mike Smith, Software Engineer msmith@atrad.adelaide.edu.au [[ ]] Genesis Software genesis@atrad.adelaide.edu.au [[ ]] High-speed data acquisition and (GSM mobile) 041-122-496 [[ ]] realtime instrument control (ph/fax) +61-8-267-3039 [[ ]] "Who does BSD?" "We do Chucky, we do." [[
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199511290350.DAA10336>