Re: [PATCH] d80211: use list_for_each_entry{,_safe}
From: Johannes Berg <johannes@sipsolutions.net>
Date: 2006-08-31 06:58:25
From: Johannes Berg <johannes@sipsolutions.net>
Date: 2006-08-31 06:58:25
On Wed, 2006-08-30 at 08:43 -0700, Jouni Malinen wrote:
Could you please separate cleanup parts (list_for_each changes) from functional changes (adding locking) to make it easier to review the patch?
Yeah, I guess I should do that.
I would prefer not to hold spinlocks when calling registered callbacks from the hardware driver. At minimum, this would need to be documented very clearly to make sure that whoever is writing low-level drivers would be aware of this. In general, it would just be simpler if this can be avoided altogether.
You don't really have a choice here. The spinlock is the only thing that protects the list... Not holding it is, umm, a bug :) johannes