From bc974f4a230756faf4f69114f271de2e678b363b Mon Sep 17 00:00:00 2001 From: "Luis R. Rodriguez" Date: Mon, 28 Sep 2009 02:54:40 -0400 Subject: atheros: define a common priv struct hw code should never use private driver data, but sometimes we need a backpointer so just stuff it on the common ath struct. Signed-off-by: Luis R. Rodriguez Signed-off-by: John W. Linville --- drivers/net/wireless/ath/ath9k/debug.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'drivers/net/wireless/ath/ath9k/debug.c') diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c index 352914cae6d8..25ae88ebdfac 100644 --- a/drivers/net/wireless/ath/ath9k/debug.c +++ b/drivers/net/wireless/ath/ath9k/debug.c @@ -562,8 +562,8 @@ static const struct file_operations fops_xmit = { int ath9k_init_debug(struct ath_hw *ah) { - struct ath_softc *sc = ah->ah_sc; - struct ath_common *common = ath9k_hw_common(sc->sc_ah); + struct ath_common *common = ath9k_hw_common(ah); + struct ath_softc *sc = (struct ath_softc *) common->priv; common->debug_mask = ath9k_debug; @@ -620,7 +620,8 @@ err: void ath9k_exit_debug(struct ath_hw *ah) { - struct ath_softc *sc = ah->ah_sc; + struct ath_common *common = ath9k_hw_common(ah); + struct ath_softc *sc = (struct ath_softc *) common->priv; debugfs_remove(sc->debug.debugfs_xmit); debugfs_remove(sc->debug.debugfs_wiphy); -- cgit v1.2.3