![](https://seccdn.libravatar.org/avatar/128a7b98d536a9cf9b4d4d5a90d63475.jpg?s=120&d=mm&r=g)
Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package iw for openSUSE:Factory checked in at 2024-06-07 15:01:56 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/iw (Old) and /work/SRC/openSUSE:Factory/.iw.new.24587 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "iw" Fri Jun 7 15:01:56 2024 rev:39 rq:1179153 version:6.9 Changes: -------- --- /work/SRC/openSUSE:Factory/iw/iw.changes 2024-01-04 15:57:00.811677309 +0100 +++ /work/SRC/openSUSE:Factory/.iw.new.24587/iw.changes 2024-06-07 15:02:03.736921428 +0200 @@ -1,0 +2,13 @@ +Fri Jun 7 08:22:32 UTC 2024 - Martin Pluskal <mpluskal@suse.com> + +- Update to version 6.9: + * iw: remove sizer section and related code + * util: clarify comment about 'parsed' pointer + * iw: add puncturing support + * iw: refactor frequency help + * bump version to 6.9 + * channel: report punctured subchannel bitmap + * wowlan: add a wake event + * update nl80211.h + +------------------------------------------------------------------- Old: ---- iw-6.7.obscpio New: ---- iw-6.9.obscpio ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ iw.spec ++++++ --- /var/tmp/diff_new_pack.EX3zZY/_old 2024-06-07 15:02:04.512949699 +0200 +++ /var/tmp/diff_new_pack.EX3zZY/_new 2024-06-07 15:02:04.516949845 +0200 @@ -17,7 +17,7 @@ Name: iw -Version: 6.7 +Version: 6.9 Release: 0 Summary: Configuration utility for nl80211 based wireless drivers License: ISC ++++++ _servicedata ++++++ --- /var/tmp/diff_new_pack.EX3zZY/_old 2024-06-07 15:02:04.572951885 +0200 +++ /var/tmp/diff_new_pack.EX3zZY/_new 2024-06-07 15:02:04.572951885 +0200 @@ -1,6 +1,6 @@ <servicedata> <service name="tar_scm"> <param name="url">https://git.kernel.org/pub/scm/linux/kernel/git/jberg/iw.git</param> - <param name="changesrevision">c49eb9ee6847953b24ba265add49fa4ec587c7a8</param></service></servicedata> + <param name="changesrevision">8609336b71a8ae37238dc3f4ddff251a4698a4fc</param></service></servicedata> (No newline at EOF) ++++++ iw-6.7.obscpio -> iw-6.9.obscpio ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/ap.c new/iw-6.9/ap.c --- old/iw-6.7/ap.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/ap.c 2024-06-05 13:46:13.000000000 +0200 @@ -144,12 +144,14 @@ nla_put_failure: return -ENOSPC; } -COMMAND(ap, start, "", - NL80211_CMD_NEW_BEACON, 0, CIB_NETDEV, handle_start_ap, - "<SSID> <control freq> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]" +COMMAND(ap, start, + "<SSID> " + PARSE_FREQ_ARGS("<SSID> ", " <beacon interval in TU> <DTIM period> [hidden-ssid|zeroed-ssid] head" " <beacon head in hexadecimal> [tail <beacon tail in hexadecimal>]" - " [inactivity-time <inactivity time in seconds>] [key0:abcde d:1:6162636465]\n"); + " [inactivity-time <inactivity time in seconds>] [key0:abcde d:1:6162636465]"), + NL80211_CMD_NEW_BEACON, 0, CIB_NETDEV, handle_start_ap, + "Start an AP. Note that this usually requires hostapd or similar.\n"); static int handle_stop_ap(struct nl80211_state *state, struct nl_msg *msg, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/event.c new/iw-6.9/event.c --- old/iw-6.7/event.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/event.c 2024-06-05 13:46:13.000000000 +0200 @@ -295,6 +295,8 @@ printf("\t* TCP connection lost\n"); if (tb[NL80211_WOWLAN_TRIG_WAKEUP_TCP_NOMORETOKENS]) printf("\t* TCP connection ran out of tokens\n"); + if (tb[NL80211_WOWLAN_TRIG_UNPROTECTED_DEAUTH_DISASSOC]) + printf("\t* unprotected deauth/disassoc\n"); } extern struct vendor_event *__start_vendor_event[]; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/info.c new/iw-6.9/info.c --- old/iw-6.7/info.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/info.c 2024-06-05 13:46:13.000000000 +0200 @@ -173,6 +173,7 @@ ext_feat_case(OWE_OFFLOAD, "OWE DH element handling offload (client)"); ext_feat_case(OWE_OFFLOAD_AP, "OWE DH element handling offload (AP)"); ext_feat_case(DFS_CONCURRENT, "DFS channel use under concurrent DFS master"); + ext_feat_case(SPP_AMSDU_SUPPORT, "SPP A-MSDU support"); } } diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/interface.c new/iw-6.9/interface.c --- old/iw-6.7/interface.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/interface.c 2024-06-05 13:46:13.000000000 +0200 @@ -385,6 +385,13 @@ if (tb[NL80211_ATTR_CENTER_FREQ2]) printf(", center2: %d MHz", nla_get_u32(tb[NL80211_ATTR_CENTER_FREQ2])); + + if (tb[NL80211_ATTR_PUNCT_BITMAP]) { + uint32_t punct = nla_get_u32(tb[NL80211_ATTR_PUNCT_BITMAP]); + + if (punct) + printf(", punctured: 0x%x", punct); + } } else if (tb[NL80211_ATTR_WIPHY_CHANNEL_TYPE]) { enum nl80211_channel_type channel_type; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/iw.c new/iw-6.9/iw.c --- old/iw-6.7/iw.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/iw.c 2024-06-05 13:46:13.000000000 +0200 @@ -87,8 +87,6 @@ nl_socket_free(state->nl_sock); } -static int cmd_size; - extern struct cmd *__start___cmd[]; extern struct cmd *__stop___cmd; @@ -555,33 +553,12 @@ return __handle_cmd(state, idby, argc, argv, NULL); } -/* - * Unfortunately, I don't know how densely the linker packs the struct cmd. - * For example, if you have a 72-byte struct cmd, the linker will pad each - * out to 96 bytes before putting them together in the section. There must - * be some algorithm, but I haven't found it yet. - * - * We used to calculate this by taking the (abs value of) the difference - * between __section_get and __section_set, but if LTO is enabled then this - * stops working because the entries of the "__cmd" section get rearranged - * freely by the compiler/linker. - * - * Fix this by using yet another "__sizer" section that only contains these - * two entries - then the (abs value of) the difference between them will - * be how they get packed and that can be used to iterate the __cmd section - * as well. - */ -static struct cmd sizer1 __attribute__((section("__sizer"))) = {}; -static struct cmd sizer2 __attribute__((section("__sizer"))) = {}; - int main(int argc, char **argv) { struct nl80211_state nlstate; int err; const struct cmd *cmd = NULL; - /* calculate command size including padding */ - cmd_size = labs((long)&sizer2 - (long)&sizer1); /* strip off self */ argc--; argv0 = *argv++; diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/iw.h new/iw-6.9/iw.h --- old/iw-6.7/iw.h 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/iw.h 2024-06-05 13:46:13.000000000 +0200 @@ -106,6 +106,7 @@ unsigned int center_freq1; unsigned int center_freq1_offset; unsigned int center_freq2; + unsigned int punctured; }; #define ARRAY_SIZE(ar) (sizeof(ar)/sizeof(ar[0])) @@ -209,6 +210,19 @@ unsigned char *parse_hex(char *hex, size_t *outlen); int parse_keys(struct nl_msg *msg, char **argv[], int *argc); + +#define _PARSE_FREQ_ARGS_OPT1 "<freq> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz] [punct <bitmap>]" +#define _PARSE_FREQ_ARGS_OPT2 "<control freq> [5|10|20|40|80|80+80|160|320] [<center1_freq> [<center2_freq>]] [punct <bitmap>]" +#define PARSE_FREQ_ARGS(pfx, sfx) \ + pfx _PARSE_FREQ_ARGS_OPT1 sfx "\n" \ + pfx _PARSE_FREQ_ARGS_OPT2 sfx +#define _PARSE_FREQ_KHZ_ARGS_OPT1 "<freq in KHz> [1MHz|2MHz|4MHz|8MHz|16MHz]" +#define _PARSE_FREQ_KHZ_ARGS_OPT2 "<control freq in KHz> [1|2|4|8|16] [<center1_freq> [<center2_freq>]]" +#define PARSE_FREQ_KHZ_ARGS(pfx, sfx) \ + pfx _PARSE_FREQ_KHZ_ARGS_OPT1 sfx "\n" \ + pfx _PARSE_FREQ_KHZ_ARGS_OPT2 sfx +#define PARSE_CHAN_ARGS(pfx) \ + pfx "<channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz] [punct <bitmap>]" int parse_freqchan(struct chandef *chandef, bool chan, int argc, char **argv, int *parsed, bool freq_in_khz); enum nl80211_chan_width str_to_bw(const char *str); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/nl80211.h new/iw-6.9/nl80211.h --- old/iw-6.7/nl80211.h 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/nl80211.h 2024-06-05 13:46:13.000000000 +0200 @@ -11,7 +11,7 @@ * Copyright 2008 Jouni Malinen <jouni.malinen@atheros.com> * Copyright 2008 Colin McCabe <colin@cozybit.com> * Copyright 2015-2017 Intel Deutschland GmbH - * Copyright (C) 2018-2023 Intel Corporation + * Copyright (C) 2018-2024 Intel Corporation * * Permission to use, copy, modify, and/or distribute this software for any * purpose with or without fee is hereby granted, provided that the above @@ -438,7 +438,8 @@ * %NL80211_ATTR_REASON_CODE can optionally be used to specify which type * of disconnection indication should be sent to the station * (Deauthentication or Disassociation frame and reason code for that - * frame). + * frame). %NL80211_ATTR_MLO_LINK_ID can be used optionally to remove + * stations connected and using at least that link as one of its links. * * @NL80211_CMD_GET_MPATH: Get mesh path attributes for mesh path to * destination %NL80211_ATTR_MAC on the interface identified by @@ -2851,6 +2852,10 @@ * mapping is as defined in section 9.4.2.314 (TID-To-Link Mapping element) * in Draft P802.11be_D4.0. * + * @NL80211_ATTR_ASSOC_SPP_AMSDU: flag attribute used with + * %NL80211_CMD_ASSOCIATE indicating the SPP A-MSDUs + * are used on this connection + * * @NUM_NL80211_ATTR: total number of nl80211_attrs available * @NL80211_ATTR_MAX: highest attribute number currently defined * @__NL80211_ATTR_AFTER_LAST: internal use @@ -3394,6 +3399,8 @@ NL80211_ATTR_MLO_TTLM_DLINK, NL80211_ATTR_MLO_TTLM_ULINK, + NL80211_ATTR_ASSOC_SPP_AMSDU, + /* add attributes here, update the policy in nl80211.c */ __NL80211_ATTR_AFTER_LAST, @@ -3534,6 +3541,7 @@ * @NL80211_STA_FLAG_ASSOCIATED: station is associated; used with drivers * that support %NL80211_FEATURE_FULL_AP_CLIENT_STATE to transition a * previously added station into associated state + * @NL80211_STA_FLAG_SPP_AMSDU: station supports SPP A-MSDUs * @NL80211_STA_FLAG_MAX: highest station flag number currently defined * @__NL80211_STA_FLAG_AFTER_LAST: internal use */ @@ -3546,6 +3554,7 @@ NL80211_STA_FLAG_AUTHENTICATED, NL80211_STA_FLAG_TDLS_PEER, NL80211_STA_FLAG_ASSOCIATED, + NL80211_STA_FLAG_SPP_AMSDU, /* keep last */ __NL80211_STA_FLAG_AFTER_LAST, @@ -4260,10 +4269,13 @@ * allowed for peer-to-peer or adhoc communication under the control * of a DFS master which operates on the same channel (FCC-594280 D01 * Section B.3). Should be used together with %NL80211_RRF_DFS only. - * @NL80211_FREQUENCY_ATTR_NO_UHB_VLP_CLIENT: Client connection to VLP AP + * @NL80211_FREQUENCY_ATTR_NO_6GHZ_VLP_CLIENT: Client connection to VLP AP * not allowed using this channel - * @NL80211_FREQUENCY_ATTR_NO_UHB_AFC_CLIENT: Client connection to AFC AP + * @NL80211_FREQUENCY_ATTR_NO_6GHZ_AFC_CLIENT: Client connection to AFC AP * not allowed using this channel + * @NL80211_FREQUENCY_ATTR_CAN_MONITOR: This channel can be used in monitor + * mode despite other (regulatory) restrictions, even if the channel is + * otherwise completely disabled. * @NL80211_FREQUENCY_ATTR_MAX: highest frequency attribute number * currently defined * @__NL80211_FREQUENCY_ATTR_AFTER_LAST: internal use @@ -4304,8 +4316,9 @@ NL80211_FREQUENCY_ATTR_NO_EHT, NL80211_FREQUENCY_ATTR_PSD, NL80211_FREQUENCY_ATTR_DFS_CONCURRENT, - NL80211_FREQUENCY_ATTR_NO_UHB_VLP_CLIENT, - NL80211_FREQUENCY_ATTR_NO_UHB_AFC_CLIENT, + NL80211_FREQUENCY_ATTR_NO_6GHZ_VLP_CLIENT, + NL80211_FREQUENCY_ATTR_NO_6GHZ_AFC_CLIENT, + NL80211_FREQUENCY_ATTR_CAN_MONITOR, /* keep last */ __NL80211_FREQUENCY_ATTR_AFTER_LAST, @@ -4318,6 +4331,10 @@ #define NL80211_FREQUENCY_ATTR_NO_IR NL80211_FREQUENCY_ATTR_NO_IR #define NL80211_FREQUENCY_ATTR_GO_CONCURRENT \ NL80211_FREQUENCY_ATTR_IR_CONCURRENT +#define NL80211_FREQUENCY_ATTR_NO_UHB_VLP_CLIENT \ + NL80211_FREQUENCY_ATTR_NO_6GHZ_VLP_CLIENT +#define NL80211_FREQUENCY_ATTR_NO_UHB_AFC_CLIENT \ + NL80211_FREQUENCY_ATTR_NO_6GHZ_AFC_CLIENT /** * enum nl80211_bitrate_attr - bitrate attributes @@ -4455,14 +4472,7 @@ * value as specified by &struct nl80211_bss_select_rssi_adjust. * @NL80211_SCHED_SCAN_MATCH_ATTR_BSSID: BSSID to be used for matching * (this cannot be used together with SSID). - * @NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI: Nested attribute that carries the - * band specific minimum rssi thresholds for the bands defined in - * enum nl80211_band. The minimum rssi threshold value(s32) specific to a - * band shall be encapsulated in attribute with type value equals to one - * of the NL80211_BAND_* defined in enum nl80211_band. For example, the - * minimum rssi threshold value for 2.4GHZ band shall be encapsulated - * within an attribute of type NL80211_BAND_2GHZ. And one or more of such - * attributes will be nested within this attribute. + * @NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI: Obsolete * @NL80211_SCHED_SCAN_MATCH_ATTR_MAX: highest scheduled scan filter * attribute number currently defined * @__NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST: internal use @@ -4475,7 +4485,7 @@ NL80211_SCHED_SCAN_MATCH_ATTR_RELATIVE_RSSI, NL80211_SCHED_SCAN_MATCH_ATTR_RSSI_ADJUST, NL80211_SCHED_SCAN_MATCH_ATTR_BSSID, - NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI, + NL80211_SCHED_SCAN_MATCH_PER_BAND_RSSI, /* obsolete */ /* keep last */ __NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST, @@ -4515,8 +4525,8 @@ peer-to-peer or adhoc communication under the control of a DFS master which operates on the same channel (FCC-594280 D01 Section B.3). Should be used together with %NL80211_RRF_DFS only. - * @NL80211_RRF_NO_UHB_VLP_CLIENT: Client connection to VLP AP not allowed - * @NL80211_RRF_NO_UHB_AFC_CLIENT: Client connection to AFC AP not allowed + * @NL80211_RRF_NO_6GHZ_VLP_CLIENT: Client connection to VLP AP not allowed + * @NL80211_RRF_NO_6GHZ_AFC_CLIENT: Client connection to AFC AP not allowed */ enum nl80211_reg_rule_flags { NL80211_RRF_NO_OFDM = 1<<0, @@ -4539,8 +4549,8 @@ NL80211_RRF_NO_EHT = 1<<19, NL80211_RRF_PSD = 1<<20, NL80211_RRF_DFS_CONCURRENT = 1<<21, - NL80211_RRF_NO_UHB_VLP_CLIENT = 1<<22, - NL80211_RRF_NO_UHB_AFC_CLIENT = 1<<23, + NL80211_RRF_NO_6GHZ_VLP_CLIENT = 1<<22, + NL80211_RRF_NO_6GHZ_AFC_CLIENT = 1<<23, }; #define NL80211_RRF_PASSIVE_SCAN NL80211_RRF_NO_IR @@ -4549,6 +4559,8 @@ #define NL80211_RRF_NO_HT40 (NL80211_RRF_NO_HT40MINUS |\ NL80211_RRF_NO_HT40PLUS) #define NL80211_RRF_GO_CONCURRENT NL80211_RRF_IR_CONCURRENT +#define NL80211_RRF_NO_UHB_VLP_CLIENT NL80211_RRF_NO_6GHZ_VLP_CLIENT +#define NL80211_RRF_NO_UHB_AFC_CLIENT NL80211_RRF_NO_6GHZ_AFC_CLIENT /* For backport compatibility with older userspace */ #define NL80211_RRF_NO_IR_ALL (NL80211_RRF_NO_IR | __NL80211_RRF_NO_IBSS) @@ -5096,14 +5108,17 @@ * BSS isn't possible * @NL80211_BSS_CANNOT_USE_NSTR_NONPRIMARY: NSTR nonprimary links aren't * supported by the device, and this BSS entry represents one. - * @NL80211_BSS_CANNOT_USE_UHB_PWR_MISMATCH: STA is not supporting + * @NL80211_BSS_CANNOT_USE_6GHZ_PWR_MISMATCH: STA is not supporting * the AP power type (SP, VLP, AP) that the AP uses. */ enum nl80211_bss_cannot_use_reasons { NL80211_BSS_CANNOT_USE_NSTR_NONPRIMARY = 1 << 0, - NL80211_BSS_CANNOT_USE_UHB_PWR_MISMATCH = 1 << 1, + NL80211_BSS_CANNOT_USE_6GHZ_PWR_MISMATCH = 1 << 1, }; +#define NL80211_BSS_CANNOT_USE_UHB_PWR_MISMATCH \ + NL80211_BSS_CANNOT_USE_6GHZ_PWR_MISMATCH + /** * enum nl80211_bss - netlink attributes for a BSS * @@ -5742,6 +5757,8 @@ * %NL80211_ATTR_SCAN_FREQUENCIES contains more than one * frequency, it means that the match occurred in more than one * channel. + * @NL80211_WOWLAN_TRIG_UNPROTECTED_DEAUTH_DISASSOC: For wakeup reporting only. + * Wake up happened due to unprotected deauth or disassoc frame in MFP. * @NUM_NL80211_WOWLAN_TRIG: number of wake on wireless triggers * @MAX_NL80211_WOWLAN_TRIG: highest wowlan trigger attribute number * @@ -5769,6 +5786,7 @@ NL80211_WOWLAN_TRIG_WAKEUP_TCP_NOMORETOKENS, NL80211_WOWLAN_TRIG_NET_DETECT, NL80211_WOWLAN_TRIG_NET_DETECT_RESULTS, + NL80211_WOWLAN_TRIG_UNPROTECTED_DEAUTH_DISASSOC, /* keep last */ NUM_NL80211_WOWLAN_TRIG, @@ -6410,8 +6428,7 @@ * @NL80211_EXT_FEATURE_AP_PMKSA_CACHING: Driver/device supports PMKSA caching * (set/del PMKSA operations) in AP mode. * - * @NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD: Driver supports - * filtering of sched scan results using band specific RSSI thresholds. + * @NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD: Obsolete * * @NL80211_EXT_FEATURE_STA_TX_PWR: This driver supports controlling tx power * to a station. @@ -6520,6 +6537,11 @@ * DFS master on the same channel as described in FCC-594280 D01 * (Section B.3). This, for example, allows P2P GO and P2P clients to * operate on DFS channels as long as there's a concurrent BSS connection. + * + * @NL80211_EXT_FEATURE_SPP_AMSDU_SUPPORT: The driver has support for SPP + * (signaling and payload protected) A-MSDUs and this shall be advertised + * in the RSNXE. + * * @NUM_NL80211_EXT_FEATURES: number of extended features. * @MAX_NL80211_EXT_FEATURES: highest extended feature index. */ @@ -6561,7 +6583,7 @@ NL80211_EXT_FEATURE_ENABLE_FTM_RESPONDER, NL80211_EXT_FEATURE_AIRTIME_FAIRNESS, NL80211_EXT_FEATURE_AP_PMKSA_CACHING, - NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD, + NL80211_EXT_FEATURE_SCHED_SCAN_BAND_SPECIFIC_RSSI_THOLD, /* obsolete */ NL80211_EXT_FEATURE_EXT_KEY_ID, NL80211_EXT_FEATURE_STA_TX_PWR, NL80211_EXT_FEATURE_SAE_OFFLOAD, @@ -6594,6 +6616,7 @@ NL80211_EXT_FEATURE_OWE_OFFLOAD, NL80211_EXT_FEATURE_OWE_OFFLOAD_AP, NL80211_EXT_FEATURE_DFS_CONCURRENT, + NL80211_EXT_FEATURE_SPP_AMSDU_SUPPORT, /* add new features before the definition below */ NUM_NL80211_EXT_FEATURES, diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/phy.c new/iw-6.9/phy.c --- old/iw-6.7/phy.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/phy.c 2024-06-05 13:46:13.000000000 +0200 @@ -198,15 +198,10 @@ return put_chandef(msg, &chandef); } -COMMAND(set, freq, - "<freq> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz]\n" - "<control freq> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]", +COMMAND(set, freq, PARSE_FREQ_ARGS("", ""), NL80211_CMD_SET_WIPHY, 0, CIB_PHY, handle_freq, - "Set frequency/channel the hardware is using, including HT\n" - "configuration."); -COMMAND(set, freq, - "<freq> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz]\n" - "<control freq> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]", + "Set frequency/channel configuration the hardware is using."); +COMMAND(set, freq, PARSE_FREQ_ARGS("", ""), NL80211_CMD_SET_WIPHY, 0, CIB_NETDEV, handle_freq, NULL); static int handle_freq_khz(struct nl80211_state *state, struct nl_msg *msg, @@ -223,15 +218,11 @@ return put_chandef(msg, &chandef); } -COMMAND(set, freq_khz, - "<freq> [1MHz|2MHz|4MHz|8MHz|16MHz]\n" - "<control freq> [1|2|4|8|16] [<center1_freq> [<center2_freq>]]", +COMMAND(set, freq_khz, PARSE_FREQ_KHZ_ARGS("", ""), NL80211_CMD_SET_WIPHY, 0, CIB_PHY, handle_freq_khz, "Set frequency in kHz the hardware is using\n" "configuration."); -COMMAND(set, freq_khz, - "<freq> [1MHz|2MHz|4MHz|8MHz|16MHz]\n" - "<control freq> [1|2|4|8|16] [<center1_freq> [<center2_freq>]]", +COMMAND(set, freq_khz, PARSE_FREQ_KHZ_ARGS("", ""), NL80211_CMD_SET_WIPHY, 0, CIB_NETDEV, handle_freq_khz, NULL); static int handle_chan(struct nl80211_state *state, struct nl_msg *msg, @@ -247,9 +238,9 @@ return put_chandef(msg, &chandef); } -COMMAND(set, channel, "<channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz]", +COMMAND(set, channel, PARSE_CHAN_ARGS(""), NL80211_CMD_SET_WIPHY, 0, CIB_PHY, handle_chan, NULL); -COMMAND(set, channel, "<channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz]", +COMMAND(set, channel, PARSE_CHAN_ARGS(""), NL80211_CMD_SET_WIPHY, 0, CIB_NETDEV, handle_chan, NULL); @@ -403,22 +394,19 @@ free(cac_trigger_argv); return err; } -TOPLEVEL(cac, "channel <channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <freq> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <control freq> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]", +TOPLEVEL(cac, PARSE_CHAN_ARGS("channel ") "\n" + PARSE_FREQ_ARGS("freq ", ""), 0, 0, CIB_NETDEV, handle_cac, NULL); COMMAND(cac, trigger, - "channel <channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <frequency> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <frequency> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]", + PARSE_CHAN_ARGS("channel ") "\n" + PARSE_FREQ_ARGS("freq ", ""), NL80211_CMD_RADAR_DETECT, 0, CIB_NETDEV, handle_cac_trigger, "Start or trigger a channel availability check (CAC) looking to look for\n" "radars on the given channel."); COMMAND(cac, background, - "channel <channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <frequency> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz]\n" - "freq <frequency> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]]", + PARSE_CHAN_ARGS("channel ") "\n" + PARSE_FREQ_ARGS("freq ", ""), NL80211_CMD_RADAR_DETECT, 0, CIB_NETDEV, handle_cac_background, "Start background channel availability check (CAC) looking to look for\n" "radars on the given channel."); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/util.c new/iw-6.9/util.c --- old/iw-6.7/util.c 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/util.c 2024-06-05 13:46:13.000000000 +0200 @@ -593,11 +593,11 @@ * user by giving "NOHT" instead. * * The working specifier if chan is set are: - * <channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz] + * <channel> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz] * * And if frequency is set: * <freq> [NOHT|HT20|HT40+|HT40-|5MHz|10MHz|80MHz|160MHz|320MHz] - * <control freq> [5|10|20|40|80|80+80|160] [<center1_freq> [<center2_freq>]] + * <control freq> [5|10|20|40|80|80+80|160|320] [<center1_freq> [<center2_freq>]] * * If the mode/channel width is not given the NOHT is assumed. * @@ -735,15 +735,29 @@ goto out; } - /* This was a only a channel definition, nothing further may follow. */ + /* This was a only a channel definition, only puncturing may follow */ if (chan) goto out; res = parse_freqs(chandef, argc - 1, argv + 1, &_parsed, freq_in_khz); out: - /* Error out if parsed is NULL. */ - if (!parsed && _parsed != argc) + if (!freq_in_khz && argc > _parsed && strcmp(argv[_parsed], "punct") == 0) { + _parsed++; + if (argc <= _parsed) + return 1; + chandef->punctured = strtoul(argv[_parsed], &end, 10); + if (*end) + return 1; + _parsed++; + } + + /* + * Either this must consume all args, or users must pass a + * valid pointer as 'parsed' and use it to know how many of + * the arguments this function consumed. + */ + if (_parsed != argc && !parsed) return 1; if (parsed) @@ -800,6 +814,9 @@ NL80211_ATTR_CENTER_FREQ2, chandef->center_freq2); + if (chandef->punctured) + NLA_PUT_U32(msg, NL80211_ATTR_PUNCT_BITMAP, chandef->punctured); + return 0; nla_put_failure: diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/iw-6.7/version.sh new/iw-6.9/version.sh --- old/iw-6.7/version.sh 2023-12-21 20:42:23.000000000 +0100 +++ new/iw-6.9/version.sh 2024-06-05 13:46:13.000000000 +0200 @@ -1,6 +1,6 @@ #!/bin/sh -VERSION="6.7" +VERSION="6.9" OUT="$1" # get the absolute path for the OUT file ++++++ iw.obsinfo ++++++ --- /var/tmp/diff_new_pack.EX3zZY/_old 2024-06-07 15:02:04.760958734 +0200 +++ /var/tmp/diff_new_pack.EX3zZY/_new 2024-06-07 15:02:04.764958880 +0200 @@ -1,5 +1,5 @@ name: iw -version: 6.7 -mtime: 1703187743 -commit: c49eb9ee6847953b24ba265add49fa4ec587c7a8 +version: 6.9 +mtime: 1717587973 +commit: 8609336b71a8ae37238dc3f4ddff251a4698a4fc
participants (1)
-
Source-Sync