]> git.ipfire.org Git - thirdparty/iw.git/blobdiff - iw.h
add a helper command to print command IDs
[thirdparty/iw.git] / iw.h
diff --git a/iw.h b/iw.h
index dd964c16436e46bc1255bf3b6419731f775e76ed..3e83bd2c65fc2c347b757589dcfd8e606a6ec2fc 100644 (file)
--- a/iw.h
+++ b/iw.h
@@ -6,8 +6,10 @@
 #include <netlink/genl/genl.h>
 #include <netlink/genl/family.h>
 #include <netlink/genl/ctrl.h>
+#include <endian.h>
 
 #include "nl80211.h"
+#include "ieee80211.h"
 
 #define ETH_ALEN 6
 
 
 struct nl80211_state {
        struct nl_sock *nl_sock;
-       struct nl_cache *nl_cache;
-       struct genl_family *nl80211;
+       int nl80211_id;
 };
 
 enum command_identify_by {
        CIB_NONE,
        CIB_PHY,
        CIB_NETDEV,
+       CIB_WDEV,
 };
 
 enum id_input {
@@ -33,6 +35,7 @@ enum id_input {
        II_NETDEV,
        II_PHY_NAME,
        II_PHY_IDX,
+       II_WDEV,
 };
 
 struct cmd {
@@ -51,7 +54,8 @@ struct cmd {
        int (*handler)(struct nl80211_state *state,
                       struct nl_cb *cb,
                       struct nl_msg *msg,
-                      int argc, char **argv);
+                      int argc, char **argv,
+                      enum id_input id);
        const struct cmd *(*selector)(int argc, char **argv);
        const struct cmd *parent;
 };
@@ -139,6 +143,7 @@ void print_ht_mcs(const __u8 *mcs);
 void print_ampdu_length(__u8 exponent);
 void print_ampdu_spacing(__u8 spacing);
 void print_ht_capability(__u16 cap);
+void print_vht_info(__u32 capa, const __u8 *mcs);
 
 const char *iftype_name(enum nl80211_iftype iftype);
 const char *command_name(enum nl80211_commands cmd);