diff options
author | Joe Perches <joe@perches.com> | 2016-09-05 00:24:03 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-09-06 23:54:32 +0300 |
commit | 2591c280c375c547022eb619895c1aebbbc38219 (patch) | |
tree | 19932d8d7f6af8e9e4c9c3f1c413a871b0db4ff2 /drivers/net/ethernet/qlogic/qed/qed_hw.c | |
parent | c7ee5672f38e3602e2c1bc935ba2f7c41b36bf40 (diff) | |
download | linux-2591c280c375c547022eb619895c1aebbbc38219.tar.xz |
qed: Remove OOM messages
These messages are unnecessary as OOM allocation failures already do
a dump_stack() giving more or less the same information.
$ size drivers/net/ethernet/qlogic/qed/built-in.o* (defconfig x86-64)
text data bss dec hex filename
127817 27969 32800 188586 2e0aa drivers/net/ethernet/qlogic/qed/built-in.o.new
132474 27969 32800 193243 2f2db drivers/net/ethernet/qlogic/qed/built-in.o.old
Miscellanea:
o Change allocs to the generally preferred forms where possible.
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/qlogic/qed/qed_hw.c')
-rw-r--r-- | drivers/net/ethernet/qlogic/qed/qed_hw.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/net/ethernet/qlogic/qed/qed_hw.c b/drivers/net/ethernet/qlogic/qed/qed_hw.c index 8ebdc79b3850..6e4fae9b1430 100644 --- a/drivers/net/ethernet/qlogic/qed/qed_hw.c +++ b/drivers/net/ethernet/qlogic/qed/qed_hw.c @@ -482,28 +482,22 @@ int qed_dmae_info_alloc(struct qed_hwfn *p_hwfn) *p_comp = dma_alloc_coherent(&p_hwfn->cdev->pdev->dev, sizeof(u32), p_addr, GFP_KERNEL); - if (!*p_comp) { - DP_NOTICE(p_hwfn, "Failed to allocate `p_completion_word'\n"); + if (!*p_comp) goto err; - } p_addr = &p_hwfn->dmae_info.dmae_cmd_phys_addr; *p_cmd = dma_alloc_coherent(&p_hwfn->cdev->pdev->dev, sizeof(struct dmae_cmd), p_addr, GFP_KERNEL); - if (!*p_cmd) { - DP_NOTICE(p_hwfn, "Failed to allocate `struct dmae_cmd'\n"); + if (!*p_cmd) goto err; - } p_addr = &p_hwfn->dmae_info.intermediate_buffer_phys_addr; *p_buff = dma_alloc_coherent(&p_hwfn->cdev->pdev->dev, sizeof(u32) * DMAE_MAX_RW_SIZE, p_addr, GFP_KERNEL); - if (!*p_buff) { - DP_NOTICE(p_hwfn, "Failed to allocate `intermediate_buffer'\n"); + if (!*p_buff) goto err; - } p_hwfn->dmae_info.channel = p_hwfn->rel_pf_id; |