From: Jozsef Kadlecsik Date: Fri, 6 Mar 2009 10:09:46 +0000 (+0100) Subject: Use spinlock initiator instead of setting the locks directly (Jan Engelhardt). X-Git-Tag: v2.5.0~1 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b8518b68b228c2d061b89fa4df9e898f4b242baa;p=thirdparty%2Fipset.git Use spinlock initiator instead of setting the locks directly (Jan Engelhardt). --- diff --git a/kernel/ip_set.c b/kernel/ip_set.c index f52647fe..15e98d0c 100644 --- a/kernel/ip_set.c +++ b/kernel/ip_set.c @@ -877,7 +877,7 @@ ip_set_create(const char *name, set = kmalloc(sizeof(struct ip_set), GFP_KERNEL); if (!set) return -ENOMEM; - set->lock = RW_LOCK_UNLOCKED; + rwlock_init(&set->lock); strncpy(set->name, name, IP_SET_MAXNAMELEN); set->binding = IP_SET_INVALID_ID; atomic_set(&set->ref, 0);