Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Re: multimedia/vlc causes a panic if media files are on msdosfs

0 views
Skip to first unread message

Kostik Belousov

unread,
Nov 20, 2009, 6:02:10 AM11/20/09
to Doug Barton, freebsd...@freebsd.org, del...@freebsd.org
On Thu, Nov 19, 2009 at 02:30:33PM -0800, Doug Barton wrote:
> Please see http://www.freebsd.org/cgi/query-pr.cgi?pr=140648 for more
> information, including a trace.
>
> There is also some evidence that the same problem is triggered by
> accessing files on an NTFS partition. The VLC folks have suggested
> that the problem may be related to threading.

This is because msdosfs and ntfs are not mpsafe, and it seems that
VLC using recently added F_RDAHEAD/F_READAHEAD fcntls.

Please try this.

diff --git a/sys/kern/kern_descrip.c b/sys/kern/kern_descrip.c
index 434f54a..676de65 100644
--- a/sys/kern/kern_descrip.c
+++ b/sys/kern/kern_descrip.c
@@ -718,14 +718,15 @@ kern_fcntl(struct thread *td, int fd, int cmd, intptr_t arg)
do {
new = old = fp->f_flag;
new |= FRDAHEAD;
- } while (atomic_cmpset_rel_int(&fp->f_flag, old, new) == 0);
+ } while (!atomic_cmpset_rel_int(&fp->f_flag, old, new));
readahead_vnlock_fail:
VFS_UNLOCK_GIANT(vfslocked);
+ vfslocked = 0;
} else {
do {
new = old = fp->f_flag;
new &= ~FRDAHEAD;
- } while (atomic_cmpset_rel_int(&fp->f_flag, old, new) == 0);
+ } while (!atomic_cmpset_rel_int(&fp->f_flag, old, new));
}
fdrop(fp, td);
break;

Aditya Sarawgi

unread,
Nov 20, 2009, 9:18:21 AM11/20/09
to Kostik Belousov, do...@dougbartion.us, freebsd...@freebsd.org, del...@freebsd.org

I have been getting panics with VLC on UFS filesytem too, Although the
frequency of panics on a UFS filesystem is pretty low as compared to
msdosfs and ntfs systems and they are very abrupt. I will try getting a
trace.

--
Aditya Sarawgi
_______________________________________________
freebsd...@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-curre...@freebsd.org"

Rainer Hurling

unread,
Nov 20, 2009, 10:59:38 AM11/20/09
to do...@dougbarton.us, Kostik Belousov, Aditya Sarawgi, freebsd...@freebsd.org, del...@freebsd.org

I am observing panics also with newest vlc port on ufs2. System panics
whenever playing .flv files.

Doug Barton

unread,
Nov 20, 2009, 4:55:45 PM11/20/09
to Kostik Belousov, freebsd...@freebsd.org, del...@freebsd.org, bug-fo...@freebsd.org

Voila! Thanks.

Doug

--

Improve the effectiveness of your Internet presence with
a domain name makeover! http://SupersetSolutions.com/

Rainer Hurling

unread,
Nov 21, 2009, 12:47:11 PM11/21/09
to do...@dougbarton.us, Kostik Belousov, Aditya Sarawgi, freebsd...@freebsd.org, del...@freebsd.org

With this patch even my panics went away :-)

Thank you very much,
Rainer Hurling

Oliver Pinter

unread,
Nov 21, 2009, 6:45:27 PM11/21/09
to Rainer Hurling, Kostik Belousov, Aditya Sarawgi, freebsd...@freebsd.org, del...@freebsd.org, do...@dougbarton.us
can you run memtest?

Rainer Hurling

unread,
Nov 23, 2009, 12:14:10 PM11/23/09
to Oliver Pinter, Kostik Belousov, Aditya Sarawgi, freebsd...@freebsd.org, del...@freebsd.org, do...@dougbarton.us
On 22.11.2009 00:44 (UTC+1), Oliver Pinter wrote:
> can you run memtest?

hmmm. memtest reports no errors. And I do not think that this was a
memory specific task.
I observed the below described behaviour on to different machines, both
running 9.0-CURRENT. And there are no panics any more after system
update on november 21th.

0 new messages