[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZIm9fw1l/EM0r3Um@corigine.com>
Date: Wed, 14 Jun 2023 15:15:43 +0200
From: Simon Horman <simon.horman@...igine.com>
To: Vladimir Oltean <vladimir.oltean@....com>
Cc: netdev@...r.kernel.org, Andrew Lunn <andrew@...n.ch>,
Florian Fainelli <f.fainelli@...il.com>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>,
Claudiu Manoil <claudiu.manoil@....com>,
Alexandre Belloni <alexandre.belloni@...tlin.com>,
UNGLinuxDriver@...rochip.com,
Xiaoliang Yang <xiaoliang.yang_1@....com>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH net] net: dsa: felix: fix taprio guard band overflow at
10Mbps with jumbo frames
On Wed, Jun 14, 2023 at 03:17:59PM +0300, Vladimir Oltean wrote:
> On Wed, Jun 14, 2023 at 02:05:15PM +0200, Simon Horman wrote:
> > Reviewed-by: Simon Horman <simon.horman@...igine.com>
>
> Thanks.
>
> > In a similar vein, you may want to consider the following suggestion from
> > Coccinelle.
> >
> > .../felix_vsc9959.c:1382:2-8: WARNING: do_div() does a 64-by-32 division, please consider using div64_u64 instead.
> >
>
> Yeah, but there, there's an earlier restriction for cycle_time to never
> exceed NSEC_PER_SEC (1000000000L) which fits on 32 bits.
Thanks, understood.
> Nonetheless, it is a good reminder that there are too many disjoint
> places in the kernel already that open-code the logic to advance a
> taprio base time. It would indeed be good to consolidate all of those
> into a static inline function offered by include/net/pkt_sched.h, which
> is also warning-free.
Yes, that would be nice, now that you mention it.
Powered by blists - more mailing lists