diff options
author | Sathya Perla <sathya.perla@emulex.com> | 2013-02-12 18:05:19 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-02-13 13:52:55 -0500 |
commit | 9e9ff4b766e25624198b623fe3eda0b3e6c669cd (patch) | |
tree | 9a00f42e0dab442195e7ca290adc7678d18099d3 /drivers | |
parent | 79876e0394aa46e74267a5871c4f4469544dcacf (diff) |
be2net: remove BUG_ON() in be_mcc_compl_is_new()
The current code expects that the last word (with valid bit)
of an MCC compl is DMAed in one shot. This may not be the case.
Remove this assertion.
Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ethernet/emulex/benet/be_cmds.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/drivers/net/ethernet/emulex/benet/be_cmds.c b/drivers/net/ethernet/emulex/benet/be_cmds.c index 8b04880ee05d..071aea79d218 100644 --- a/drivers/net/ethernet/emulex/benet/be_cmds.c +++ b/drivers/net/ethernet/emulex/benet/be_cmds.c | |||
@@ -93,13 +93,16 @@ static void be_mcc_notify(struct be_adapter *adapter) | |||
93 | * little endian) */ | 93 | * little endian) */ |
94 | static inline bool be_mcc_compl_is_new(struct be_mcc_compl *compl) | 94 | static inline bool be_mcc_compl_is_new(struct be_mcc_compl *compl) |
95 | { | 95 | { |
96 | u32 flags; | ||
97 | |||
96 | if (compl->flags != 0) { | 98 | if (compl->flags != 0) { |
97 | compl->flags = le32_to_cpu(compl->flags); | 99 | flags = le32_to_cpu(compl->flags); |
98 | BUG_ON((compl->flags & CQE_FLAGS_VALID_MASK) == 0); | 100 | if (flags & CQE_FLAGS_VALID_MASK) { |
99 | return true; | 101 | compl->flags = flags; |
100 | } else { | 102 | return true; |
101 | return false; | 103 | } |
102 | } | 104 | } |
105 | return false; | ||
103 | } | 106 | } |
104 | 107 | ||
105 | /* Need to reset the entire word that houses the valid bit */ | 108 | /* Need to reset the entire word that houses the valid bit */ |