You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2022/09/19 14:58:08 UTC

[GitHub] [incubator-nuttx] gustavonihei commented on a diff in pull request #7135: net/wireless: add support for netdev private ioctl

gustavonihei commented on code in PR #7135:
URL: https://github.com/apache/incubator-nuttx/pull/7135#discussion_r974360437


##########
include/nuttx/wireless/wireless.h:
##########
@@ -150,6 +150,42 @@
 #define SIOCSIWPTAPRIO      _WLIOC(0x0039)  /* Set PTA priority type */
 #define SIOCGIWPTAPRIO      _WLIOC(0x003a)  /* Get PTA priority type */
 
+/* -------------------- DEV PRIVATE IOCTL LIST -------------------- */
+
+/* These 32 ioctl are wireless device private, for 16 commands.
+ * Each driver is free to use them for whatever purpose it chooses,
+ * however the driver *must* export the description of those ioctls
+ * with SIOCGIWPRIV and *must* use arguments as defined below.
+ */
+
+#define SIOCIWFIRSTPRIV     _WLIOC(0x00e0)
+#define SIOCIWLASTPRIV      _WLIOC(0x00ff)
+
+/* Previously, we were using SIOCDEVPRIVATE, but we now have our
+ * separate range because of collisions with other tools such as
+ * 'mii-tool'.
+ * We now have 32 commands, so a bit more space ;-).
+ * Also, all 'even' commands are only usable by root and don't return the
+ * content of ifr/iwr to user (but you are not obliged to use the set/get
+ * convention, just use every other two command). More details in iwpriv.c.
+ * And I repeat : you are not forced to use them with iwpriv, but you
+ * must be compliant with it.
+ */

Review Comment:
   This comment does not seem to be pertinent to this project, considering the references to `mii-tool` and `iwpriv.c`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org