]> git.baikalelectronics.ru Git - kernel.git/commit
net: bcmgenet: cleanup for bcmgenet_xmit()
authorPetri Gynther <pgynther@google.com>
Tue, 5 Apr 2016 20:59:59 +0000 (13:59 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 5 Apr 2016 23:33:51 +0000 (19:33 -0400)
commit9360d2f03a53be581c08cd246180f0d9ff928c36
tree88f37125dd2f84678b3d40944b54df7a095fec8e
parent768b3804f214029b34b2186802a9c5d90f15d17e
net: bcmgenet: cleanup for bcmgenet_xmit()

1. Readability: Move nr_frags assignment a few lines down in order
   to bundle index -> ring -> txq calculations together.
2. Readability: Add parentheses around nr_frags + 1.
3. Minor fix: Stop the Tx queue and throw the error message only if
   the Tx queue hasn't already been stopped.

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