lkml.org 
[lkml]   [2010]   [Oct]   [12]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[tip:core/locking] hamradio: Mkiss: semaphore cleanup
    Commit-ID:  495e64bddeb9349395ed346177057fff7d52857e
    Gitweb: http://git.kernel.org/tip/495e64bddeb9349395ed346177057fff7d52857e
    Author: Thomas Gleixner <tglx@linutronix.de>
    AuthorDate: Tue, 7 Sep 2010 14:32:18 +0000
    Committer: Thomas Gleixner <tglx@linutronix.de>
    CommitDate: Tue, 12 Oct 2010 17:36:09 +0200

    hamradio: Mkiss: semaphore cleanup

    Get rid of init_MUTEX[_LOCKED]() and use sema_init() instead.

    Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Christoph Hellwig <hch@infradead.org>
    Acked-by: David Miller <davem@davemloft.net>
    LKML-Reference: <20100907125055.368389976@linutronix.de>

    ---
    drivers/net/hamradio/mkiss.c | 2 +-
    1 files changed, 1 insertions(+), 1 deletions(-)

    diff --git a/drivers/net/hamradio/mkiss.c b/drivers/net/hamradio/mkiss.c
    index 66e88bd..4c62839 100644
    --- a/drivers/net/hamradio/mkiss.c
    +++ b/drivers/net/hamradio/mkiss.c
    @@ -747,7 +747,7 @@ static int mkiss_open(struct tty_struct *tty)

    spin_lock_init(&ax->buflock);
    atomic_set(&ax->refcnt, 1);
    - init_MUTEX_LOCKED(&ax->dead_sem);
    + sema_init(&ax->dead_sem, 0);

    ax->tty = tty;
    tty->disc_data = ax;

    \
     
     \ /
      Last update: 2010-10-12 17:53    [W:0.022 / U:0.288 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site