From cbb7de25fe4e974fc1edf3aa907152482a120583 Mon Sep 17 00:00:00 2001 From: Thomas Schoebel-Theuer Date: Mon, 5 Jun 2017 23:18:20 +0200 Subject: [PATCH] logger: fix races on queues --- kernel/mars_trans_logger.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/kernel/mars_trans_logger.c b/kernel/mars_trans_logger.c index d675b50a..d335424f 100644 --- a/kernel/mars_trans_logger.c +++ b/kernel/mars_trans_logger.c @@ -623,14 +623,10 @@ static inline int _congested(struct trans_logger_brick *brick) { return - brick->q_phase[0].q_queued || - atomic_read(&brick->q_phase[0].q_flying) || - brick->q_phase[1].q_queued || - atomic_read(&brick->q_phase[1].q_flying) || - brick->q_phase[2].q_queued || - atomic_read(&brick->q_phase[2].q_flying) || - brick->q_phase[3].q_queued || - atomic_read(&brick->q_phase[3].q_flying); + brick->q_phase[0].q_active || + brick->q_phase[1].q_active || + brick->q_phase[2].q_active || + brick->q_phase[3].q_active; } ////////////////// own brick / input / output operations //////////////////