X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=include%2Fasm-s390%2Fsemaphore.h;fp=include%2Fasm-s390%2Fsemaphore.h;h=32cdc69f39f4dd28c42521e67d77a7b536356cdc;hb=16c70f8c1b54b61c3b951b6fb220df250fe09b32;hp=702cf436698c60e77ee5198600df6ad8506c07c4;hpb=4e76c8a9fa413ccc09d3f7f664183dcce3555d57;p=linux-2.6.git diff --git a/include/asm-s390/semaphore.h b/include/asm-s390/semaphore.h index 702cf4366..32cdc69f3 100644 --- a/include/asm-s390/semaphore.h +++ b/include/asm-s390/semaphore.h @@ -37,7 +37,8 @@ struct semaphore { static inline void sema_init (struct semaphore *sem, int val) { - *sem = (struct semaphore) __SEMAPHORE_INITIALIZER((*sem),val); + atomic_set(&sem->count, val); + init_waitqueue_head(&sem->wait); } static inline void init_MUTEX (struct semaphore *sem)