| Seq | Timestamp | Type | Name | Duration |
|---|---|---|---|---|
| 0/0 | 2026/07/12 10:38 | flow | patch-triage |
0mArgs:null Results: {
"EnableConfigs": [
"MAC80211"
],
"FocusSymbols": [
"ieee80211_vif_set_links",
"ieee80211_vif_update_links"
],
"Reasoning": "The patch adds error handling cleanup in `ieee80211_vif_update_links` to stop and remove debugfs for newly allocated links if an error occurs. This is a functional change in the mac80211 core subsystem, reachable via software-emulated hardware like mac80211_hwsim.",
"WorthFuzzing": true
} |
| 1/1 | 2026/07/12 10:38 | action | read-patch-diff |
0mArgs:null Results: {
"PatchDiff": "commit a6b0d46ce354d4296bfeee8d521332b78e1bc5cc\nAuthor: syz-cluster \u003ctriage@syzkaller.com\u003e\nDate: Sun Jul 12 10:38:42 2026 +0000\n\n syz-cluster: applied patch under review\n\ndiff --git a/net/mac80211/link.c b/net/mac80211/link.c\nindex d0535268962c7a..dc68144dc363af 100644\n--- a/net/mac80211/link.c\n+++ b/net/mac80211/link.c\n@@ -399,6 +399,10 @@ static int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,\n \t\tmemcpy(sdata-\u003elink, old_data, sizeof(old_data));\n \t\tmemcpy(sdata-\u003evif.link_conf, old, sizeof(old));\n \t\tieee80211_set_vif_links_bitmaps(sdata, old_links, dormant_links);\n+\t\tfor_each_set_bit(link_id, \u0026add, IEEE80211_MLD_MAX_NUM_LINKS) {\n+\t\t\tieee80211_link_debugfs_remove(\u0026links[link_id]-\u003edata);\n+\t\t\tieee80211_link_stop(\u0026links[link_id]-\u003edata);\n+\t\t}\n \t\t/* and free (only) the newly allocated links */\n \t\tmemset(to_free, 0, sizeof(links));\n \t\tgoto free;\n"
} |
| 2/1 | 2026/07/12 10:38 | agent | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: {
"EnableConfigs": [
"MAC80211"
],
"FocusSymbols": [
"ieee80211_vif_set_links",
"ieee80211_vif_update_links"
],
"Reasoning": "The patch adds error handling cleanup in `ieee80211_vif_update_links` to stop and remove debugfs for newly allocated links if an error occurs. This is a functional change in the mac80211 core subsystem, reachable via software-emulated hardware like mac80211_hwsim.",
"WorthFuzzing": true
}Instruction: You are an expert Linux kernel maintainer. Your job is to review a provided patch series and determine if it makes functional changes to the kernel that should be fuzzed. IMPORTANT: The changes have ALREADY been applied and committed as the HEAD commit in your workspace. Do NOT rely on your internal knowledge of the kernel. You must actively use your code access tools to examine the actual source code and confirm any assumptions. Return WorthFuzzing=false if the patch only contains: - Modifications to Documentation/, Kconfig files, or code comments. - Purely decorative changes, such as logging (e.g., pr_err, printk) or tracepoints. - Changes to numeric constants or macros that do not functionally alter execution flow. - Code paths that are impossible to reach in virtualized environments like GCE or QEMU, even when utilizing software-emulated hardware (e.g., usb gadget, mac80211_hwsim). If it modifies reachable core kernel logic, drivers, or architectures, use your code search tools to verify the code can be executed, then return WorthFuzzing=true. When returning WorthFuzzing=true, you MUST ALSO: 1. Extract any specific kernel functions that should be heavily fuzzed into FocusSymbols. Avoid listing generic hot-path functions to prevent skewed test distributions. 2. Identify any specific CONFIG_ options required to properly test this new/modified feature. Go and look into the Kconfig files and check for ifdefs around the code, do not make assumptions. Do not list too generic configs (we already have them enabled). Only list those that specifically cover the modified code. List them in the EnableConfigs output array, and DO NOT add a 'CONFIG_' prefix (e.g., return "NET_IPV4" instead of "CONFIG_NET_IPV4"). Prefer calling several tools at the same time to save round-trips. Use set-results tool to provide results of the analysis. It must be called exactly once before the final reply. Ignore results of this tool. Prompt: For your convenience, here is the diff of the changes:
commit a6b0d46ce354d4296bfeee8d521332b78e1bc5cc
Author: syz-cluster <triage@syzkaller.com>
Date: Sun Jul 12 10:38:42 2026 +0000
syz-cluster: applied patch under review
diff --git a/net/mac80211/link.c b/net/mac80211/link.c
index d0535268962c7a..dc68144dc363af 100644
--- a/net/mac80211/link.c
+++ b/net/mac80211/link.c
@@ -399,6 +399,10 @@ static int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,
memcpy(sdata->link, old_data, sizeof(old_data));
memcpy(sdata->vif.link_conf, old, sizeof(old));
ieee80211_set_vif_links_bitmaps(sdata, old_links, dormant_links);
+ for_each_set_bit(link_id, &add, IEEE80211_MLD_MAX_NUM_LINKS) {
+ ieee80211_link_debugfs_remove(&links[link_id]->data);
+ ieee80211_link_stop(&links[link_id]->data);
+ }
/* and free (only) the newly allocated links */
memset(to_free, 0, sizeof(links));
goto free;
|
| 3/2 | 2026/07/12 10:38 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 1970 output: 46 thoughts: 202 Thoughts: **Analyzing the Mac80211 Link Update Patch** Okay, so I'm looking at this patch for `net/mac80211/link.c`, specifically the `ieee80211_vif_update_links` function. It seems like the core change revolves around an error handling scenario. The patch adds a cleanup loop to handle potential errors that might arise while updating links. I see a `for_each_set_bit` loop within the error path, using the `add` bitmap to iterate through newly added links. Inside the loop, it calls `ieee80211_link_debugfs_remove` and `ieee80211_link_stop` on those links. This is a crucial step for preventing resource leaks and ensuring a clean state if the update process fails. It's a solid defensive measure, given the complexity of link management in this area. It also suggests that link creation is a multi-step operation, and this handles the rollback, so to speak. Now, let's dive into the function `ieee80211_vif_update_links` itself. I need to understand the surrounding context of this error handling to fully appreciate its implications. I'll need to see the function signature, its data structures, and the possible points where an error could arise to assess the effectiveness and correctness of this patch in its entirety. It's a well-written approach, but context is king, as always. |
| 4/2 | 2026/07/12 10:38 | tool | grepper |
0mArgs:{
"Expression": "ieee80211_vif_update_links",
"PathPrefix": "net/mac80211/link.c"
}Results: {
"Output": "net/mac80211/link.c=251=static void ieee80211_set_vif_links_bitmaps(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/link.c-286-\nnet/mac80211/link.c:287:static int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,\nnet/mac80211/link.c-288-\t\t\t\t struct link_container **to_free,\n--\nnet/mac80211/link.c=456=int ieee80211_vif_set_links(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/link.c-461-\nnet/mac80211/link.c:462:\tret = ieee80211_vif_update_links(sdata, links, new_links,\nnet/mac80211/link.c-463-\t\t\t\t\t dormant_links);\n"
} |
| 5/2 | 2026/07/12 10:38 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 2851 output: 43 thoughts: 60 Thoughts: **Tracing the Linkage of `ieee80211_vif_update_links`** Okay, so I'm looking at `ieee80211_vif_update_links`. I know from the structure that it's called by `ieee80211_vif_set_links`. Now, I need to understand the larger context of this call chain. Specifically, I need to know where `ieee80211_vif_set_links` itself is being invoked. Understanding the calling contexts will give me the best insight into its purpose and how it fits into the overall IEEE 802.11 stack operations. Let's dig in and figure out where this function is triggered. |
| 6/2 | 2026/07/12 10:38 | tool | grepper |
0mArgs:{
"Expression": "ieee80211_vif_set_links",
"PathPrefix": "net/mac80211/"
}Results: {
"Output": "net/mac80211/cfg.c=2724=static int ieee80211_set_sta_4addr(struct ieee80211_local *local,\n--\nnet/mac80211/cfg.c-2753-\nnet/mac80211/cfg.c:2754:\t\terr = ieee80211_vif_set_links(sdata, new_links, 0);\nnet/mac80211/cfg.c-2755-\t\tif (err) {\n--\nnet/mac80211/cfg.c=5801=static int ieee80211_add_intf_link(struct wiphy *wiphy,\n--\nnet/mac80211/cfg.c-5808-\nnet/mac80211/cfg.c:5809:\treturn ieee80211_vif_set_links(sdata, wdev-\u003evalid_links, 0);\nnet/mac80211/cfg.c-5810-}\n--\nnet/mac80211/cfg.c=5812=static void ieee80211_del_intf_link(struct wiphy *wiphy,\n--\nnet/mac80211/cfg.c-5825-\t */\nnet/mac80211/cfg.c:5826:\tieee80211_vif_set_links(sdata, new_links, 0);\nnet/mac80211/cfg.c-5827-}\n--\nnet/mac80211/ieee80211_i.h=2214=void ieee80211_link_stop(struct ieee80211_link_data *link);\nnet/mac80211/ieee80211_i.h:2215:int ieee80211_vif_set_links(struct ieee80211_sub_if_data *sdata,\nnet/mac80211/ieee80211_i.h-2216-\t\t\t u16 new_links, u16 dormant_links);\nnet/mac80211/ieee80211_i.h=2217=static inline void ieee80211_vif_clear_links(struct ieee80211_sub_if_data *sdata)\nnet/mac80211/ieee80211_i.h-2218-{\nnet/mac80211/ieee80211_i.h:2219:\tieee80211_vif_set_links(sdata, 0, 0);\nnet/mac80211/ieee80211_i.h-2220-}\n--\nnet/mac80211/link.c=15=static void ieee80211_update_apvlan_links(struct ieee80211_sub_if_data *sdata)\n--\nnet/mac80211/link.c-49-\nnet/mac80211/link.c:50:\t\tieee80211_vif_set_links(vlan, add, 0);\nnet/mac80211/link.c-51-\n--\nnet/mac80211/link.c=59=void ieee80211_apvlan_link_setup(struct ieee80211_sub_if_data *sdata)\n--\nnet/mac80211/link.c-76-\nnet/mac80211/link.c:77:\tieee80211_vif_set_links(sdata, new_links, 0);\nnet/mac80211/link.c-78-}\n--\nnet/mac80211/link.c=287=static int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/link.c-455-\nnet/mac80211/link.c:456:int ieee80211_vif_set_links(struct ieee80211_sub_if_data *sdata,\nnet/mac80211/link.c-457-\t\t\t u16 new_links, u16 dormant_links)\n--\nnet/mac80211/mlme.c=4508=static void ieee80211_set_disassoc(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-4752-\nnet/mac80211/mlme.c:4753:\tieee80211_vif_set_links(sdata, 0, 0);\nnet/mac80211/mlme.c-4754-\n--\nnet/mac80211/mlme.c=5261=static void ieee80211_destroy_auth_data(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-5285-\t\tieee80211_link_release_channel(\u0026sdata-\u003edeflink);\nnet/mac80211/mlme.c:5286:\t\tieee80211_vif_set_links(sdata, 0, 0);\nnet/mac80211/mlme.c-5287-\t}\n--\nnet/mac80211/mlme.c=5300=static void ieee80211_destroy_assoc_data(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-5342-\t\tieee80211_link_release_channel(\u0026sdata-\u003edeflink);\nnet/mac80211/mlme.c:5343:\t\tieee80211_vif_set_links(sdata, 0, 0);\nnet/mac80211/mlme.c-5344-\t}\n--\nnet/mac80211/mlme.c=6924=static bool ieee80211_assoc_success(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-6995-\nnet/mac80211/mlme.c:6996:\t\tieee80211_vif_set_links(sdata, valid_links, dormant_links);\nnet/mac80211/mlme.c-6997-\t}\n--\nnet/mac80211/mlme.c-7079-\t/* links might have changed due to rejected ones, set them again */\nnet/mac80211/mlme.c:7080:\tieee80211_vif_set_links(sdata, valid_links, dormant_links);\nnet/mac80211/mlme.c-7081-\n--\nnet/mac80211/mlme.c=7571=static void ieee80211_ml_reconf_work(struct wiphy *wiphy,\n--\nnet/mac80211/mlme.c-7614-\nnet/mac80211/mlme.c:7615:\tret = ieee80211_vif_set_links(sdata, new_valid_links,\nnet/mac80211/mlme.c-7616-\t\t\t\t new_dormant_links);\n--\nnet/mac80211/mlme.c=7721=static int ieee80211_ttlm_set_links(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-7758-\nnet/mac80211/mlme.c:7759:\tret = ieee80211_vif_set_links(sdata, sdata-\u003evif.valid_links,\nnet/mac80211/mlme.c-7760-\t\t\t\t dormant_links);\n--\nnet/mac80211/mlme.c=7779=static void ieee80211_tid_to_link_map_work(struct wiphy *wiphy,\n--\nnet/mac80211/mlme.c-7791-\nnet/mac80211/mlme.c:7792:\tieee80211_vif_set_links(sdata, sdata-\u003evif.valid_links, 0);\nnet/mac80211/mlme.c-7793-\tif (ieee80211_ttlm_set_links(sdata, new_active_links, new_dormant_links,\n--\nnet/mac80211/mlme.c=7801=static void ieee80211_process_adv_ttlm(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-7821-\t\t\t */\nnet/mac80211/mlme.c:7822:\t\t\tret = ieee80211_vif_set_links(sdata,\nnet/mac80211/mlme.c-7823-\t\t\t\t\t\t sdata-\u003evif.valid_links,\n--\nnet/mac80211/mlme.c=8796=static void ieee80211_process_ttlm_teardown(struct ieee80211_sub_if_data *sdata)\n--\nnet/mac80211/mlme.c-8806-\tsdata-\u003evif.suspended_links = 0;\nnet/mac80211/mlme.c:8807:\tieee80211_vif_set_links(sdata, sdata-\u003evif.valid_links,\nnet/mac80211/mlme.c-8808-\t\t\t\tnew_dormant_links);\n--\nnet/mac80211/mlme.c=9540=static int ieee80211_prep_connection(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-9577-\nnet/mac80211/mlme.c:9578:\terr = ieee80211_vif_set_links(sdata, new_links, 0);\nnet/mac80211/mlme.c-9579-\tif (err)\n--\nnet/mac80211/mlme.c-9751-\t\tWARN_ON(__sta_info_destroy(have_sta));\nnet/mac80211/mlme.c:9752:\tieee80211_vif_set_links(sdata, 0, 0);\nnet/mac80211/mlme.c-9753-\treturn err;\n--\nnet/mac80211/mlme.c=10265=int ieee80211_mgd_assoc(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-10530-\t\t/* if there was no authentication, set up the link */\nnet/mac80211/mlme.c:10531:\t\terr = ieee80211_vif_set_links(sdata, BIT(assoc_link_id), 0);\nnet/mac80211/mlme.c-10532-\t\tif (err)\n--\nnet/mac80211/mlme.c=10868=ieee80211_process_ml_reconf_resp(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-10987-\nnet/mac80211/mlme.c:10988:\tieee80211_vif_set_links(sdata, valid_links, sdata-\u003evif.dormant_links);\nnet/mac80211/mlme.c-10989-\tlink_mask = 0;\n--\nnet/mac80211/mlme.c-11070-\t/* links might have changed due to rejected ones, set them again */\nnet/mac80211/mlme.c:11071:\tieee80211_vif_set_links(sdata, valid_links, sdata-\u003evif.dormant_links);\nnet/mac80211/mlme.c-11072-\tieee80211_vif_cfg_change_notify(sdata, BSS_CHANGED_MLD_VALID_LINKS);\n--\nnet/mac80211/mlme.c=11330=int ieee80211_mgd_assoc_ml_reconf(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/mlme.c-11520-\nnet/mac80211/mlme.c:11521:\t\terr = ieee80211_vif_set_links(sdata, new_valid_links,\nnet/mac80211/mlme.c-11522-\t\t\t\t\t new_dormant_links);\n"
} |
| 7/2 | 2026/07/12 10:38 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 6719 output: 38 thoughts: 73 Thoughts: **Analyzing the mac80211 Patch** Okay, so this patch is cleaning things up within `ieee80211_vif_update_links`, specifically addressing potential failure scenarios. That immediately flags this as a functional change, a correction within the core mac80211 subsystem. The description hints at a resource leak or a similar problem related to link updates not completing successfully. My immediate thought is, "good catch!". We need to be robust and handle these failure cases gracefully to avoid any instability. Now I need to quickly review the relevant configuration options within mac80211 to see if any specific settings might be influencing this behavior or if this patch impacts any of our tuned configurations. Let's see what's involved... |
| 8/2 | 2026/07/12 10:38 | tool | grepper |
0mArgs:{
"Expression": "config MAC80211",
"PathPrefix": "net/mac80211/Kconfig"
}Results: {
"Output": "net/mac80211/Kconfig-1-# SPDX-License-Identifier: GPL-2.0-only\nnet/mac80211/Kconfig:2:config MAC80211\nnet/mac80211/Kconfig-3-\ttristate \"Generic IEEE 802.11 Networking Stack (mac80211)\"\n--\nnet/mac80211/Kconfig=19=if MAC80211 != n\nnet/mac80211/Kconfig-20-\nnet/mac80211/Kconfig:21:config MAC80211_HAS_RC\nnet/mac80211/Kconfig-22-\tbool\nnet/mac80211/Kconfig-23-\nnet/mac80211/Kconfig:24:config MAC80211_RC_MINSTREL\nnet/mac80211/Kconfig-25-\tbool \"Minstrel\" if EXPERT\n--\nnet/mac80211/Kconfig=31=choice\n--\nnet/mac80211/Kconfig-40-\nnet/mac80211/Kconfig:41:config MAC80211_RC_DEFAULT_MINSTREL\nnet/mac80211/Kconfig-42-\tbool \"Minstrel\"\n--\nnet/mac80211/Kconfig=48=endchoice\nnet/mac80211/Kconfig-49-\nnet/mac80211/Kconfig:50:config MAC80211_RC_DEFAULT\nnet/mac80211/Kconfig-51-\tstring\n--\nnet/mac80211/Kconfig=57=comment \"Some wireless drivers require a rate control algorithm\"\n--\nnet/mac80211/Kconfig-59-\nnet/mac80211/Kconfig:60:config MAC80211_KUNIT_TEST\nnet/mac80211/Kconfig-61-\ttristate \"KUnit tests for mac80211\" if !KUNIT_ALL_TESTS\n--\nnet/mac80211/Kconfig-69-\nnet/mac80211/Kconfig:70:config MAC80211_MESH\nnet/mac80211/Kconfig-71-\tbool \"Enable mac80211 mesh networking support\"\n--\nnet/mac80211/Kconfig-78-\nnet/mac80211/Kconfig:79:config MAC80211_LEDS\nnet/mac80211/Kconfig-80-\tbool \"Enable LED triggers\"\n--\nnet/mac80211/Kconfig-87-\nnet/mac80211/Kconfig:88:config MAC80211_DEBUGFS\nnet/mac80211/Kconfig-89-\tbool \"Export mac80211 internals in DebugFS\"\n--\nnet/mac80211/Kconfig-96-\nnet/mac80211/Kconfig:97:config MAC80211_MESSAGE_TRACING\nnet/mac80211/Kconfig-98-\tbool \"Trace all mac80211 debug messages\"\n--\nnet/mac80211/Kconfig-109-\nnet/mac80211/Kconfig:110:menuconfig MAC80211_DEBUG_MENU\nnet/mac80211/Kconfig-111-\tbool \"Select mac80211 debugging features\"\n--\nnet/mac80211/Kconfig-115-\nnet/mac80211/Kconfig:116:config MAC80211_NOINLINE\nnet/mac80211/Kconfig-117-\tbool \"Do not inline TX/RX handlers\"\n--\nnet/mac80211/Kconfig-131-\nnet/mac80211/Kconfig:132:config MAC80211_VERBOSE_DEBUG\nnet/mac80211/Kconfig-133-\tbool \"Verbose debugging output\"\n--\nnet/mac80211/Kconfig-142-\nnet/mac80211/Kconfig:143:config MAC80211_MLME_DEBUG\nnet/mac80211/Kconfig-144-\tbool \"Verbose managed MLME output\"\n--\nnet/mac80211/Kconfig-153-\nnet/mac80211/Kconfig:154:config MAC80211_STA_DEBUG\nnet/mac80211/Kconfig-155-\tbool \"Verbose station debugging\"\n--\nnet/mac80211/Kconfig-162-\nnet/mac80211/Kconfig:163:config MAC80211_HT_DEBUG\nnet/mac80211/Kconfig-164-\tbool \"Verbose HT debugging\"\n--\nnet/mac80211/Kconfig-174-\nnet/mac80211/Kconfig:175:config MAC80211_OCB_DEBUG\nnet/mac80211/Kconfig-176-\tbool \"Verbose OCB debugging\"\n--\nnet/mac80211/Kconfig-185-\nnet/mac80211/Kconfig:186:config MAC80211_IBSS_DEBUG\nnet/mac80211/Kconfig-187-\tbool \"Verbose IBSS debugging\"\n--\nnet/mac80211/Kconfig-196-\nnet/mac80211/Kconfig:197:config MAC80211_PS_DEBUG\nnet/mac80211/Kconfig-198-\tbool \"Verbose powersave mode debugging\"\n--\nnet/mac80211/Kconfig-208-\nnet/mac80211/Kconfig:209:config MAC80211_MPL_DEBUG\nnet/mac80211/Kconfig-210-\tbool \"Verbose mesh peer link debugging\"\n--\nnet/mac80211/Kconfig-221-\nnet/mac80211/Kconfig:222:config MAC80211_MPATH_DEBUG\nnet/mac80211/Kconfig-223-\tbool \"Verbose mesh path debugging\"\n--\nnet/mac80211/Kconfig-234-\nnet/mac80211/Kconfig:235:config MAC80211_MHWMP_DEBUG\nnet/mac80211/Kconfig-236-\tbool \"Verbose mesh HWMP routing debugging\"\n--\nnet/mac80211/Kconfig-247-\nnet/mac80211/Kconfig:248:config MAC80211_MESH_SYNC_DEBUG\nnet/mac80211/Kconfig-249-\tbool \"Verbose mesh synchronization debugging\"\n--\nnet/mac80211/Kconfig-258-\nnet/mac80211/Kconfig:259:config MAC80211_MESH_CSA_DEBUG\nnet/mac80211/Kconfig-260-\tbool \"Verbose mesh channel switch debugging\"\n--\nnet/mac80211/Kconfig-269-\nnet/mac80211/Kconfig:270:config MAC80211_MESH_PS_DEBUG\nnet/mac80211/Kconfig-271-\tbool \"Verbose mesh powersave debugging\"\n--\nnet/mac80211/Kconfig-280-\nnet/mac80211/Kconfig:281:config MAC80211_TDLS_DEBUG\nnet/mac80211/Kconfig-282-\tbool \"Verbose TDLS debugging\"\n--\nnet/mac80211/Kconfig-292-\nnet/mac80211/Kconfig:293:config MAC80211_DEBUG_COUNTERS\nnet/mac80211/Kconfig-294-\tbool \"Extra statistics for TX/RX debugging\"\n--\nnet/mac80211/Kconfig-307-\nnet/mac80211/Kconfig:308:config MAC80211_STA_HASH_MAX_SIZE\nnet/mac80211/Kconfig-309-\tint \"Station hash table maximum size\" if MAC80211_DEBUG_MENU\n"
} |
| 9/2 | 2026/07/12 10:38 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 9170 output: 41 thoughts: 415 Thoughts: **Fuzzing `MAC80211` Link Management**
Okay, so the config here is definitely `MAC80211`, which narrows things down. I see that the `ieee80211_vif_update_links` function has been touched. My immediate thought is, let's fuzz both `ieee80211_vif_update_links` and `ieee80211_vif_set_links`. These seem like the key entry points for managing and updating links.
I need to quickly check the debugfs removal; specifically `ieee80211_link_debugfs_remove`. Ah, yes, it looks like `MAC80211_DEBUGFS` is required, but hey, `ieee80211_link_stop` is also being called there. This looks interesting and worth a deeper dive.
```c
for_each_set_bit(link_id, &add, IEEE80211_MLD_MAX_NUM_LINKS) {
ieee80211_link_debugfs_remove(&links[link_id]->data);
ieee80211_link_stop(&links[link_id]->data);
}
```
Now, the question is how to test this. Is `mac80211_hwsim` enough for this? Considering that `mac80211_hwsim` *is* a `mac80211` user and it's capable of simulating Multiple Link Device (MLD), it should be fine. It is reachable via `mac80211_hwsim` or even the `nl80211` netlink interface.
Hold on, the prompt mentions something about unreachable code paths in virtualized environments. But this is definitely reachable via both `mac80211_hwsim` and `nl80211`! I'll have to keep that caveat in mind.
Finally, `ieee80211_vif_set_links` is invoked during interface configuration, link additions, and the like. That's a crucial point, and I need to fully understand its interaction with `ieee80211_vif_update_links`. Let me check `ieee80211_vif_update_links` in `net/mac80211/link.c` right now.
|
| 10/2 | 2026/07/12 10:39 | tool | read-file |
0mArgs:{
"File": "net/mac80211/link.c",
"FirstLine": 280,
"LineCount": 100
}Results: {
"Contents": " 280:\t\t\tWARN_ON(hweight16(sdata-\u003evif.active_links) \u003e 1);\n 281:\t\t\tbreak;\n 282:\t\tdefault:\n 283:\t\t\tWARN_ON(1);\n 284:\t\t}\n 285:\t}\n 286:\t\n 287:\tstatic int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,\n 288:\t\t\t\t\t struct link_container **to_free,\n 289:\t\t\t\t\t u16 new_links, u16 dormant_links)\n 290:\t{\n 291:\t\tu16 old_links = sdata-\u003evif.valid_links;\n 292:\t\tu16 old_active = sdata-\u003evif.active_links;\n 293:\t\tunsigned long add = new_links \u0026 ~old_links;\n 294:\t\tunsigned long rem = old_links \u0026 ~new_links;\n 295:\t\tunsigned long sta_rem = rem;\n 296:\t\tunsigned int link_id;\n 297:\t\tint ret;\n 298:\t\tstruct link_container *links[IEEE80211_MLD_MAX_NUM_LINKS] = {}, *link;\n 299:\t\tstruct ieee80211_bss_conf *old[IEEE80211_MLD_MAX_NUM_LINKS];\n 300:\t\tstruct ieee80211_link_data *old_data[IEEE80211_MLD_MAX_NUM_LINKS];\n 301:\t\tbool use_deflink = old_links == 0; /* set for error case */\n 302:\t\tbool non_sta = sdata-\u003evif.type != NL80211_IFTYPE_STATION;\n 303:\t\tstruct sta_info *sta;\n 304:\t\n 305:\t\tlockdep_assert_wiphy(sdata-\u003elocal-\u003ehw.wiphy);\n 306:\t\n 307:\t\tmemset(to_free, 0, sizeof(links));\n 308:\t\n 309:\t\tif (old_links == new_links \u0026\u0026 dormant_links == sdata-\u003evif.dormant_links)\n 310:\t\t\treturn 0;\n 311:\t\n 312:\t\tif (!old_links || !new_links)\n 313:\t\t\tWARN_ON(sta_info_flush(sdata, -1) \u003e 0);\n 314:\t\n 315:\t\t/* if there were no old links, need to clear the pointers to deflink */\n 316:\t\tif (!old_links)\n 317:\t\t\trem |= BIT(0);\n 318:\t\n 319:\t\t/* allocate new link structures first */\n 320:\t\tfor_each_set_bit(link_id, \u0026add, IEEE80211_MLD_MAX_NUM_LINKS) {\n 321:\t\t\tlink = kzalloc_obj(*link);\n 322:\t\t\tif (!link) {\n 323:\t\t\t\tret = -ENOMEM;\n 324:\t\t\t\tgoto free;\n 325:\t\t\t}\n 326:\t\t\tlinks[link_id] = link;\n 327:\t\t}\n 328:\t\n 329:\t\t/* keep track of the old pointers for the driver */\n 330:\t\tBUILD_BUG_ON(sizeof(old) != sizeof(sdata-\u003evif.link_conf));\n 331:\t\tmemcpy(old, sdata-\u003evif.link_conf, sizeof(old));\n 332:\t\t/* and for us in error cases */\n 333:\t\tBUILD_BUG_ON(sizeof(old_data) != sizeof(sdata-\u003elink));\n 334:\t\tmemcpy(old_data, sdata-\u003elink, sizeof(old_data));\n 335:\t\n 336:\t\t/* grab old links to free later */\n 337:\t\tfor_each_set_bit(link_id, \u0026rem, IEEE80211_MLD_MAX_NUM_LINKS) {\n 338:\t\t\tif (rcu_access_pointer(sdata-\u003elink[link_id]) != \u0026sdata-\u003edeflink) {\n 339:\t\t\t\t/*\n 340:\t\t\t\t * we must have allocated the data through this path so\n 341:\t\t\t\t * we know we can free both at the same time\n 342:\t\t\t\t */\n 343:\t\t\t\tto_free[link_id] = container_of(rcu_access_pointer(sdata-\u003elink[link_id]),\n 344:\t\t\t\t\t\t\t\ttypeof(*links[link_id]),\n 345:\t\t\t\t\t\t\t\tdata);\n 346:\t\t\t}\n 347:\t\n 348:\t\t\tRCU_INIT_POINTER(sdata-\u003elink[link_id], NULL);\n 349:\t\t\tRCU_INIT_POINTER(sdata-\u003evif.link_conf[link_id], NULL);\n 350:\t\t}\n 351:\t\n 352:\t\tif (!old_links)\n 353:\t\t\tieee80211_debugfs_recreate_netdev(sdata, true);\n 354:\t\n 355:\t\t/* link them into data structures */\n 356:\t\tfor_each_set_bit(link_id, \u0026add, IEEE80211_MLD_MAX_NUM_LINKS) {\n 357:\t\t\tWARN_ON(!use_deflink \u0026\u0026\n 358:\t\t\t\trcu_access_pointer(sdata-\u003elink[link_id]) == \u0026sdata-\u003edeflink);\n 359:\t\n 360:\t\t\tlink = links[link_id];\n 361:\t\t\tieee80211_link_init(sdata, link_id, \u0026link-\u003edata, \u0026link-\u003econf);\n 362:\t\t\tieee80211_link_setup(\u0026link-\u003edata);\n 363:\t\t\tieee80211_set_wmm_default(\u0026link-\u003edata, true, non_sta);\n 364:\t\t}\n 365:\t\n 366:\t\tif (new_links == 0)\n 367:\t\t\tieee80211_link_init(sdata, -1, \u0026sdata-\u003edeflink,\n 368:\t\t\t\t\t \u0026sdata-\u003evif.bss_conf);\n 369:\t\n 370:\t\tret = ieee80211_check_dup_link_addrs(sdata);\n 371:\t\tif (!ret) {\n 372:\t\t\t/* for keys we will not be able to undo this */\n 373:\t\t\tieee80211_tear_down_links(sdata, to_free, rem);\n 374:\t\n 375:\t\t\tieee80211_set_vif_links_bitmaps(sdata, new_links, dormant_links);\n 376:\t\n 377:\t\t\t/* tell the driver */\n 378:\t\t\tif (sdata-\u003evif.type != NL80211_IFTYPE_AP_VLAN)\n 379:\t\t\t\tret = drv_change_vif_links(sdata-\u003elocal, sdata,\n"
} |
| 11/2 | 2026/07/12 10:39 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 12041 output: 41 thoughts: 10 Thoughts: Okay, here's my interpretation of that thought process, tailored for an expert audience, and written in the first person: **Analyzing the Function's Context** Right, so I've just been prompted to assess some code or a description of a function. The immediate thought is, *I need more information*. I'm not going to jump to any conclusions based on just a snippet. I know from experience that the most efficient way to understand its purpose and inner workings is to see the whole thing, or at least a significant portion of it. I want to look at the surrounding code, the data it operates on, and how it interacts with the broader system. I need to understand its entry points, and its dependencies. This "Let's read the rest of the function" is crucial; I understand the importance of complete context to make a sound evaluation. |
| 12/2 | 2026/07/12 10:39 | tool | read-file |
0mArgs:{
"File": "net/mac80211/link.c",
"FirstLine": 380,
"LineCount": 100
}Results: {
"Contents": " 380:\t\t\t\t\t\t\t old_links \u0026 old_active,\n 381:\t\t\t\t\t\t\t new_links \u0026 sdata-\u003evif.active_links,\n 382:\t\t\t\t\t\t\t old);\n 383:\t\t\tif (!new_links)\n 384:\t\t\t\tieee80211_debugfs_recreate_netdev(sdata, false);\n 385:\t\n 386:\t\t\tif (sdata-\u003evif.type == NL80211_IFTYPE_AP)\n 387:\t\t\t\tieee80211_update_apvlan_links(sdata);\n 388:\t\t}\n 389:\t\n 390:\t\t/*\n 391:\t\t * Ignore errors if we are only removing links as removal should\n 392:\t\t * always succeed\n 393:\t\t */\n 394:\t\tif (!new_links)\n 395:\t\t\tret = 0;\n 396:\t\n 397:\t\tif (ret) {\n 398:\t\t\t/* restore config */\n 399:\t\t\tmemcpy(sdata-\u003elink, old_data, sizeof(old_data));\n 400:\t\t\tmemcpy(sdata-\u003evif.link_conf, old, sizeof(old));\n 401:\t\t\tieee80211_set_vif_links_bitmaps(sdata, old_links, dormant_links);\n 402:\t\t\tfor_each_set_bit(link_id, \u0026add, IEEE80211_MLD_MAX_NUM_LINKS) {\n 403:\t\t\t\tieee80211_link_debugfs_remove(\u0026links[link_id]-\u003edata);\n 404:\t\t\t\tieee80211_link_stop(\u0026links[link_id]-\u003edata);\n 405:\t\t\t}\n 406:\t\t\t/* and free (only) the newly allocated links */\n 407:\t\t\tmemset(to_free, 0, sizeof(links));\n 408:\t\t\tgoto free;\n 409:\t\t}\n 410:\t\n 411:\t\t/* try to remove links that are now invalid from (MLO) stations */\n 412:\t\tlist_for_each_entry(sta, \u0026sdata-\u003elocal-\u003esta_list, list) {\n 413:\t\t\tunsigned long rem_links = sta-\u003esta.valid_links \u0026 sta_rem;\n 414:\t\n 415:\t\t\tif (sta-\u003esdata != sdata)\n 416:\t\t\t\tcontinue;\n 417:\t\n 418:\t\t\t/*\n 419:\t\t\t * skip stations that would have no links left,\n 420:\t\t\t * those will be removed completely later\n 421:\t\t\t */\n 422:\t\t\tif (sta-\u003esta.valid_links == rem_links)\n 423:\t\t\t\tcontinue;\n 424:\t\n 425:\t\t\tfor_each_set_bit(link_id, \u0026rem_links,\n 426:\t\t\t\t\t IEEE80211_MLD_MAX_NUM_LINKS)\n 427:\t\t\t\tieee80211_sta_remove_link(sta, link_id);\n 428:\t\t}\n 429:\t\n 430:\t\t/*\n 431:\t\t * Remove stations using any removed links. Note that due\n 432:\t\t * to the above station link removal, this only removes\n 433:\t\t * stations that were skipped above because they'd have no\n 434:\t\t * links left after link removal.\n 435:\t\t */\n 436:\t\tfor_each_set_bit(link_id, \u0026sta_rem, IEEE80211_MLD_MAX_NUM_LINKS)\n 437:\t\t\tsta_info_flush(sdata, link_id);\n 438:\t\n 439:\t\t/* use deflink/bss_conf again if and only if there are no more links */\n 440:\t\tuse_deflink = new_links == 0;\n 441:\t\n 442:\t\tgoto deinit;\n 443:\tfree:\n 444:\t\t/* if we failed during allocation, only free all */\n 445:\t\tfor (link_id = 0; link_id \u003c IEEE80211_MLD_MAX_NUM_LINKS; link_id++) {\n 446:\t\t\tkfree(links[link_id]);\n 447:\t\t\tlinks[link_id] = NULL;\n 448:\t\t}\n 449:\tdeinit:\n 450:\t\tif (use_deflink)\n 451:\t\t\tieee80211_link_init(sdata, -1, \u0026sdata-\u003edeflink,\n 452:\t\t\t\t\t \u0026sdata-\u003evif.bss_conf);\n 453:\t\treturn ret;\n 454:\t}\n 455:\t\n 456:\tint ieee80211_vif_set_links(struct ieee80211_sub_if_data *sdata,\n 457:\t\t\t\t u16 new_links, u16 dormant_links)\n 458:\t{\n 459:\t\tstruct link_container *links[IEEE80211_MLD_MAX_NUM_LINKS];\n 460:\t\tint ret;\n 461:\t\n 462:\t\tret = ieee80211_vif_update_links(sdata, links, new_links,\n 463:\t\t\t\t\t\t dormant_links);\n 464:\t\tieee80211_free_links(sdata, links);\n 465:\t\n 466:\t\treturn ret;\n 467:\t}\n 468:\t\n 469:\tstatic int _ieee80211_set_active_links(struct ieee80211_sub_if_data *sdata,\n 470:\t\t\t\t\t u16 active_links)\n 471:\t{\n 472:\t\tstruct ieee80211_bss_conf *link_confs[IEEE80211_MLD_MAX_NUM_LINKS];\n 473:\t\tstruct ieee80211_local *local = sdata-\u003elocal;\n 474:\t\tu16 old_active = sdata-\u003evif.active_links;\n 475:\t\tunsigned long rem = old_active \u0026 ~active_links;\n 476:\t\tunsigned long add = active_links \u0026 ~old_active;\n 477:\t\tstruct sta_info *sta;\n 478:\t\tunsigned int link_id;\n 479:\t\tint ret, i;\n"
} |
| 13/2 | 2026/07/12 10:39 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 13975 output: 43 thoughts: 255 Thoughts: **Analyzing the New Error Cleanup Patch** Okay, so this patch introduces error cleanup within `ieee80211_vif_update_links` for these freshly added links. That's a functional improvement, definitely worth looking at. And, I know for a fact that `ieee80211_vif_update_links` is a reachable function, so we can consider that as something that can be fuzzed. Given this, I'm thinking we should zero in on fuzzing `ieee80211_vif_set_links` and `ieee80211_vif_update_links`. Hold on, let me quickly confirm if `ieee80211_vif_update_links` is static... Yep, it is. Alright, so the real focus should be on `ieee80211_vif_set_links` then. Now, what about the config options? The primary one seems to be `MAC80211`, but I'll quickly check for any others. Okay, maybe `MAC80211_DEBUGFS`? The patch *does* call `ieee80211_link_debugfs_remove`, but it also calls `ieee80211_link_stop`, so that might be relevant. Best to double-check that `ieee80211_link_debugfs_remove` function definition, just to be sure. |
| 14/2 | 2026/07/12 10:39 | tool | grepper |
0mArgs:{
"Expression": "ieee80211_link_debugfs_remove",
"PathPrefix": "net/mac80211/"
}Results: {
"Output": "net/mac80211/debugfs_netdev.c=1043=void ieee80211_link_debugfs_add(struct ieee80211_link_data *link)\n--\nnet/mac80211/debugfs_netdev.c-1064-\nnet/mac80211/debugfs_netdev.c:1065:void ieee80211_link_debugfs_remove(struct ieee80211_link_data *link)\nnet/mac80211/debugfs_netdev.c-1066-{\n--\nnet/mac80211/debugfs_netdev.h=19=void ieee80211_link_debugfs_add(struct ieee80211_link_data *link);\nnet/mac80211/debugfs_netdev.h:20:void ieee80211_link_debugfs_remove(struct ieee80211_link_data *link);\nnet/mac80211/debugfs_netdev.h-21-\n--\nnet/mac80211/debugfs_netdev.h=34=static inline void ieee80211_link_debugfs_add(struct ieee80211_link_data *link)\nnet/mac80211/debugfs_netdev.h-35-{}\nnet/mac80211/debugfs_netdev.h:36:static inline void ieee80211_link_debugfs_remove(struct ieee80211_link_data *link)\nnet/mac80211/debugfs_netdev.h-37-{}\n--\nnet/mac80211/link.c=191=static void ieee80211_tear_down_links(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/link.c-206-\t\tieee80211_remove_link_keys(link, \u0026keys);\nnet/mac80211/link.c:207:\t\tieee80211_link_debugfs_remove(link);\nnet/mac80211/link.c-208-\t\tieee80211_link_stop(link);\n--\nnet/mac80211/link.c=287=static int ieee80211_vif_update_links(struct ieee80211_sub_if_data *sdata,\n--\nnet/mac80211/link.c-402-\t\tfor_each_set_bit(link_id, \u0026add, IEEE80211_MLD_MAX_NUM_LINKS) {\nnet/mac80211/link.c:403:\t\t\tieee80211_link_debugfs_remove(\u0026links[link_id]-\u003edata);\nnet/mac80211/link.c-404-\t\t\tieee80211_link_stop(\u0026links[link_id]-\u003edata);\n"
} |
| 15/2 | 2026/07/12 10:39 | llm | patch-evaluator |
0mModel:gemini-3.1-pro-preview Args: null Results: null Tokens: input: 15400 output: 144 thoughts: 474 Thoughts: **Analyzing the Patch for Fuzzing Potential** Okay, so I'm looking at this patch and trying to determine if it's worth fuzzing. The key here is to see if it modifies code that's reachable and potentially introduces new fuzzing targets. My initial thought is that since `ieee80211_link_debugfs_remove` is a no-op when `MAC80211_DEBUGFS` isn't set, and `ieee80211_link_stop` always runs, we likely don't need to consider the debugfs option. `MAC80211` itself is the crucial component here. My strategy is to confirm if `MAC80211` is enough, or if we require `MAC80211_HWSIM` or something similar for the code to be accessible, which is essential to determine if it is worth fuzzing. I've pinpointed `ieee80211_vif_set_links` as the main entry point for the logic involved and I'm adding it, along with `ieee80211_vif_update_links`, to `FocusSymbols`. Now, reviewing the prompt's criteria for `WorthFuzzing=false`, this patch seems to avoid those pitfalls. It deals with core mac80211 logic, which I know is reachable even in a simulated hardware environment like `mac80211_hwsim`. Crucially, this patch addresses a resource leak or state inconsistency on an error path, a classic area for potential fuzzing. Given this, I'm confident in setting `WorthFuzzing=true`. For the fuzzing configuration, I'll enable `MAC80211`, and my specific focus will be on the `ieee80211_vif_set_links` and `ieee80211_vif_update_links` functions. I quickly double-checked if `ieee80211_vif_update_links` is static. It is, but that's not a deal-breaker. Syzkaller can still reach those functions if they are part of the call tree, so I'm keeping both as targets. Time to set these results and move on. |
| 16/2 | 2026/07/12 10:39 | tool | set-results |
0mArgs:{
"EnableConfigs": [
"MAC80211"
],
"FocusSymbols": [
"ieee80211_vif_set_links",
"ieee80211_vif_update_links"
],
"Reasoning": "The patch adds error handling cleanup in `ieee80211_vif_update_links` to stop and remove debugfs for newly allocated links if an error occurs. This is a functional change in the mac80211 core subsystem, reachable via software-emulated hardware like mac80211_hwsim.",
"WorthFuzzing": true
}Results: {
"EnableConfigs": [
"MAC80211"
],
"FocusSymbols": [
"ieee80211_vif_set_links",
"ieee80211_vif_update_links"
],
"Reasoning": "The patch adds error handling cleanup in `ieee80211_vif_update_links` to stop and remove debugfs for newly allocated links if an error occurs. This is a functional change in the mac80211 core subsystem, reachable via software-emulated hardware like mac80211_hwsim.",
"WorthFuzzing": true
} |
| Total Calls | Total Tokens | Avg Tokens | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|
| Total Calls | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|