bnx2x: Don't pretend during register dump
authorDmitry Kravkov <dmitry@broadcom.com>
Sun, 20 Oct 2013 14:51:33 +0000 (16:51 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 21 Oct 2013 22:31:36 +0000 (18:31 -0400)
commit4293b9f57a46469d6762be3300e2c3fa6515905d
treef6020068f1393722e4ed08b40033ab97d0c31c36
parent32316a46f2bbd4a898acf86547197cff8476f442
bnx2x: Don't pretend during register dump

As part of a register dump, the interface pretends to have the identity
of other interfaces of the same physical device in order to perform
HW configuration for them - specifically, it needs to prevent attentions
from generating on those functions as the register dump accesses registers
in common blocks which whose reading might generate an attention.

However, such pretension is unsafe - unlike other flows in which the driver
uses pretend, during register dump there is no guarantee no other HW access
will take place (by other flows). If such access will take place, the HW will
be accessed by the wrong interface, and leave both functions in an incorrect
state.

This patch removes all pretensions from the register dump flow. Instead, it
changes initial configuration of attentions such that no fatal attention will
be generated for other functions as a result of the register dump
(notice however, a debug print claiming an attention from other functions IS
possible during the register dump)

Signed-off-by: Dmitry Kravkov <dmitry@broadcom.com>
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Ariel Elior <ariele@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c
drivers/net/ethernet/broadcom/bnx2x/bnx2x_init.h
drivers/net/ethernet/broadcom/bnx2x/bnx2x_main.c