]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
greybus: timesync: probe shouldn't complete until FrameTime sync does
authorBryan O'Donoghue <bryan.odonoghue@linaro.org>
Wed, 20 Jul 2016 18:31:18 +0000 (19:31 +0100)
committerGreg Kroah-Hartman <gregkh@google.com>
Wed, 20 Jul 2016 19:07:35 +0000 (12:07 -0700)
Currently the probe() function contains the asynchronous() variant of
FrameTime synchronization. This patch converts to the synchronous() version
of synchronization. This is required for two reasons first a probe() cannot
reasonably be considered to be complete without successfully completing a
time synchronization for Interfaces that care about that sync. Secondly
scheduling the operation asynchronously means its possible the PM-runtime
suspend() path can execute before the async timesync operation completes.
For both reasons we want to run synchronization - synchronously.

Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
Reviewed-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
drivers/staging/greybus/core.c

index 2c94bbb1748fb2cd904db24e19f79160ee4f50ba..8c77d6cb391938b0003cca7e20c59297960f2590 100644 (file)
@@ -219,7 +219,7 @@ static int greybus_probe(struct device *dev)
                return retval;
        }
 
-       gb_timesync_schedule_asynchronous(bundle->intf);
+       gb_timesync_schedule_synchronous(bundle->intf);
 
        pm_runtime_put(&bundle->intf->dev);