lkml.org 
[lkml]   [2010]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH RFC 07/11] Adopt the way of initializing semaphore to lock monitor
    Date
    Now spinlock_t doesn't have struct lockdep_map,
    this was replaced with struct lock_monitor.

    So this patch fixes the way of initializing semaphore.

    Signed-off-by: Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp>
    Cc: Ingo Molnar <mingo@elte.hu>
    Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
    Cc: Paul Mackerras <paulus@samba.org>
    Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
    Cc: Jens Axboe <jens.axboe@oracle.com>
    Cc: Jason Baron <jbaron@redhat.com>
    ---
    include/linux/semaphore.h | 2 +-
    1 files changed, 1 insertions(+), 1 deletions(-)

    diff --git a/include/linux/semaphore.h b/include/linux/semaphore.h
    index 7415839..d5aa2ba 100644
    --- a/include/linux/semaphore.h
    +++ b/include/linux/semaphore.h
    @@ -33,7 +33,7 @@ static inline void sema_init(struct semaphore *sem, int val)
    {
    static struct lock_class_key __key;
    *sem = (struct semaphore) __SEMAPHORE_INITIALIZER(*sem, val);
    - lockdep_init_map(&sem->lock.dep_map, "semaphore->lock", &__key, 0);
    + lockdep_init_map(&sem->lock.monitor.dep_map, "semaphore->lock", &__key, 0);
    }

    #define init_MUTEX(sem) sema_init(sem, 1)
    --
    1.6.5.2


    \
     
     \ /
      Last update: 2010-03-14 11:41    [W:0.023 / U:0.188 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site