Skip to content

netconsole: validate a target's IP address configuration

Gustavo Luiz Duarte linux-doc lkml netdev 4 versions – Applied

Status from this message: This series was applied to netdev/net-next.git (main)

Get series with b4
b4 am [email protected] change-id 20260730-netcons_ipv6-565d55f55729

Versions newest first

  1. v4 Latest7 patches 1 replyApplied 7/7
  2. v37 patches 3 repliesSuperseded
  3. v26 patches 6 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v14 patches7 repliesSuperseded

Changes in v4 from the cover letter

- No changes, just reposting post merge window close.
- Link to v3: https://patch.msgid.link/[email protected]

Patches in v4 All 7 applied

#Subject and filesSizeRepliesApplied
1/7netconsole: add an address family to struct inet_addrdrivers/net/netconsole.c include/linux/netpoll.h+22 -120 repliesApplied
2/7netconsole: use the address family instead of the ipv6 flagdrivers/net/netconsole.c+23 -590 repliesApplied
3/7netconsole: reject enabling a target with no remote IP addressdrivers/net/netconsole.c+5 -00 repliesApplied
4/7netconsole: reject a target mixing IPv4 and IPv6 addressesdrivers/net/netconsole.c+6 -01 replyApplied
5/7netconsole: show empty string for an unset IP addressdrivers/net/netconsole.c+10 -20 repliesApplied
6/7netconsole: move struct inet_addr into netconsole.cdrivers/net/netconsole.c include/linux/netpoll.h+9 -90 repliesApplied
7/7docs: netconsole: document local_ip auto-selectionDocumentation/networking/netconsole.rst+5 -00 repliesApplied

Reviews trailers per patch

All 7 patches have a Reviewed-by or Acked-by.

PatchBreno Leitao
1/7R-b
2/7R-b
3/7R-b
4/7R-b
5/7R-b
6/7R-b
7/7R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v4 thread

Cover letter [PATCH net-next v4 0/7] netconsole: validate a target's IP address configuration

This series adds two validations to the target configuration when the user tries to enable it: first whether remote_ip was set, and second whether local_ip and remote_ip address families match. Refuse to enable the target if any of those validations fail.

These validations are already done for the target passed on the command-line, so this aligns dynamic targets with the command-line behavior.

The first two patches replace the per-target 'ipv6' flag with a per-address 'family' field, which makes it easier to detect these error conditions. Patches 3 and 4 implement the actual validations.

Patches 5-7 are follow-ups from previous reviews: move inet_addr from netpoll.h into netconsole.c, show an unset address as an empty string rather than "0.0.0.0", document local_ip auto-selection.

---
Changes in v4:
- No changes, just reposting post merge window close.
- Link to v3: https://patch.msgid.link/[email protected]

Changes in v3:
- Document local_ip auto-selection
- Link to v2: https://patch.msgid.link/[email protected]

Changes in v2:
- Show empty string in configfs for an unset IP address
- Moved inet_addr definition from netpoll.h to netconsole.c
- Moved address checks out of rtnl_lock()
- Link to v1: https://patch.msgid.link/[email protected]

To: Breno Leitao <[email protected]>
To: Andrew Lunn <[email protected]>
To: "David S. Miller" <[email protected]>
To: Eric Dumazet <[email protected]>
To: Jakub Kicinski <[email protected]>
To: Paolo Abeni <[email protected]>
To: Simon Horman <[email protected]>
To: Jonathan Corbet <[email protected]>
To: Shuah Khan <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]

---
Gustavo Luiz Duarte (7):
netconsole: add an address family to struct inet_addr
netconsole: use the address family instead of the ipv6 flag
netconsole: reject enabling a target with no remote IP address
netconsole: reject a target mixing IPv4 and IPv6 addresses
netconsole: show empty string for an unset IP address
netconsole: move struct inet_addr into netconsole.c
docs: netconsole: document local_ip auto-selection

 Documentation/networking/netconsole.rst |   5 ++
 drivers/net/netconsole.c                | 132 ++++++++++++++++----------------
 include/linux/netpoll.h                 |   5 --
 3 files changed, 70 insertions(+), 72 deletions(-)

---
base-commit: 7042c8c193e5d634198b7c766bb3a01c8e3ee0e2
change-id: 20260730-netcons_ipv6-565d55f55729

Best regards,

Signature · 1 line
Gustavo Luiz Duarte <[email protected]>