Re: [PATCH] net: sched: Fix potential infinite loop

2021-04-07 Thread Davide Caratti
hello Colin, and thanks for your patch! On Wed, 2021-04-07 at 17:38 +0100, Colin King wrote: > From: Colin Ian King > > The for-loop iterates with a u16 loop counter idx and compares this > with the loop upper limit of q->flows_cnt that is a u32 type. the value of 'flows_cnt' has 65535 as an up

[PATCH] net: sched: Fix potential infinite loop

2021-04-07 Thread Colin King
From: Colin Ian King The for-loop iterates with a u16 loop counter idx and compares this with the loop upper limit of q->flows_cnt that is a u32 type. There is a potential infinite loop if q->flows_cnt is larger than the u8 loop counter. Fix this by making the loop counter the same type as q->flo