diff options
| author | Ben Hutchings <bhutchings@solarflare.com> | 2012-09-11 13:25:13 -0400 |
|---|---|---|
| committer | Ben Hutchings <bhutchings@solarflare.com> | 2012-11-30 19:26:11 -0500 |
| commit | bbec969b7f57a6ab5683145b99da869f99080e2a (patch) | |
| tree | 2474715e0ccabcd8cb0b5573b00e36a737d00cf9 | |
| parent | b8e0251730775cc970d2453dedd454b8ae071dd9 (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>
| -rw-r--r-- | drivers/net/ethernet/sfc/mcdi.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/sfc/mcdi.c b/drivers/net/ethernet/sfc/mcdi.c index aea43cbd0520..e1967fbad161 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) | |||
| 1216 | 1216 | ||
| 1217 | rc = efx_mcdi_rpc(efx, MC_CMD_FLUSH_RX_QUEUES, (u8 *)qid, | 1217 | rc = efx_mcdi_rpc(efx, MC_CMD_FLUSH_RX_QUEUES, (u8 *)qid, |
| 1218 | count * sizeof(*qid), NULL, 0, NULL); | 1218 | count * sizeof(*qid), NULL, 0, NULL); |
| 1219 | WARN_ON(rc > 0); | 1219 | WARN_ON(rc < 0); |
| 1220 | 1220 | ||
| 1221 | kfree(qid); | 1221 | kfree(qid); |
| 1222 | 1222 | ||
