Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 640d9b42 authored by Clemens Ladisch's avatar Clemens Ladisch
Browse files

ALSA: dice: check clock change timeout



Output a warning if the wait for the clock change notification times
out.

Signed-off-by: default avatarClemens Ladisch <clemens@ladisch.de>
parent 4edeb831
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -551,8 +551,9 @@ static int dice_change_rate(struct dice *dice, unsigned int clock_rate)
	if (err < 0)
		return err;

	wait_for_completion_timeout(&dice->clock_accepted,
				    msecs_to_jiffies(100));
	if (!wait_for_completion_timeout(&dice->clock_accepted,
					 msecs_to_jiffies(100)))
		dev_warn(&dice->unit->device, "clock change timed out\n");

	return 0;
}