mbox series

[v3,net-next,0/2] net: dsa: mv88e6xxx: Improve indirect addressing performance

Message ID 20220128162650.2510062-1-tobias@waldekranz.com (mailing list archive)
Headers show
Series net: dsa: mv88e6xxx: Improve indirect addressing performance | expand

Message

Tobias Waldekranz Jan. 28, 2022, 4:26 p.m. UTC
The individual patches have all the details. This work was triggered
by recent work on a platform that took 16s (sic) to load the mv88e6xxx
module.

The first patch gets rid of most of that time by replacing a very long
delay with a tighter poll loop to wait for the busy bit to clear.

The second patch shaves off some more time by avoiding redundant
busy-bit-checks, saving 1 out of 4 MDIO operations for every register
read/write in the optimal case.

v1 -> v2:
- Make sure that we always poll the busy bit at least twice, in the
  unlikely event that the first one is quick to query the hardware,
  but is then scheduled out for a long time before the timeout is
  checked.

v2 -> v3:
- Fallback to the longer sleeps after the initial two poll attempts.

Tobias Waldekranz (2):
  net: dsa: mv88e6xxx: Improve performance of busy bit polling
  net: dsa: mv88e6xxx: Improve indirect addressing performance

 drivers/net/dsa/mv88e6xxx/chip.c | 13 +++++++++---
 drivers/net/dsa/mv88e6xxx/chip.h |  1 +
 drivers/net/dsa/mv88e6xxx/smi.c  | 35 +++++++++++++++++++++-----------
 3 files changed, 34 insertions(+), 15 deletions(-)

Comments

patchwork-bot+netdevbpf@kernel.org Jan. 31, 2022, 11:40 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (master)
by David S. Miller <davem@davemloft.net>:

On Fri, 28 Jan 2022 17:26:48 +0100 you wrote:
> The individual patches have all the details. This work was triggered
> by recent work on a platform that took 16s (sic) to load the mv88e6xxx
> module.
> 
> The first patch gets rid of most of that time by replacing a very long
> delay with a tighter poll loop to wait for the busy bit to clear.
> 
> [...]

Here is the summary with links:
  - [v3,net-next,1/2] net: dsa: mv88e6xxx: Improve performance of busy bit polling
    https://git.kernel.org/netdev/net-next/c/35da1dfd9484
  - [v3,net-next,2/2] net: dsa: mv88e6xxx: Improve indirect addressing performance
    https://git.kernel.org/netdev/net-next/c/7bca16b22e6a

You are awesome, thank you!