mac80211: fix ath9k kernel crash with linux 4.9
authorFelix Fietkau <nbd@nbd.name>
Tue, 7 Feb 2017 10:36:31 +0000 (11:36 +0100)
committerFelix Fietkau <nbd@nbd.name>
Tue, 7 Feb 2017 10:38:54 +0000 (11:38 +0100)
Signed-off-by: Felix Fietkau <nbd@nbd.name>
package/kernel/mac80211/patches/548-ath9k_enable_gpio_chip.patch

index 2900ece9144f5b113342f7ce6009a6d032dd67cf..d4269282d960d857cde3f81d1839359cf3447ff2 100644 (file)
@@ -123,6 +123,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
 +      if (!gc)
 +              return;
 +
++      gc->sc = sc;
 +      snprintf(gc->label, sizeof(gc->label), "ath9k-%s",
 +               wiphy_name(sc->hw->wiphy));
 +#if LINUX_VERSION_CODE >= KERNEL_VERSION(4,5,0)
@@ -146,7 +147,6 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
 +
 +      gc->gchip.owner = NULL;
 +      sc->gpiochip = gc;
-+      gc->sc = sc;
 +}
 +
 +/* remove GPIO chip */