]> git.baikalelectronics.ru Git - kernel.git/commit
net: bcmgenet: cleanup ring interrupt masking and unmasking
authorDoug Berger <opendmb@gmail.com>
Wed, 25 Oct 2017 22:04:15 +0000 (15:04 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 26 Oct 2017 01:14:54 +0000 (10:14 +0900)
commite7f3efd1122ed3c3f95c14081965ab3fc17ab951
tree3b3be30beed4377e998341f84572375decd30253
parentda2fe94f89f76129a9b0c52988de13bd46400d5a
net: bcmgenet: cleanup ring interrupt masking and unmasking

Since the NAPI interrupts are basically ignored when NAPI is
disabled we don't need to mask them within the functions
bcmgenet_disable_tx_napi() and bcmgenet_disable_rx_napi().
So wait until all NAPI instances are disabled and mask all of the
bcmgenet driver interrupts together in bcmgenet_netif_stop().

The interrupts can still be enabled in the functions
bcmgenet_enable_tx_napi() and bcmgenet_enable_rx_napi(), but use
the ring context int_enable() method to keep the functionality
consistent and the code cleaner.

Signed-off-by: Doug Berger <opendmb@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/genet/bcmgenet.c