Re: [PATCH] netfilter: use per-cpu recursive lock (v11)

From: Lai Jiangshan
Date: Tue Apr 21 2009 - 01:49:16 EST



My silly opinion about lockdep in this patch:

> +
> +struct xt_info_lock {
> + spinlock_t lock;

+ struct lock_class_key key;

> + int depth; /* # readers - 1 */
> +};
> +static DEFINE_PER_CPU(struct xt_info_lock, xt_info_locks);
> +
> +
> +static inline void xt_info_lock_init(struct xt_info_lock *lock)
> +{
> + spin_lock_init(&lock->lock);

+ lockdep_set_class(&lock->lock, &lock->key);

> + lock->depth = -1;
> +}
> +

And remove lockdep_xxx()s.


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/