All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Kicinski <kuba@kernel.org>
To: davem@davemloft.net
Cc: netdev@vger.kernel.org, kernel-team@fb.com,
	johannes@sipsolutions.net, jiri@resnulli.us, andrew@lunn.ch,
	mkubecek@suse.cz, Jakub Kicinski <kuba@kernel.org>
Subject: [PATCH net-next 0/6] ethtool: allow dumping policies to user space
Date: Mon,  5 Oct 2020 08:57:47 -0700	[thread overview]
Message-ID: <20201005155753.2333882-1-kuba@kernel.org> (raw)

Hi!

This series wires up ethtool policies to ops, so they can be
dumped to user space for feature discovery.

First two patches wire up GET, third patch wires up SET.

Next - take care of linking up nested policies for the header
(which is what we actually care about right now). And once header
policy is linked make sure that attribute range validation is
done by policy, not code conditions for flags. New type of
policy is needed to validate masks (patch 5).

Netlink as always staying a step ahead of all the other kernel
API interfaces :)

Jakub Kicinski (6):
  ethtool: wire up get policies to ops
  ethtool: use the attributes parsed by the core in get commands
  ethtool: wire up set policies to ops
  ethtool: link up ethnl_header_policy as a nested policy
  netlink: add mask validation
  ethtool: specify which header flags are supported per command

 include/net/netlink.h        |  11 ++++
 include/uapi/linux/netlink.h |   2 +
 lib/nlattr.c                 |  36 ++++++++++
 net/ethtool/cabletest.c      |  30 +++------
 net/ethtool/channels.c       |  22 +++----
 net/ethtool/coalesce.c       |  22 +++----
 net/ethtool/debug.c          |  20 ++----
 net/ethtool/eee.c            |  21 +++---
 net/ethtool/features.c       |  22 +++----
 net/ethtool/linkinfo.c       |  22 +++----
 net/ethtool/linkmodes.c      |  22 +++----
 net/ethtool/linkstate.c      |   8 +--
 net/ethtool/netlink.c        | 123 +++++++++++++++++++++++++----------
 net/ethtool/netlink.h        |  33 +++++++++-
 net/ethtool/pause.c          |  19 ++----
 net/ethtool/privflags.c      |  22 +++----
 net/ethtool/rings.c          |  20 ++----
 net/ethtool/strset.c         |   6 +-
 net/ethtool/tsinfo.c         |   7 +-
 net/ethtool/tunnels.c        |  42 +++++-------
 net/ethtool/wol.c            |  19 ++----
 net/netlink/policy.c         |   8 +++
 22 files changed, 303 insertions(+), 234 deletions(-)

-- 
2.26.2


             reply	other threads:[~2020-10-05 15:58 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-05 15:57 Jakub Kicinski [this message]
2020-10-05 15:57 ` [PATCH net-next 1/6] ethtool: wire up get policies to ops Jakub Kicinski
2020-10-05 18:56   ` Johannes Berg
2020-10-05 19:16     ` Jakub Kicinski
2020-10-05 19:21       ` Johannes Berg
2020-10-05 19:31         ` Jakub Kicinski
2020-10-05 19:33           ` Johannes Berg
2020-10-05 19:41             ` Jakub Kicinski
2020-10-05 19:46               ` Johannes Berg
2020-10-05 19:51                 ` Jakub Kicinski
2020-10-05 21:52             ` Jacob Keller
2020-10-05 21:33           ` Jacob Keller
2020-10-05 15:57 ` [PATCH net-next 2/6] ethtool: use the attributes parsed by the core in get commands Jakub Kicinski
2020-10-05 15:57 ` [PATCH net-next 3/6] ethtool: wire up set policies to ops Jakub Kicinski
2020-10-05 15:57 ` [PATCH net-next 4/6] ethtool: link up ethnl_header_policy as a nested policy Jakub Kicinski
2020-10-05 15:57 ` [PATCH net-next 5/6] netlink: add mask validation Jakub Kicinski
2020-10-05 19:05   ` Johannes Berg
2020-10-05 19:22     ` Jakub Kicinski
2020-10-05 19:25       ` Johannes Berg
2020-10-05 19:34         ` Jakub Kicinski
2020-10-05 19:37           ` Johannes Berg
2020-10-05 19:47           ` Michal Kubecek
2020-10-05 19:28     ` Michal Kubecek
2020-10-05 19:31       ` Johannes Berg
2020-10-05 19:40         ` Jakub Kicinski
2020-10-05 19:53           ` Johannes Berg
2020-10-05 20:12             ` Johannes Berg
2020-10-05 22:21               ` Jakub Kicinski
2020-10-06  6:37                 ` Johannes Berg
2020-10-06 11:52                   ` Johannes Berg
2020-10-05 15:57 ` [PATCH net-next 6/6] ethtool: specify which header flags are supported per command Jakub Kicinski
2020-10-05 18:58   ` Johannes Berg
2020-10-05 19:25     ` Jakub Kicinski
2020-10-05 19:28       ` Johannes Berg

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=20201005155753.2333882-1-kuba@kernel.org \
    --to=kuba@kernel.org \
    --cc=andrew@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=jiri@resnulli.us \
    --cc=johannes@sipsolutions.net \
    --cc=kernel-team@fb.com \
    --cc=mkubecek@suse.cz \
    --cc=netdev@vger.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.