Re: [PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Sylwester Nawrocki
On 06/11/13 15:51, Hans Verkuil wrote: Rename __vb2_fop_release to vb2_fop_release_unlock and rearrange >>> arguments >>> >> >>> >> I know I suggested the vb2_fop_release_unlock name, but on second >>> >> thoughts >>> >> that's not a good name. I suggest vb2_fop_release_no_lock instead.

Re: [PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Hans Verkuil
On 11/06/13 15:46, Sylwester Nawrocki wrote: > Hello, > > (dropping some unrelated e-mail addresses from Cc) > > On 06/11/13 10:07, Hans Verkuil wrote: >> On 11/06/13 09:24, Ricardo Ribalda Delgado wrote: >>> From: Ricardo Ribalda >>> >>> vb2_fop_relase does not held the lock although it is modi

Re: [PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Sylwester Nawrocki
Hello, (dropping some unrelated e-mail addresses from Cc) On 06/11/13 10:07, Hans Verkuil wrote: > On 11/06/13 09:24, Ricardo Ribalda Delgado wrote: >> From: Ricardo Ribalda >> >> vb2_fop_relase does not held the lock although it is modifying the > > Small typo: _relase -> _release > >> queue-

Re: [PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Ricardo Ribalda Delgado
Hello Hans I will fix both things, but I will wait a couple of hours in case there is more changes, to avoid spamming the list. Thanks On Wed, Nov 6, 2013 at 10:07 AM, Hans Verkuil wrote: > On 11/06/13 09:24, Ricardo Ribalda Delgado wrote: >> From: Ricardo Ribalda >> >> vb2_fop_relase does not

Re: [PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Hans Verkuil
On 11/06/13 09:24, Ricardo Ribalda Delgado wrote: > From: Ricardo Ribalda > > vb2_fop_relase does not held the lock although it is modifying the Small typo: _relase -> _release > queue->owner field. > > This could lead to race conditions on the vb2_perform_io function > when multiple applicati

[PATCH v5] videobuf2: Add missing lock held on vb2_fop_relase

2013-11-06 Thread Ricardo Ribalda Delgado
From: Ricardo Ribalda vb2_fop_relase does not held the lock although it is modifying the queue->owner field. This could lead to race conditions on the vb2_perform_io function when multiple applications are accessing the video device via read/write API: [ 308.297741] BUG: unable to handle kernel