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

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
......@@ -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)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment