From: Shreyas NC Date: Fri, 27 Jul 2018 09:14:12 +0000 (+0530) Subject: soundwire: Initialize completion for defer messages X-Git-Tag: v4.20-rc1~107^2~67^2~9 X-Git-Url: https://git.kernel.dk/?a=commitdiff_plain;h=a306a0e4a5326269b6c78d136407f08433ab5ece;p=linux-block.git soundwire: Initialize completion for defer messages Deferred messages are async messages used to synchronize transitions mostly while doing a bank switch on multi links. On successful transitions these messages are marked complete and thereby confirming that all the buses performed bank switch successfully. So, initialize the completion structure for the same. Signed-off-by: Sanyog Kale Signed-off-by: Shreyas NC Acked-by: Pierre-Louis Bossart Signed-off-by: Vinod Koul --- diff --git a/drivers/soundwire/bus.c b/drivers/soundwire/bus.c index dcc0ff9f0c22..dbabd5e69343 100644 --- a/drivers/soundwire/bus.c +++ b/drivers/soundwire/bus.c @@ -175,6 +175,7 @@ static inline int do_transfer_defer(struct sdw_bus *bus, defer->msg = msg; defer->length = msg->len; + init_completion(&defer->complete); for (i = 0; i <= retry; i++) { resp = bus->ops->xfer_msg_defer(bus, msg, defer);