diff options
Diffstat (limited to 'drivers/net/wireless/ath9k/recv.c')
-rw-r--r-- | drivers/net/wireless/ath9k/recv.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath9k/recv.c b/drivers/net/wireless/ath9k/recv.c index 3df5c7824360..9439cb351118 100644 --- a/drivers/net/wireless/ath9k/recv.c +++ b/drivers/net/wireless/ath9k/recv.c | |||
@@ -100,7 +100,7 @@ static u64 ath_extend_tsf(struct ath_softc *sc, u32 rstamp) | |||
100 | return (tsf & ~0x7fff) | rstamp; | 100 | return (tsf & ~0x7fff) | rstamp; |
101 | } | 101 | } |
102 | 102 | ||
103 | static struct sk_buff *ath_rxbuf_alloc(struct ath_softc *sc, u32 len) | 103 | static struct sk_buff *ath_rxbuf_alloc(struct ath_softc *sc, u32 len, gfp_t gfp_mask) |
104 | { | 104 | { |
105 | struct sk_buff *skb; | 105 | struct sk_buff *skb; |
106 | u32 off; | 106 | u32 off; |
@@ -118,7 +118,7 @@ static struct sk_buff *ath_rxbuf_alloc(struct ath_softc *sc, u32 len) | |||
118 | * Unfortunately this means we may get 8 KB here from the | 118 | * Unfortunately this means we may get 8 KB here from the |
119 | * kernel... and that is actually what is observed on some | 119 | * kernel... and that is actually what is observed on some |
120 | * systems :( */ | 120 | * systems :( */ |
121 | skb = dev_alloc_skb(len + sc->cachelsz - 1); | 121 | skb = __dev_alloc_skb(len + sc->cachelsz - 1, gfp_mask); |
122 | if (skb != NULL) { | 122 | if (skb != NULL) { |
123 | off = ((unsigned long) skb->data) % sc->cachelsz; | 123 | off = ((unsigned long) skb->data) % sc->cachelsz; |
124 | if (off != 0) | 124 | if (off != 0) |
@@ -306,7 +306,7 @@ int ath_rx_init(struct ath_softc *sc, int nbufs) | |||
306 | } | 306 | } |
307 | 307 | ||
308 | list_for_each_entry(bf, &sc->rx.rxbuf, list) { | 308 | list_for_each_entry(bf, &sc->rx.rxbuf, list) { |
309 | skb = ath_rxbuf_alloc(sc, sc->rx.bufsize); | 309 | skb = ath_rxbuf_alloc(sc, sc->rx.bufsize, GFP_KERNEL); |
310 | if (skb == NULL) { | 310 | if (skb == NULL) { |
311 | error = -ENOMEM; | 311 | error = -ENOMEM; |
312 | break; | 312 | break; |
@@ -580,7 +580,7 @@ int ath_rx_tasklet(struct ath_softc *sc, int flush) | |||
580 | 580 | ||
581 | /* Ensure we always have an skb to requeue once we are done | 581 | /* Ensure we always have an skb to requeue once we are done |
582 | * processing the current buffer's skb */ | 582 | * processing the current buffer's skb */ |
583 | requeue_skb = ath_rxbuf_alloc(sc, sc->rx.bufsize); | 583 | requeue_skb = ath_rxbuf_alloc(sc, sc->rx.bufsize, GFP_ATOMIC); |
584 | 584 | ||
585 | /* If there is no memory we ignore the current RX'd frame, | 585 | /* If there is no memory we ignore the current RX'd frame, |
586 | * tell hardware it can give us a new frame using the old | 586 | * tell hardware it can give us a new frame using the old |