projects
/
platform
/
kernel
/
linux-starfive.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d29e33d
)
sfc: allow asynchronous MCDI without completion function
author
Bert Kenward
<bkenward@solarflare.com>
Thu, 11 Aug 2016 12:01:21 +0000
(13:01 +0100)
committer
David S. Miller
<davem@davemloft.net>
Sat, 13 Aug 2016 03:42:19 +0000
(20:42 -0700)
Signed-off-by: Bert Kenward <bkenward@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/sfc/mcdi.c
patch
|
blob
|
history
diff --git
a/drivers/net/ethernet/sfc/mcdi.c
b/drivers/net/ethernet/sfc/mcdi.c
index
d28e7dd
..
9fbc12a
100644
(file)
--- a/
drivers/net/ethernet/sfc/mcdi.c
+++ b/
drivers/net/ethernet/sfc/mcdi.c
@@
-548,7
+548,10
@@
static bool efx_mcdi_complete_async(struct efx_mcdi_iface *mcdi, bool timeout)
efx_mcdi_display_error(efx, async->cmd, async->inlen, errbuf,
err_len, rc);
}
- async->complete(efx, async->cookie, rc, outbuf, data_len);
+
+ if (async->complete)
+ async->complete(efx, async->cookie, rc, outbuf,
+ min(async->outlen, data_len));
kfree(async);
efx_mcdi_release(mcdi);