lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20221103113348.17378-2-pranavi.somisetty@amd.com>
Date:   Thu, 3 Nov 2022 05:33:47 -0600
From:   Pranavi Somisetty <pranavi.somisetty@....com>
To:     <davem@...emloft.net>, <edumazet@...gle.com>, <kuba@...nel.org>,
        <pabeni@...hat.com>
CC:     <git@....com>, <pranavi.somisetty@....com>,
        <harini.katakam@....com>, <radhey.shyam.pandey@....com>,
        <michal.simek@....com>, <linux-kernel@...r.kernel.org>,
        <netdev@...r.kernel.org>
Subject: [RFC PATCH net-next 1/2] include: uapi: Add new ioctl definitions to support Frame Preemption

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@....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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ