summaryrefslogtreecommitdiff
path: root/kernel/time
diff options
context:
space:
mode:
authorZhu Yi <yi.zhu@intel.com>2008-12-17 16:52:33 +0800
committerGreg Kroah-Hartman <gregkh@suse.de>2009-01-18 10:35:27 -0800
commitf7853c4f831743203c292b28968239cca37f51f8 (patch)
tree0330272645adb6db5c769ae87d2b71d94e20da6a /kernel/time
parentceaccb6a0b1816a05cccb77a0f5343a1a900d3cb (diff)
iwlwifi: use GFP_KERNEL to allocate Rx SKB memory
commit f1bc4ac61f2c08515afd80c6dc3962aa6d0b138b upstream. Previously we allocate Rx SKB with GFP_ATOMIC flag. This is because we need to hold a spinlock to protect the two rx_used and rx_free lists operation in the rxq. spin_lock(); ... element = rxq->rx_used.next; element->skb = alloc_skb(..., GFP_ATOMIC); list_del(element); list_add_tail(&element->list, &rxq->rx_free); ... spin_unlock(); After spliting the rx_used delete and rx_free insert into two operations, we don't require the skb allocation in an atomic context any more (the function itself is scheduled in a workqueue). spin_lock(); ... element = rxq->rx_used.next; list_del(element); ... spin_unlock(); ... element->skb = alloc_skb(..., GFP_KERNEL); ... spin_lock() ... list_add_tail(&element->list, &rxq->rx_free); ... spin_unlock(); This patch should fix the "iwlagn: Can not allocate SKB buffers" warning we see recently. Signed-off-by: Zhu Yi <yi.zhu@intel.com> Acked-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: John W. Linville <linville@tuxdriver.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'kernel/time')
0 files changed, 0 insertions, 0 deletions