The indexes into the ring buffer are always incremented, and
the entry is accessed via doing a modulo to find the "real" index.
Modulo is an expensive operation.
This patch replaces the modulo with a simple if clamp.
It helps improve stmmac RX path as it's being called inside RX loop.
Signed-off-
On 12/10/2015 6:11 AM, Giuseppe CAVALLARO wrote:
On 12/9/2015 6:21 PM, David Laight wrote:
From: Giuseppe Cavallaro
Sent: 09 December 2015 08:38
The indexes into the ring buffer are always incremented, and
the entry is accessed via doing a modulo to find the "real" index.
Modulo is an expensive
On 12/9/2015 6:21 PM, David Laight wrote:
From: Giuseppe Cavallaro
Sent: 09 December 2015 08:38
The indexes into the ring buffer are always incremented, and
the entry is accessed via doing a modulo to find the "real" index.
Modulo is an expensive operation.
This patch replaces the modulo with a
From: Giuseppe Cavallaro
> Sent: 09 December 2015 08:38
> The indexes into the ring buffer are always incremented, and
> the entry is accessed via doing a modulo to find the "real" index.
> Modulo is an expensive operation.
>
> This patch replaces the modulo with a simple if clamp.
> It helps impr
The indexes into the ring buffer are always incremented, and
the entry is accessed via doing a modulo to find the "real" index.
Modulo is an expensive operation.
This patch replaces the modulo with a simple if clamp.
It helps improve stmmac RX path as it's being called inside RX loop.
Signed-off-