net: bcmgenet: simplify bcmgenet_init_dma()
authorPetri Gynther <pgynther@google.com>
Wed, 25 Mar 2015 19:35:11 +0000 (12:35 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 27 Mar 2015 21:26:13 +0000 (14:26 -0700)
commitebbd96fb2861f591df011cd0eac67dd367596cca
tree13f882e9dd5d369747dd07424cd8e6828246b056
parent9dbac28fc193e3972f566f120dce67d69a1df634
net: bcmgenet: simplify bcmgenet_init_dma()

Do the two kcalloc() calls first, before proceeding into Rx/Tx DMA init.
Makes the error case handling much simpler.

Signed-off-by: Petri Gynther <pgynther@google.com>
Reviewed-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Jaedon Shin <jaedon.shin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/genet/bcmgenet.c