aboutsummaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/sfc/mcdi.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2012-09-11 18:25:13 +0100
committerBen Hutchings <bhutchings@solarflare.com>2012-12-01 00:26:11 +0000
commitbbec969b7f57a6ab5683145b99da869f99080e2a (patch)
tree2474715e0ccabcd8cb0b5573b00e36a737d00cf9 /drivers/net/ethernet/sfc/mcdi.c
parentb8e0251730775cc970d2453dedd454b8ae071dd9 (diff)
sfc: Fix check for failure of MC_CMD_FLUSH_RX_QUEUES
efx_mcdi_rpc_start() returns a negative value on error or zero on success. However one caller that can't properly handle failure then does WARN_ON(rc > 0). Change it to WARN_ON(rc < 0). Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Diffstat (limited to 'drivers/net/ethernet/sfc/mcdi.c')
-rw-r--r--drivers/net/ethernet/sfc/mcdi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/sfc/mcdi.c b/drivers/net/ethernet/sfc/mcdi.c
index aea43cbd052..e1967fbad16 100644
--- a/drivers/net/ethernet/sfc/mcdi.c
+++ b/drivers/net/ethernet/sfc/mcdi.c
@@ -1216,7 +1216,7 @@ int efx_mcdi_flush_rxqs(struct efx_nic *efx)
rc = efx_mcdi_rpc(efx, MC_CMD_FLUSH_RX_QUEUES, (u8 *)qid,
count * sizeof(*qid), NULL, 0, NULL);
- WARN_ON(rc > 0);
+ WARN_ON(rc < 0);
kfree(qid);