Procházet zdrojové kódy

sfc: Fix sign of efx_mcdi_poll_reboot() error in efx_mcdi_poll()

efx_mcdi_poll() uses positive error numbers, matching the MCDI
protocol.  It must negate the result of efx_mcdi_poll_reboot() which
returns the usual negative error numbers.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Ben Hutchings před 15 roky
rodič
revize
e0bf54c93a
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      drivers/net/sfc/mcdi.c

+ 1 - 1
drivers/net/sfc/mcdi.c

@@ -127,7 +127,7 @@ static int efx_mcdi_poll(struct efx_nic *efx)
 	efx_dword_t reg;
 	efx_dword_t reg;
 
 
 	/* Check for a reboot atomically with respect to efx_mcdi_copyout() */
 	/* Check for a reboot atomically with respect to efx_mcdi_copyout() */
-	rc = efx_mcdi_poll_reboot(efx);
+	rc = -efx_mcdi_poll_reboot(efx);
 	if (rc)
 	if (rc)
 		goto out;
 		goto out;