mbox series

[net-next,0/8] net: rps: misc changes

Message ID 20240328170309.2172584-1-edumazet@google.com (mailing list archive)
Headers show
Series net: rps: misc changes | expand

Message

Eric Dumazet March 28, 2024, 5:03 p.m. UTC
Make RPS/RFS a bit more efficient with better cache locality
and heuristics.

Aso shrink include/linux/netdevice.h a bit.
 
Eric Dumazet (8):
  net: move kick_defer_list_purge() to net/core/dev.h
  net: move dev_xmit_recursion() helpers to net/core/dev.h
  net: enqueue_to_backlog() change vs not running device
  net: make softnet_data.dropped an atomic_t
  net: enqueue_to_backlog() cleanup
  net: rps: change input_queue_tail_incr_save()
  net: rps: add rps_input_queue_head_add() helper
  net: rps: move received_rps field to a better location

 include/linux/netdevice.h | 38 ++------------------
 include/net/rps.h         | 28 +++++++++++++++
 net/core/dev.c            | 73 ++++++++++++++++++++++-----------------
 net/core/dev.h            | 23 ++++++++++--
 net/core/net-procfs.c     |  3 +-
 5 files changed, 95 insertions(+), 70 deletions(-)

Comments

Jakub Kicinski March 29, 2024, 5:45 a.m. UTC | #1
On Thu, 28 Mar 2024 17:03:01 +0000 Eric Dumazet wrote:
> Make RPS/RFS a bit more efficient with better cache locality
> and heuristics.
> 
> Aso shrink include/linux/netdevice.h a bit.

Looks like it breaks kunit build:

../net/core/dev.c: In function ‘enqueue_to_backlog’:
../net/core/dev.c:4829:24: error: implicit declaration of function ‘rps_input_queue_tail_incr’ [-Werror=implicit-function-declaration]
 4829 |                 tail = rps_input_queue_tail_incr(sd);
      |                        ^~~~~~~~~~~~~~~~~~~~~~~~~
../net/core/dev.c:4833:17: error: implicit declaration of function ‘rps_input_queue_tail_save’ [-Werror=implicit-function-declaration]
 4833 |                 rps_input_queue_tail_save(qtail, tail);
      |                 ^~~~~~~~~~~~~~~~~~~~~~~~~
../net/core/dev.c: In function ‘flush_backlog’:
../net/core/dev.c:5911:25: error: implicit declaration of function ‘rps_input_queue_head_incr’ [-Werror=implicit-function-declaration]
 5911 |                         rps_input_queue_head_incr(sd);
      |                         ^~~~~~~~~~~~~~~~~~~~~~~~~
../net/core/dev.c: In function ‘process_backlog’:
../net/core/dev.c:6049:33: error: implicit declaration of function ‘rps_input_queue_head_add’ [-Werror=implicit-function-declaration]
 6049 |                                 rps_input_queue_head_add(sd, work);
      |                                 ^~~~~~~~~~~~~~~~~~~~~~~~
Eric Dumazet March 29, 2024, 6:44 a.m. UTC | #2
On Fri, Mar 29, 2024 at 6:45 AM Jakub Kicinski <kuba@kernel.org> wrote:
>
> On Thu, 28 Mar 2024 17:03:01 +0000 Eric Dumazet wrote:
> > Make RPS/RFS a bit more efficient with better cache locality
> > and heuristics.
> >
> > Aso shrink include/linux/netdevice.h a bit.
>
> Looks like it breaks kunit build:
>
> ../net/core/dev.c: In function ‘enqueue_to_backlog’:
> ../net/core/dev.c:4829:24: error: implicit declaration of function ‘rps_input_queue_tail_incr’ [-Werror=implicit-function-declaration]
>  4829 |                 tail = rps_input_queue_tail_incr(sd);
>       |                        ^~~~~~~~~~~~~~~~~~~~~~~~~
> ../net/core/dev.c:4833:17: error: implicit declaration of function ‘rps_input_queue_tail_save’ [-Werror=implicit-function-declaration]
>  4833 |                 rps_input_queue_tail_save(qtail, tail);
>       |                 ^~~~~~~~~~~~~~~~~~~~~~~~~
> ../net/core/dev.c: In function ‘flush_backlog’:
> ../net/core/dev.c:5911:25: error: implicit declaration of function ‘rps_input_queue_head_incr’ [-Werror=implicit-function-declaration]
>  5911 |                         rps_input_queue_head_incr(sd);
>       |                         ^~~~~~~~~~~~~~~~~~~~~~~~~
> ../net/core/dev.c: In function ‘process_backlog’:
> ../net/core/dev.c:6049:33: error: implicit declaration of function ‘rps_input_queue_head_add’ [-Werror=implicit-function-declaration]
>  6049 |                                 rps_input_queue_head_add(sd, work);
>       |                                 ^~~~~~~~~~~~~~~~~~~~~~~~

Oh right, I need to define rps_input_queue_tail_incr() and friends
outside of the #ifdef CONFIG_RPS