Skip to contentSkip to conversation

ath9k: Random cleanup

PATCH New Sujith 1 participant 1 message Aug 14, 2008 Networking drivers (wireless)

lore
Share & tools
lore

Sujith

author
#0 lore raw

PATCH 2/6 ath9k: Random cleanup

Remove dead code, add newlines, fix indentation.

---
 drivers/net/wireless/ath9k/core.c |    5 +-
 drivers/net/wireless/ath9k/hw.c   |   13 +---
 drivers/net/wireless/ath9k/rc.c   |  159 +++++++++++++++++++------------------
 3 files changed, 83 insertions(+), 94 deletions(-)
drivers/net/wireless/ath9k/core.c +1 -4
index a9e8ad0..e3682b6 100644
@@ -1025,7 +1025,6 @@ int ath_init(u16 devid, struct ath_softc *sc)
 	int status;
 	int error = 0, i;
 	int csz = 0;
-	u32 rd;
 
 	/* XXX: hardware will not be ready until ath_open() being called */
 	sc->sc_flags |= SC_OP_INVALID;
@@ -1091,8 +1090,6 @@ int ath_init(u16 devid, struct ath_softc *sc)
 	 * is resposible for filtering this list based on settings
 	 * like the phy mode.
 	 */
-	rd = ah->ah_currentRD;
-
 	error = ath_setup_channels(sc);
 	if (error)
 		goto bad;
@@ -1169,7 +1166,7 @@ int ath_init(u16 devid, struct ath_softc *sc)
 
 	sc->sc_rc = ath_rate_attach(ah);
 	if (sc->sc_rc == NULL) {
-		error = EIO;
+		error = -EIO;
 		goto bad2;
 	}
 
drivers/net/wireless/ath9k/hw.c +2 -11
index 72ad3f3..23eb789 100644
@@ -7650,8 +7650,7 @@ bool ath9k_hw_resettxqueue(struct ath_hal *ah, u32 q)
 	REG_WRITE(ah, AR_DRETRY_LIMIT(q),
 		  SM(INIT_SSH_RETRY, AR_D_RETRY_LIMIT_STA_SH)
 		  | SM(INIT_SLG_RETRY, AR_D_RETRY_LIMIT_STA_LG)
-		  | SM(qi->tqi_shretry, AR_D_RETRY_LIMIT_FR_SH)
-		);
+		  | SM(qi->tqi_shretry, AR_D_RETRY_LIMIT_FR_SH));
 
 	REG_WRITE(ah, AR_QMISC(q), AR_Q_MISC_DCU_EARLY_TERM_REQ);
 	REG_WRITE(ah, AR_DMISC(q),
@@ -8296,15 +8295,7 @@ struct ath_hal *ath9k_hw_attach(u16 devid,
 		*error = -ENXIO;
 		break;
 	}
-	if (ah != NULL) {
-		ah->ah_devid = ah->ah_devid;
-		ah->ah_subvendorid = ah->ah_subvendorid;
-		ah->ah_macVersion = ah->ah_macVersion;
-		ah->ah_macRev = ah->ah_macRev;
-		ah->ah_phyRev = ah->ah_phyRev;
-		ah->ah_analog5GhzRev = ah->ah_analog5GhzRev;
-		ah->ah_analog2GhzRev = ah->ah_analog2GhzRev;
-	}
+
 	return ah;
 }
 
drivers/net/wireless/ath9k/rc.c +80 -79

407 lines not on this page · raw message

Signature · 1 line
1.5.6.5