lkml.org 
[lkml]   [2015]   [Apr]   [7]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 3/3] staging: dgnc: improve the coding style in unlocking part of dgnc_tty_write()
On Tue, Apr 07, 2015 at 11:17:48AM +0300, Dan Carpenter wrote:
> This patch changes the lock ordering (behavior change) and it's not
> described in the changelog. Please figure out which way is the correct
> ordering and resend.

Actually the original ordering was obviously correct. You can't take
a mutex if you are holding a spinlock. So it always has to be:

mutex_lock();
spin_lock();

spin_unlock();
mutext_unlock();

regards,
dan carpenter



\
 
 \ /
  Last update: 2015-04-07 11:01    [W:0.094 / U:0.204 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site