Re: [PATCH v2 net 4/7] net/sched: taprio: get corrected value of cycle_time and interval
From: Vladimir Oltean <vladimir.oltean@nxp.com>
Date: 2023-11-09 12:01:38
Also in:
lkml
From: Vladimir Oltean <vladimir.oltean@nxp.com>
Date: 2023-11-09 12:01:38
Also in:
lkml
On Tue, Nov 07, 2023 at 06:20:20AM -0500, Faizal Rahim wrote:
@@ -215,6 +216,31 @@ static void switch_schedules(struct taprio_sched *q, *admin = NULL; } +static bool cycle_corr_active(s64 cycle_time_correction) +{ + if (cycle_time_correction == INIT_CYCLE_TIME_CORRECTION) + return false; + else + return true; +}@@ -259,14 +286,6 @@ static int duration_to_length(struct taprio_sched *q, u64 duration) return div_u64(duration * PSEC_PER_NSEC, atomic64_read(&q->picos_per_byte)); } -static bool cycle_corr_active(s64 cycle_time_correction) -{ - if (cycle_time_correction == INIT_CYCLE_TIME_CORRECTION) - return false; - else - return true; -} -
Don't move code around that you've introduced in earlier changes. Just place it where it needs to be from the beginning.