Mailing List archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[linux-dvb] Re: More thoughts on coldboot driver crash
- To: Holger Waechtler <holger@convergence.de>
- Subject: [linux-dvb] Re: More thoughts on coldboot driver crash
- From: "Dr. Werner Fink" <werner@suse.de>
- Date: Tue, 7 Jan 2003 15:17:20 +0100
- Cc: linux-dvb@linuxtv.org
- Content-disposition: inline
- Content-type: text/plain; charset=us-ascii
- In-reply-to: <3E079E18.1080802@convergence.de>
- Organization: SuSE GmbH
- References: <1040660962.3003.15.camel@monstrousfish.lidskialf.net> <15879.18104.877630.23150@gargle.gargle.HOWL> <3E079E18.1080802@convergence.de>
- Sender: linux-dvb-bounce@linuxtv.org
- User-agent: Mutt/1.4i
On Tue, Dec 24, 2002 at 12:36:56AM +0100, Holger Waechtler wrote:
> @@ -1040,11 +1059,17 @@ unsigned int
> DmxDevDVRPoll(dmxdev_t *dmxdev, struct file *file, poll_table * wait)
> {
> if ((file->f_flags&O_ACCMODE)==O_RDONLY) {
> + if (dmxdev->dvr_buffer.error)
> + return (POLLIN | POLLRDNORM | POLLPRI | POLLERR);
> +
> if (dmxdev->dvr_buffer.pread!=dmxdev->dvr_buffer.pwrite)
> return (POLLIN | POLLRDNORM | POLLPRI);
>
> poll_wait(file, &dmxdev->dvr_buffer.queue, wait);
>
> + if (dmxdev->dvr_buffer.error)
> + return (POLLIN | POLLRDNORM | POLLPRI | POLLERR);
> +
> if (dmxdev->dvr_buffer.pread!=dmxdev->dvr_buffer.pwrite)
> return (POLLIN | POLLRDNORM | POLLPRI);
>
Just as remark: AFAIS poll_wait() never ever waits (aka NO scheduler call) but
only add the wait queue to the poll table used by both the
sys_poll and sys_select calls (-> linux/fs/select.c, linux/include/linux/poll.h).
In other words: simply removing the the two checks before poll_wait() will avoid
not needed code. This holds also true for all other poll functions around within
the DVB driver.
Werner
--
Info:
To unsubscribe send a mail to listar@linuxtv.org with "unsubscribe linux-dvb" as subject.
Home |
Main Index |
Thread Index