Re: [linux-dvb] A dvb-core code problem

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Zhang Xiaobing wrote:
> I found a code problem in dvb-core when I was debugging with my dvb
> driver.
>
> The code in dvb_dvr_release() file dmxdev.c
> /* TODO */
>     dvbdev->users--;
>     if(*dvbdev->users== -1* && dmxdev->exit==1) {
>         fops_put(file->f_op);
>         file->f_op = NULL;
>         mutex_unlock(&dmxdev->mutex);
>
> "dvbdev->users== -1" should be changed to "dvbdev->users== 1",
> otherwise driver may block forever in dvb_dmxdev_release() where a
> wakeup condition is "dvbdev->users== 1".
>
> Here is the code in dvb_dmxdev_release().
>
> if (dmxdev->dvr_dvbdev->users > 1) {
>         wait_event(dmxdev->dvr_dvbdev->wait_queue,
>                 *dmxdev->dvr_dvbdev->users==1*);
> }
>
> I hope it is right to post this message here.

Hi Zhang,  could you post a patch to the linux-media mail list; for
general info see here:
http://www.linuxtv.org/wiki/index.php/Development:_How_to_submit_patches


--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux