mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Oscar Maes <oscmaes92@gmail.com>
To: netdev@vger.kernel.org
Cc: davem@davemloft.net, dsahern@kernel.org, edumazet@google.com,
	kuba@kernel.org, pabeni@redhat.com, horms@kernel.org,
	shuah@kernel.org, linux-kernel@vger.kernel.org,
	Oscar Maes <oscmaes92@gmail.com>
Subject: [PATCH net-next v3 0/2] net: ipv4: allow directed broadcast routes to use dst hint
Date: Tue, 19 Aug 2025 19:46:40 +0200	[thread overview]
Message-ID: <20250819174642.5148-1-oscmaes92@gmail.com> (raw)

Currently, ip_extract_route_hint uses RTN_BROADCAST to decide
whether to use the route dst hint mechanism.

This check is too strict, as it prevents directed broadcast
routes from using the hint, resulting in poor performance
during bursts of directed broadcast traffic.

This series fixes this, and adds a new selftest to ensure
this does not regress.

Changes in v3:
 - Improved selftest
 - Use ipv4_is_zeronet to check daddr

Changes in v2:
 - Removed unused variable
 - Fixed formatting
 - Added new selftest

Link to v2: https://lore.kernel.org/netdev/20250814140309.3742-1-oscmaes92@gmail.com/

Oscar Maes (2):
  net: ipv4: allow directed broadcast routes to use dst hint
  selftests: net: add test for dst hint mechanism with directed
    broadcast addresses

 net/ipv4/ip_input.c                       | 11 ++--
 net/ipv4/route.c                          |  2 +-
 tools/testing/selftests/net/Makefile      |  1 +
 tools/testing/selftests/net/route_hint.sh | 79 +++++++++++++++++++++++
 4 files changed, 88 insertions(+), 5 deletions(-)
 create mode 100755 tools/testing/selftests/net/route_hint.sh

-- 
2.39.5


             reply	other threads:[~2025-08-19 17:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-19 17:46 Oscar Maes [this message]
2025-08-19 17:46 ` [PATCH net-next v3 1/2] " Oscar Maes
2025-08-20 14:19   ` David Ahern
2025-08-19 17:46 ` [PATCH net-next v3 2/2] selftests: net: add test for dst hint mechanism with directed broadcast addresses Oscar Maes
2025-08-25 23:30 ` [PATCH net-next v3 0/2] net: ipv4: allow directed broadcast routes to use dst hint patchwork-bot+netdevbpf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250819174642.5148-1-oscmaes92@gmail.com \
    --to=oscmaes92@gmail.com \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=shuah@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®