From: Johannes Berg Date: Sat, 25 Jul 2009 10:35:09 +0200 Subject: [ath9k-devel] [PATCH] mac80211: redefine usage of the mac80211 workqueue In-Reply-To: <1248482853-17032-2-git-send-email-lrodriguez@atheros.com> References: <1248482853-17032-1-git-send-email-lrodriguez@atheros.com> <1248482853-17032-2-git-send-email-lrodriguez@atheros.com> Message-ID: <1248510909.32151.48.camel@johannes.local> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: ath9k-devel@lists.ath9k.org On Fri, 2009-07-24 at 20:47 -0400, Luis R. Rodriguez wrote: > The mac80211 workqueue exists to enable mac80211 and drivers > to queue their own work on a single threaded workqueue. mac80211 > takes care to flush the workqueue during suspend but we never > really had requirements on drivers for how they should use > the workqueue in consideration for suspend. > > We extend mac80211 to document how the mac80211 workqueue should > be used, how it should not be used and finally move raw access to > the workqueue to mac80211 only. Drivers and mac80211 use helpers > to queue work and flush the mac80211 workqueue: > > * ieee80211_queue_work() > * ieee80211_queue_delayed_work() > * ieee80211_flush_workqueue() I would prefer to have wait_on_work() and/or cancel_work_sync() instead of flushing? It's often preferable due to locking constraints to cancel_work_sync() instead of flush_workqueue(). Do people really need flush_workqueue()? johannes -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 801 bytes Desc: This is a digitally signed message part Url : http://lists.ath9k.org/pipermail/ath9k-devel/attachments/20090725/0386a56d/attachment.pgp