Date: Thu, 29 Jan 2015 15:57:28 +0000 From: "gnn (George Neville-Neil)" <phabric-noreply@FreeBSD.org> To: freebsd-net@freebsd.org Subject: [Differential] [Requested Changes To] D1707: sfxge: access statistics buffers under port lock Message-ID: <63958787bd31353ba613da583e4e4b19@localhost.localdomain> In-Reply-To: <differential-rev-PHID-DREV-defmxvevbobjt3cs6kel-req@FreeBSD.org> References: <differential-rev-PHID-DREV-defmxvevbobjt3cs6kel-req@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
gnn requested changes to this revision. gnn added a comment. This revision now requires changes to proceed. If you look at other drivers you'll see they have #define'd macros for the locks, rather than direct calls. This allows us to name the lock in the macro. See, for instance, this example from cxgbe/adapter.h: #define ADAPTER_LOCK(sc) mtx_lock(&(sc)->sc_lock) #define ADAPTER_UNLOCK(sc) mtx_unlock(&(sc)->sc_lock) #define ADAPTER_LOCK_ASSERT_OWNED(sc) mtx_assert(&(sc)->sc_lock, MA_OWNED) #define ADAPTER_LOCK_ASSERT_NOTOWNED(sc) mtx_assert(&(sc)->sc_lock, MA_NOTOWNED) You should move to this model and then update the patch. REVISION DETAIL https://reviews.freebsd.org/D1707 To: arybchik, gnn Cc: freebsd-net
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?63958787bd31353ba613da583e4e4b19>