Re: [PATCH net] sfc: fix ef100 design-param checking

2020-08-12 Thread David Miller
From: Edward Cree Date: Wed, 12 Aug 2020 10:32:49 +0100 > The handling of the RXQ/TXQ size granularity design-params had two > problems: it had a 64-bit divide that didn't build on 32-bit platforms, > and it could divide by zero if the NIC supplied 0 as the value of the > design-param. Fix bo

Re: [PATCH net] sfc: fix ef100 design-param checking

2020-08-12 Thread Guenter Roeck
On Wed, Aug 12, 2020 at 10:32:49AM +0100, Edward Cree wrote: > The handling of the RXQ/TXQ size granularity design-params had two > problems: it had a 64-bit divide that didn't build on 32-bit platforms, > and it could divide by zero if the NIC supplied 0 as the value of the > design-param. Fix

[PATCH net] sfc: fix ef100 design-param checking

2020-08-12 Thread Edward Cree
The handling of the RXQ/TXQ size granularity design-params had two problems: it had a 64-bit divide that didn't build on 32-bit platforms, and it could divide by zero if the NIC supplied 0 as the value of the design-param. Fix both by checking for 0 and for a granularity bigger than our min-si