summaryrefslogtreecommitdiff
path: root/drivers/nfc
diff options
context:
space:
mode:
authorMichal Schmidt <mschmidt@redhat.com>2013-09-05 20:13:09 (GMT)
committerDavid S. Miller <davem@davemloft.net>2013-09-11 19:43:54 (GMT)
commit996dedbafe640aee40dc846ad634dd352b6bcd44 (patch)
treebd7b091ebbf1ac628a2640c9cb4f4459bf2f5783 /drivers/nfc
parentc19d65c95c6d472d69829fea7d473228493d5245 (diff)
downloadlinux-fsl-qoriq-996dedbafe640aee40dc846ad634dd352b6bcd44.tar.xz
bnx2x: avoid atomic allocations during initialization
During initialization bnx2x allocates significant amounts of memory (for rx data, rx SGEs, TPA pool) using atomic allocations. I received a report where bnx2x failed to allocate SGEs and it had to fall back to TPA-less operation. Let's use GFP_KERNEL allocations during initialization, which runs in process context. Add gfp_t parameters to functions that are used both in initialization and in the receive path. Use an unlikely branch in bnx2x_frag_alloc() to avoid atomic allocation by netdev_alloc_frag(). The branch is taken several thousands of times during initialization, but then never more. Note that fp->rx_frag_size is never greater than PAGE_SIZE, so __get_free_page() can be used here. Signed-off-by: Michal Schmidt <mschmidt@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/nfc')
0 files changed, 0 insertions, 0 deletions