Commit a0ee3d3e authored by Bryan O'Donoghue's avatar Bryan O'Donoghue Committed by Greg Kroah-Hartman
Browse files

greybus: loopback: remove magic number in state-machine



Magic number 2 used instead of define GB_LOOPBACK_TYPE_PING, remove and and
use the define instead.

Signed-off-by: default avatarBryan O'Donoghue <bryan.odonoghue@linaro.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@google.com>
parent f9f971a2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -356,7 +356,7 @@ static int gb_loopback_fn(void *data)
		gb->elapsed_nsecs = timeval_to_ns(&gb->te) -
					timeval_to_ns(&gb->ts);
		gb_loopback_freq_update(gb);
		if (gb->type == 2)
		if (gb->type == GB_LOOPBACK_TYPE_PING)
			gb_loopback_bw_update(gb, error);
		gb_loopback_latency_update(gb, &tlat);
		if (gb->elapsed_nsecs >= NSEC_PER_SEC)