ath5k: free sc->ah in ath5k_deinit_softc
authorJohn W. Linville <linville@tuxdriver.com>
Fri, 17 Jun 2011 20:41:30 +0000 (16:41 -0400)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 20 Jun 2011 19:34:19 +0000 (15:34 -0400)
Nothing else is freeing it, and this mirrors the error handling path
already in ath5k_init_softc.

https://bugzilla.kernel.org/show_bug.cgi?id=37592

Signed-off-by: John W. Linville <linville@tuxdriver.com>
Reported-by: Tsyvarev Andrey <tsyvarev@ispras.ru>
drivers/net/wireless/ath/ath5k/base.c

index 3e70b1418a4a053ac6d166e3777f902220593c8e..a6623ddfdefe3546b56961e3be2feeab6617a9bd 100644 (file)
@@ -2960,6 +2960,7 @@ ath5k_deinit_softc(struct ath5k_softc *sc)
         * state and potentially want to use them.
         */
        ath5k_hw_deinit(sc->ah);
+       kfree(sc->ah);
        free_irq(sc->irq, sc);
 }