From: Pranavi Somisetty <pranavi.somisetty@amd.com>
To: <davem@davemloft.net>, <edumazet@google.com>, <kuba@kernel.org>,
<pabeni@redhat.com>
Cc: <git@amd.com>, <pranavi.somisetty@amd.com>,
<harini.katakam@amd.com>, <radhey.shyam.pandey@amd.com>,
<michal.simek@amd.com>, <linux-kernel@vger.kernel.org>,
<netdev@vger.kernel.org>
Subject: [RFC PATCH net-next 1/2] include: uapi: Add new ioctl definitions to support Frame Preemption
Date: Thu, 3 Nov 2022 05:33:47 -0600 [thread overview]
Message-ID: <20221103113348.17378-2-pranavi.somisetty@amd.com> (raw)
In-Reply-To: <20221103113348.17378-1-pranavi.somisetty@amd.com>
Add new ioctl definitions, SIOC_PREEMPTION_EN, SIOC_PREEMPTION_CTRL,
SIOC_PREEMPTION_STS, SIOC_PREEMPTION_COUNTER, to support IEEE 802.3br.
Signed-off-by: Pranavi Somisetty <pranavi.somisetty@amd.com>
---
include/uapi/linux/sockios.h | 6 ++++++
net/core/dev_ioctl.c | 6 +++++-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/include/uapi/linux/sockios.h b/include/uapi/linux/sockios.h
index 7d1bccbbef78..382f959fb371 100644
--- a/include/uapi/linux/sockios.h
+++ b/include/uapi/linux/sockios.h
@@ -153,6 +153,12 @@
#define SIOCSHWTSTAMP 0x89b0 /* set and get config */
#define SIOCGHWTSTAMP 0x89b1 /* get config */
+/* Frame Preemption, IEEE 802.3br */
+#define SIOC_PREEMPTION_EN 0x89b2 /* enable frame preemption */
+#define SIOC_PREEMPTION_CTRL 0x89b3 /* configure preemption parameters */
+#define SIOC_PREEMPTION_STS 0x89b4 /* get preemption status */
+#define SIOC_PREEMPTION_COUNTER 0x89b5 /* read preemption statistics */
+
/* Device private ioctl calls */
/*
diff --git a/net/core/dev_ioctl.c b/net/core/dev_ioctl.c
index 7674bb9f3076..46fb963cd13a 100644
--- a/net/core/dev_ioctl.c
+++ b/net/core/dev_ioctl.c
@@ -409,7 +409,11 @@ static int dev_ifsioc(struct net *net, struct ifreq *ifr, void __user *data,
cmd == SIOCGMIIREG ||
cmd == SIOCSMIIREG ||
cmd == SIOCSHWTSTAMP ||
- cmd == SIOCGHWTSTAMP) {
+ cmd == SIOCGHWTSTAMP ||
+ cmd == SIOC_PREEMPTION_EN ||
+ cmd == SIOC_PREEMPTION_CTRL ||
+ cmd == SIOC_PREEMPTION_STS ||
+ cmd == SIOC_PREEMPTION_COUNTER) {
err = dev_eth_ioctl(dev, ifr, cmd);
} else if (cmd == SIOCBONDENSLAVE ||
cmd == SIOCBONDRELEASE ||
--
2.36.1
next prev parent reply other threads:[~2022-11-03 11:34 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-03 11:33 [RFC PATCH net-next 0/2] Add support for Frame preemption (IEEE Pranavi Somisetty
2022-11-03 11:33 ` Pranavi Somisetty [this message]
2022-11-03 22:11 ` [RFC PATCH net-next 1/2] include: uapi: Add new ioctl definitions to support Frame Preemption Andrew Lunn
2022-11-03 11:33 ` [RFC PATCH net-next 2/2] include: uapi: Add Frame preemption parameters Pranavi Somisetty
2022-11-03 22:51 ` [RFC PATCH net-next 0/2] Add support for Frame preemption (IEEE Vladimir Oltean
2022-11-04 14:08 ` Somisetty, Pranavi
2022-11-04 15:52 ` Vladimir Oltean
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=20221103113348.17378-2-pranavi.somisetty@amd.com \
--to=pranavi.somisetty@amd.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=git@amd.com \
--cc=harini.katakam@amd.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=michal.simek@amd.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=radhey.shyam.pandey@amd.com \
/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;
as well as URLs for NNTP newsgroup(s).