| Seq | Timestamp | Type | Name | Duration |
|---|---|---|---|---|
| 0/0 | 2026/09/19 11:55 | flow | patch-triage |
0mArgs:null Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"KMSANReasoning": "",
"NeedsKMSAN": false,
"Reasoning": "The patch adds a missing of_node_put() in an error path within of_unittest_pci_dma_ranges() in drivers/of/unittest.c. This is part of the Device Tree unit test suite and is marked __init, executed solely once during kernel boot (late_initcall) before userspace starts, after which init memory is released. It cannot be reached or exercised by syzkaller fuzzing.",
"WorthFuzzing": false
} |
| 1/1 | 2026/09/19 11:55 | action | read-patch-diff |
0mArgs:null Results: {
"PatchDiff": "commit 591285dfcbd749ce712d2c5dc314d6e01acd9cba\nAuthor: syz-cluster \u003ctriage@syzkaller.com\u003e\nDate: Sat Sep 19 11:55:33 2026 +0000\n\n syz-cluster: applied patch under review\n\ndiff --git a/drivers/of/unittest.c b/drivers/of/unittest.c\nindex e255f54f4d760..c5fefc5131b67 100644\n--- a/drivers/of/unittest.c\n+++ b/drivers/of/unittest.c\n@@ -1221,6 +1221,7 @@ static void __init of_unittest_pci_dma_ranges(void)\n \n \tif (of_pci_dma_range_parser_init(\u0026parser, np)) {\n \t\tpr_err(\"missing dma-ranges property\\n\");\n+\t\tof_node_put(np);\n \t\treturn;\n \t}\n \n"
} |
| 2/1 | 2026/09/19 11:55 | agent | patch-evaluator |
0mModel:core Args: null Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"Reasoning": "The patch adds a missing of_node_put() in an error path within of_unittest_pci_dma_ranges() in drivers/of/unittest.c. This is part of the Device Tree unit test suite and is marked __init, executed solely once during kernel boot (late_initcall) before userspace starts, after which init memory is released. It cannot be reached or exercised by syzkaller fuzzing.",
"WorthFuzzing": false
}Instruction: You are an expert Linux kernel maintainer and security engineer.
Your job is to review a provided patch series and evaluate whether it warrants fuzzing with syzkaller.
IMPORTANT: The changes have ALREADY been applied and committed as the HEAD commit in
your workspace. Do NOT rely on internal assumptions. You must actively use your code access
tools to inspect the actual source code, callers, and surrounding context.
================================================================================
1. CORE TRIAGE PHILOSOPHY
================================================================================
The goal of patch fuzzing is to discover crashes, regressions, exposed latent bugs,
and newly triggered assertions introduced by the patch series.
- REACHABILITY IS THE PRIMARY GATE:
Fuzzing can only discover bugs in code that can actually execute in standard virtualized
environments (GCE or QEMU, utilizing software-emulated devices like USB gadgets, netdev, tun/tap).
If the modified code is structurally unreachable (see Section 2), it MUST NOT be fuzzed,
regardless of whether it adds assertions or complex logic.
- DO NOT BLINDLY TRUST "NO FUNCTIONAL CHANGE" (NFCI) OR "REFACTORING" CLAIMS:
Patch authors routinely label changes as "cleanups", "refactorings", or state
"No functional change intended". Do NOT take these claims at face value.
Code refactorings that rearrange logic, introduce helper functions, or alter state management
in core subsystems frequently introduce subtle semantic shifts or uncover latent kernel bugs.
If reachable executable code is modified or refactored, it MUST be fuzzed.
- NEW OR MODIFIED ASSERTIONS IN REACHABLE CODE MUST BE FUZZED:
When a patch introduces or modifies runtime checks or assertions (e.g., WARN_ON*, VM_WARN_ON*,
BUG_ON*, lockdep_assert*) in reachable code paths, it enforces new or stricter invariants.
Even if the author believes the invariant always holds, fuzzing is essential to verify whether
an unusual sequence of operations can violate it.
================================================================================
2. WHEN TO RETURN WorthFuzzing=false (NEGATIVE CRITERIA)
================================================================================
Return WorthFuzzing=false ONLY IF all modified code falls strictly into one or more of these categories:
- Non-kernel and non-executable changes:
* Modifications to Documentation/, comments, or spelling fixes.
* User-space directories, self-tests, samples, or scripts (e.g., tools/, samples/, scripts/, usr/)
that do not affect the compiled kernel image (vmlinux) or kernel modules.
* Purely decorative logging (e.g., message strings in pr_err, printk, dev_info) or tracepoints
that do not alter control flow or data structures.
* Build system or Kconfig changes that do not alter compiled C logic.
- Structurally unreachable hardware:
* Vendor-specific PCIe switches, SmartNICs, or GPU drivers (e.g., mlxsw, pds_core, qed,
ionic, amdgpu) requiring physical ASIC/PCIe cards not emulated in standard QEMU.
- Unreachable execution paths:
* Driver teardown callbacks (.remove, .shutdown, pci_unregister_driver) executed only during
physical PCI hot-unplug or manual sysfs driver unbinding.
* Code paths exclusive to architectures other than the target architecture.
================================================================================
3. WHEN TO RETURN WorthFuzzing=true (POSITIVE CRITERIA)
================================================================================
Return WorthFuzzing=true whenever the patch touches reachable executable code, including:
- Core Subsystems:
* Any logic modifications in memory management (mm/), synchronization/locking (kernel/locking/),
BPF, scheduler, core networking, VFS, or syscall handling.
- Refactorings and Code Cleanups:
* Any restructuring of reachable data structures, helper abstractions, or algorithm flows.
- Runtime Assertions and Defensive Checks:
* Any introduction or alteration of assertions (WARN_ON*, VM_WARN_ON*, BUG_ON*, etc.) in reachable paths.
- Reachable Drivers and Protocols:
* Drivers accessible via virtual buses (virtio, USB gadget, loopback, netlink, binder, sockets, etc.).
================================================================================
4. EXTRACTING FocusSymbols (PREVENTING DILUTION)
================================================================================
When WorthFuzzing=true, you must extract specific kernel functions into FocusSymbols to guide the fuzzer:
- AVOID UBIQUITOUS LIFECYCLE HOT-PATHS:
Do NOT list generic, ubiquitous functions called by almost every program in the corpus
(including, but not limited to: general memory allocators and deallocators, page fault
and trap handlers, or core synchronization primitives; this is not an exhaustive list).
Listing ubiquitous functions causes the fuzzer to classify thousands of unrelated tests as "focused",
which severely dilutes fuzzing effort away from the actual changes.
- TARGET SPECIFIC FEATURE LOGIC AND ENTRYPOINTS:
List functions that specifically implement the logic being added or altered, or direct API entrypoints
for the subsystem feature under review.
- HANDLING STATIC INLINE FUNCTIONS IN HEADERS (.h):
Compiler-inlined static functions (such as static inlines in mm/*.h or include/linux/*.h) lack
distinct symbol addresses in vmlinux and cannot be targeted directly by symbol coverage filters.
If the changes are primarily in static inline helpers, identify non-static, feature-specific caller
functions in .c files that exercise them (avoiding ubiquitous lifecycle wrappers).
================================================================================
5. IDENTIFYING EnableConfigs
================================================================================
Identify any specific CONFIG_ options required to properly compile and reach the modified code:
- Inspect Kconfig files and #ifdef guards; do not make assumptions.
- Check "depends on" lines in Kconfig to include any non-standard parent subsystem configs needed.
- Strip any '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: Target architecture: amd64
For your convenience, here is the diff of the changes:
commit 591285dfcbd749ce712d2c5dc314d6e01acd9cba
Author: syz-cluster <triage@syzkaller.com>
Date: Sat Sep 19 11:55:33 2026 +0000
syz-cluster: applied patch under review
diff --git a/drivers/of/unittest.c b/drivers/of/unittest.c
index e255f54f4d760..c5fefc5131b67 100644
--- a/drivers/of/unittest.c
+++ b/drivers/of/unittest.c
@@ -1221,6 +1221,7 @@ static void __init of_unittest_pci_dma_ranges(void)
if (of_pci_dma_range_parser_init(&parser, np)) {
pr_err("missing dma-ranges property\n");
+ of_node_put(np);
return;
}
|
| 3/2 | 2026/09/19 11:55 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 2836 output: 36 thoughts: 282 Thoughts: **Analyzing a Patch: A Quick Deep Dive** Okay, let's break this down. First, I see a patch, and it looks like it touches `drivers/of/unittest.c`. I immediately zoom in on the specific function modified: `static void __init of_unittest_pci_dma_ranges(void)`. The `__init` tag is a clear signal; this is initialization code. It needs to be examined from a global context. My instinct is to understand how this function is called and its overall role. I'm seeing a missing `of_node_put(np);` which indicates a potential resource leak if initialization fails, good catch! I'll quickly need to verify how and where it is called and used. I'll need to use my usual tools to understand this function. I'll reach for a `read-file` or `grepper` to trace the call paths and gain a full picture. |
| 4/2 | 2026/09/19 11:55 | tool | read-file |
0mArgs:{
"File": "drivers/of/unittest.c",
"FirstLine": 1210,
"LineCount": 30
}Results: {
"Contents": "1210:\t\tstruct of_pci_range_parser parser;\n1211:\t\tint i = 0;\n1212:\t\n1213:\t\tif (!IS_ENABLED(CONFIG_PCI))\n1214:\t\t\treturn;\n1215:\t\n1216:\t\tnp = of_find_node_by_path(\"/testcase-data/address-tests/pci@90000000\");\n1217:\t\tif (!np) {\n1218:\t\t\tpr_err(\"missing testcase data\\n\");\n1219:\t\t\treturn;\n1220:\t\t}\n1221:\t\n1222:\t\tif (of_pci_dma_range_parser_init(\u0026parser, np)) {\n1223:\t\t\tpr_err(\"missing dma-ranges property\\n\");\n1224:\t\t\tof_node_put(np);\n1225:\t\t\treturn;\n1226:\t\t}\n1227:\t\n1228:\t\t/*\n1229:\t\t * Get the dma-ranges from the device tree\n1230:\t\t */\n1231:\t\tfor_each_of_pci_range(\u0026parser, \u0026range) {\n1232:\t\t\tif (!i) {\n1233:\t\t\t\tunittest(range.size == 0x10000000,\n1234:\t\t\t\t\t \"for_each_of_pci_range wrong size on node %pOF size=%llx\\n\",\n1235:\t\t\t\t\t np, range.size);\n1236:\t\t\t\tunittest(range.cpu_addr == 0x20000000,\n1237:\t\t\t\t\t \"for_each_of_pci_range wrong CPU addr (%llx) on node %pOF\",\n1238:\t\t\t\t\t range.cpu_addr, np);\n1239:\t\t\t\tunittest(range.pci_addr == 0x80000000,\n"
} |
| 5/2 | 2026/09/19 11:55 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 3860 output: 35 thoughts: 22 Thoughts: Here's my attempt at summarizing the thought process, tailored for an expert audience: **Investigating `of_unittest_pci_dma_ranges` Call Sites** Okay, so I've come across `of_unittest_pci_dma_ranges` and my first thought is, "Where's this function actually *used*?". It's a pretty straightforward debugging step, of course. I need to understand the context and flow that leads to it being executed. Knowing the call sites will immediately give me a clue about the component of the system it pertains to. Is it invoked during device initialization, perhaps during resource assignment, or is it part of a test harness, as the name hints? Finding those call sites is the essential next step towards grasping its role. Let's dig in and figure out where this function is triggered. |
| 6/2 | 2026/09/19 11:55 | tool | grepper |
0mArgs:{
"Expression": "of_unittest_pci_dma_ranges",
"PathPrefix": "drivers/of/"
}Results: {
"Output": "drivers/of/unittest.c=1195=static void __init of_unittest_parse_dma_ranges(void)\n--\ndrivers/of/unittest.c-1205-\ndrivers/of/unittest.c:1206:static void __init of_unittest_pci_dma_ranges(void)\ndrivers/of/unittest.c-1207-{\n--\ndrivers/of/unittest.c=4507=static int __init of_unittest(void)\n--\ndrivers/of/unittest.c-4547-\tof_unittest_parse_dma_ranges();\ndrivers/of/unittest.c:4548:\tof_unittest_pci_dma_ranges();\ndrivers/of/unittest.c-4549-\tof_unittest_pci_empty_dma_ranges();\n"
} |
| 7/2 | 2026/09/19 11:55 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 4310 output: 36 thoughts: 47 Thoughts: Here's my summary, as though I'm thinking through this process: **Diving into the `of_unittest_pci_dma_ranges` Call Chain** Okay, so I'm looking at `of_unittest_pci_dma_ranges`. I see that it's called from `of_unittest`. Right off the bat, I note that `of_unittest` is a static function that's marked as `__init`. This means it's likely part of the module initialization process, probably setting up something at boot time. Now, my next move is clear: I need to figure out exactly *how* `of_unittest` itself is getting registered or invoked. Understanding that call chain is the key to understanding why and when `of_unittest_pci_dma_ranges` is being used. I need to trace this back and see if there are any interesting uses. |
| 8/2 | 2026/09/19 11:55 | tool | read-file |
0mArgs:{
"File": "drivers/of/unittest.c",
"FirstLine": 4505,
"LineCount": 70
}Results: {
"Contents": "4505:\t#endif\n4506:\t\n4507:\tstatic int __init of_unittest(void)\n4508:\t{\n4509:\t\tstruct device_node *np;\n4510:\t\tint res;\n4511:\t\n4512:\t\tpr_info(\"start of unittest - you will see error messages\\n\");\n4513:\t\n4514:\t\t/* Taint the kernel so we know we've run tests. */\n4515:\t\tadd_taint(TAINT_TEST, LOCKDEP_STILL_OK);\n4516:\t\n4517:\t\t/* adding data for unittest */\n4518:\t\tres = unittest_data_add();\n4519:\t\tif (res)\n4520:\t\t\treturn res;\n4521:\t\tif (!of_aliases)\n4522:\t\t\tof_aliases = of_find_node_by_path(\"/aliases\");\n4523:\t\n4524:\t\tnp = of_find_node_by_path(\"/testcase-data/phandle-tests/consumer-a\");\n4525:\t\tif (!np) {\n4526:\t\t\tpr_info(\"No testcase data in device tree; not running tests\\n\");\n4527:\t\t\treturn 0;\n4528:\t\t}\n4529:\t\tof_node_put(np);\n4530:\t\n4531:\t\tof_unittest_check_tree_linkage();\n4532:\t\tof_unittest_check_phandles();\n4533:\t\tof_unittest_find_node_by_name();\n4534:\t\tof_unittest_dynamic();\n4535:\t\tof_unittest_parse_phandle_with_args();\n4536:\t\tof_unittest_parse_phandle_with_args_map();\n4537:\t\tof_unittest_printf();\n4538:\t\tof_unittest_property_string();\n4539:\t\tof_unittest_property_copy();\n4540:\t\tof_unittest_changeset();\n4541:\t\tof_unittest_changeset_prop();\n4542:\t\tof_unittest_parse_interrupts();\n4543:\t\tof_unittest_parse_interrupts_extended();\n4544:\t\tof_unittest_parse_interrupt_map();\n4545:\t\tof_unittest_irq_refcount();\n4546:\t\tof_unittest_dma_get_max_cpu_address();\n4547:\t\tof_unittest_parse_dma_ranges();\n4548:\t\tof_unittest_pci_dma_ranges();\n4549:\t\tof_unittest_pci_empty_dma_ranges();\n4550:\t\tof_unittest_bus_ranges();\n4551:\t\tof_unittest_bus_3cell_ranges();\n4552:\t\tof_unittest_reg();\n4553:\t\tof_unittest_translate_addr();\n4554:\t\tof_unittest_match_node();\n4555:\t\tof_unittest_platform_populate();\n4556:\t\tof_unittest_overlay();\n4557:\t\tof_unittest_lifecycle();\n4558:\t\tof_unittest_pci_node();\n4559:\t\n4560:\t\t/* Double check linkage after removing testcase data */\n4561:\t\tof_unittest_check_tree_linkage();\n4562:\t\n4563:\t\tof_unittest_overlay_high_level();\n4564:\t\n4565:\t\tpr_info(\"end of unittest - %i passed, %i failed\\n\",\n4566:\t\t\tunittest_results.passed, unittest_results.failed);\n4567:\t\n4568:\t\treturn 0;\n4569:\t}\n4570:\tlate_initcall(of_unittest);\n"
} |
| 9/2 | 2026/09/19 11:55 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 5584 output: 27 thoughts: 203 Thoughts: **Analyzing the Accessibility of `of_unittest` for Fuzzing** Okay, so `of_unittest` is a `late_initcall`, meaning it gets called during kernel boot initialization, and only if `CONFIG_OF_UNITTEST` is enabled, making it an internal self-test residing in `drivers/of/unittest.c`. My immediate question is: can a user-space fuzzer like syzkaller possibly reach the `of_unittest_pci_dma_ranges` function? It's a boot-time function indicated by the `__init` tag, so it will be discarded during memory freeing by `free_initmem()`, immediately after boot is complete! That means that the `of_unittest` code is gone from memory once the kernel is fully booted. But hold on, let's not jump to conclusions. I need to be thorough. Let's explore any potential avenues where `of_unittest` or, more specifically, `of_unittest_pci_dma_ranges`, could be invoked. Could there be a debugfs or sysfs entry or anything else allowing access? The standard approach would be to grep for `of_unittest` in the `drivers/of/` directory. That's the next step to confirm this. |
| 10/2 | 2026/09/19 11:56 | tool | grepper |
0mArgs:{
"Expression": "of_unittest",
"PathPrefix": "drivers/of/"
}Results: {
"Output": "\nFull output is too long, showing 500 out of 643 lines.\nUse more precise expression if possible.\n\ndrivers/of/Kconfig=21=config OF_UNITTEST\n--\ndrivers/of/Kconfig-38-\t via capturing the console output or via the dmesg command. Process\ndrivers/of/Kconfig:39:\t this file with scripts/dtc/of_unittest_expect to reduce the\ndrivers/of/Kconfig-40-\t verbosity, test whether expected output is present, and to\n--\ndrivers/of/overlay.c=751=static int init_overlay_changeset(struct overlay_changeset *ovcs,\n--\ndrivers/of/overlay.c-767-\t * Warn for some issues. Can not return -EINVAL for these until\ndrivers/of/overlay.c:768:\t * of_unittest_apply_overlay() is fixed to pass these checks.\ndrivers/of/overlay.c-769-\t */\n--\ndrivers/of/unittest.c=36=static struct unittest_results {\n--\ndrivers/of/unittest.c-79-\ndrivers/of/unittest.c:80:static void __init of_unittest_find_node_by_name(void)\ndrivers/of/unittest.c-81-{\n--\ndrivers/of/unittest.c-187-\ndrivers/of/unittest.c:188:static void __init of_unittest_dynamic(void)\ndrivers/of/unittest.c-189-{\n--\ndrivers/of/unittest.c-248-\ndrivers/of/unittest.c:249:static int __init of_unittest_check_node_linkage(struct device_node *np)\ndrivers/of/unittest.c-250-{\n--\ndrivers/of/unittest.c-259-\ndrivers/of/unittest.c:260:\t\trc = of_unittest_check_node_linkage(child);\ndrivers/of/unittest.c-261-\t\tif (rc \u003c 0)\n--\ndrivers/of/unittest.c-268-\ndrivers/of/unittest.c:269:static void __init of_unittest_check_tree_linkage(void)\ndrivers/of/unittest.c-270-{\n--\ndrivers/of/unittest.c-278-\t\tallnode_count++;\ndrivers/of/unittest.c:279:\tchild_count = of_unittest_check_node_linkage(of_root);\ndrivers/of/unittest.c-280-\n--\ndrivers/of/unittest.c-287-\ndrivers/of/unittest.c:288:static void __init of_unittest_printf_one(struct device_node *np, const char *fmt,\ndrivers/of/unittest.c-289-\t\t\t\t\t const char *expected)\n--\ndrivers/of/unittest.c-321-\ndrivers/of/unittest.c:322:static void __init of_unittest_printf(void)\ndrivers/of/unittest.c-323-{\n--\ndrivers/of/unittest.c-335-\ndrivers/of/unittest.c:336:\tof_unittest_printf_one(np, \"%pOF\", full_name);\ndrivers/of/unittest.c:337:\tof_unittest_printf_one(np, \"%pOFf\", full_name);\ndrivers/of/unittest.c:338:\tof_unittest_printf_one(np, \"%pOFn\", \"dev\");\ndrivers/of/unittest.c:339:\tof_unittest_printf_one(np, \"%2pOFn\", \"dev\");\ndrivers/of/unittest.c:340:\tof_unittest_printf_one(np, \"%5pOFn\", \" dev\");\ndrivers/of/unittest.c:341:\tof_unittest_printf_one(np, \"%pOFnc\", \"dev:test-sub-device\");\ndrivers/of/unittest.c:342:\tof_unittest_printf_one(np, \"%pOFp\", phandle_str);\ndrivers/of/unittest.c:343:\tof_unittest_printf_one(np, \"%pOFP\", \"dev@100\");\ndrivers/of/unittest.c:344:\tof_unittest_printf_one(np, \"ABC %pOFP ABC\", \"ABC dev@100 ABC\");\ndrivers/of/unittest.c:345:\tof_unittest_printf_one(np, \"%10pOFP\", \" dev@100\");\ndrivers/of/unittest.c:346:\tof_unittest_printf_one(np, \"%-10pOFP\", \"dev@100 \");\ndrivers/of/unittest.c:347:\tof_unittest_printf_one(of_root, \"%pOFP\", \"/\");\ndrivers/of/unittest.c:348:\tof_unittest_printf_one(np, \"%pOFF\", \"----\");\ndrivers/of/unittest.c:349:\tof_unittest_printf_one(np, \"%pOFPF\", \"dev@100:----\");\ndrivers/of/unittest.c:350:\tof_unittest_printf_one(np, \"%pOFPFPc\", \"dev@100:----:dev@100:test-sub-device\");\ndrivers/of/unittest.c:351:\tof_unittest_printf_one(np, \"%pOFc\", \"test-sub-device\");\ndrivers/of/unittest.c:352:\tof_unittest_printf_one(np, \"%pOFC\",\ndrivers/of/unittest.c-353-\t\t\t\"\\\"test-sub-device\\\",\\\"test-compat2\\\",\\\"test-compat3\\\"\");\n--\ndrivers/of/unittest.c=361=static DEFINE_HASHTABLE(phandle_ht, 8);\ndrivers/of/unittest.c:362:static void __init of_unittest_check_phandles(void)\ndrivers/of/unittest.c-363-{\n--\ndrivers/of/unittest.c-399-\ndrivers/of/unittest.c:400:static void __init of_unittest_parse_phandle_with_args(void)\ndrivers/of/unittest.c-401-{\n--\ndrivers/of/unittest.c-558-\ndrivers/of/unittest.c:559:static void __init of_unittest_parse_phandle_with_args_map(void)\ndrivers/of/unittest.c-560-{\n--\ndrivers/of/unittest.c-712-\ndrivers/of/unittest.c:713:static void __init of_unittest_property_string(void)\ndrivers/of/unittest.c-714-{\n--\ndrivers/of/unittest.c-829-\t\t\t!strcmp((p1)-\u003ename, (p2)-\u003ename))\ndrivers/of/unittest.c:830:static void __init of_unittest_property_copy(void)\ndrivers/of/unittest.c-831-{\n--\ndrivers/of/unittest.c-848-\ndrivers/of/unittest.c:849:static void __init of_unittest_changeset(void)\ndrivers/of/unittest.c-850-{\n--\ndrivers/of/unittest.c=1054=static void __init __maybe_unused changeset_check_bool(struct device_node *np,\n--\ndrivers/of/unittest.c-1060-\ndrivers/of/unittest.c:1061:static void __init of_unittest_changeset_prop(void)\ndrivers/of/unittest.c-1062-{\n--\ndrivers/of/unittest.c-1126-\ndrivers/of/unittest.c:1127:static void __init of_unittest_dma_get_max_cpu_address(void)\ndrivers/of/unittest.c-1128-{\n--\ndrivers/of/unittest.c-1146-\ndrivers/of/unittest.c:1147:static void __init of_unittest_dma_ranges_one(const char *path,\ndrivers/of/unittest.c-1148-\t\tu64 expect_dma_addr, u64 expect_paddr)\n--\ndrivers/of/unittest.c-1194-\ndrivers/of/unittest.c:1195:static void __init of_unittest_parse_dma_ranges(void)\ndrivers/of/unittest.c-1196-{\ndrivers/of/unittest.c:1197:\tof_unittest_dma_ranges_one(\"/testcase-data/address-tests/device@70000000\",\ndrivers/of/unittest.c-1198-\t\t0x0, 0x20000000);\ndrivers/of/unittest.c-1199-\tif (IS_ENABLED(CONFIG_ARCH_DMA_ADDR_T_64BIT))\ndrivers/of/unittest.c:1200:\t\tof_unittest_dma_ranges_one(\"/testcase-data/address-tests/bus@80000000/device@1000\",\ndrivers/of/unittest.c-1201-\t\t\t0x100000000, 0x20000000);\ndrivers/of/unittest.c:1202:\tof_unittest_dma_ranges_one(\"/testcase-data/address-tests/pci@90000000\",\ndrivers/of/unittest.c-1203-\t\t0x80000000, 0x20000000);\n--\ndrivers/of/unittest.c-1205-\ndrivers/of/unittest.c:1206:static void __init of_unittest_pci_dma_ranges(void)\ndrivers/of/unittest.c-1207-{\n--\ndrivers/of/unittest.c-1258-\ndrivers/of/unittest.c:1259:static void __init of_unittest_pci_empty_dma_ranges(void)\ndrivers/of/unittest.c-1260-{\n--\ndrivers/of/unittest.c-1296-\ndrivers/of/unittest.c:1297:static void __init of_unittest_bus_ranges(void)\ndrivers/of/unittest.c-1298-{\n--\ndrivers/of/unittest.c-1367-\ndrivers/of/unittest.c:1368:static void __init of_unittest_bus_3cell_ranges(void)\ndrivers/of/unittest.c-1369-{\n--\ndrivers/of/unittest.c-1422-\ndrivers/of/unittest.c:1423:static void __init of_unittest_reg(void)\ndrivers/of/unittest.c-1424-{\n--\ndrivers/of/unittest.c-1457-\ndrivers/of/unittest.c:1458:struct of_unittest_expected_res {\ndrivers/of/unittest.c-1459-\tint index;\n--\ndrivers/of/unittest.c-1462-\ndrivers/of/unittest.c:1463:static void __init of_unittest_check_addr(const char *node_path,\ndrivers/of/unittest.c:1464:\t\t\t\t\t const struct of_unittest_expected_res *tab_exp,\ndrivers/of/unittest.c-1465-\t\t\t\t\t unsigned int tab_exp_count)\ndrivers/of/unittest.c-1466-{\ndrivers/of/unittest.c:1467:\tconst struct of_unittest_expected_res *expected;\ndrivers/of/unittest.c-1468-\tstruct device_node *np;\n--\ndrivers/of/unittest.c-1498-\ndrivers/of/unittest.c:1499:static const struct of_unittest_expected_res of_unittest_reg_2cell_expected_res[] = {\ndrivers/of/unittest.c-1500-\t{.index = 0, .res = DEFINE_RES_MEM(0xa0a01000, 0x100) },\n--\ndrivers/of/unittest.c-1505-\ndrivers/of/unittest.c:1506:static const struct of_unittest_expected_res of_unittest_reg_3cell_expected_res[] = {\ndrivers/of/unittest.c-1507-\t{.index = 0, .res = DEFINE_RES_MEM(0xa0a01000, 0x100) },\n--\ndrivers/of/unittest.c-1513-\ndrivers/of/unittest.c:1514:static const struct of_unittest_expected_res of_unittest_reg_pci_expected_res[] = {\ndrivers/of/unittest.c-1515-\t{.index = 0, .res = DEFINE_RES_MEM(0xe8001000, 0x1000) },\n--\ndrivers/of/unittest.c-1518-\ndrivers/of/unittest.c:1519:static void __init of_unittest_translate_addr(void)\ndrivers/of/unittest.c-1520-{\ndrivers/of/unittest.c:1521:\tof_unittest_check_addr(\"/testcase-data/address-tests2/bus-2cell@10000000/device@100000\",\ndrivers/of/unittest.c:1522:\t\t\t of_unittest_reg_2cell_expected_res,\ndrivers/of/unittest.c:1523:\t\t\t ARRAY_SIZE(of_unittest_reg_2cell_expected_res));\ndrivers/of/unittest.c-1524-\ndrivers/of/unittest.c:1525:\tof_unittest_check_addr(\"/testcase-data/address-tests2/bus-3cell@20000000/local-bus@100000/device@f1001000\",\ndrivers/of/unittest.c:1526:\t\t\t of_unittest_reg_3cell_expected_res,\ndrivers/of/unittest.c:1527:\t\t\t ARRAY_SIZE(of_unittest_reg_3cell_expected_res));\ndrivers/of/unittest.c-1528-\ndrivers/of/unittest.c:1529:\tof_unittest_check_addr(\"/testcase-data/address-tests2/pcie@d1070000/pci@0,0/dev@0,0/local-bus@0/dev@e0000000\",\ndrivers/of/unittest.c:1530:\t\t\t of_unittest_reg_pci_expected_res,\ndrivers/of/unittest.c:1531:\t\t\t ARRAY_SIZE(of_unittest_reg_pci_expected_res));\ndrivers/of/unittest.c-1532-}\ndrivers/of/unittest.c-1533-\ndrivers/of/unittest.c:1534:static void __init of_unittest_parse_interrupts(void)\ndrivers/of/unittest.c-1535-{\n--\ndrivers/of/unittest.c-1610-\ndrivers/of/unittest.c:1611:static void __init of_unittest_parse_interrupts_extended(void)\ndrivers/of/unittest.c-1612-{\n--\ndrivers/of/unittest.c-1690-\ndrivers/of/unittest.c:1691:struct of_unittest_expected_imap_item {\ndrivers/of/unittest.c-1692-\tu32 child_imap_count;\n--\ndrivers/of/unittest.c-1698-\ndrivers/of/unittest.c:1699:static const struct of_unittest_expected_imap_item of_unittest_expected_imap_items[] = {\ndrivers/of/unittest.c-1700-\t{\n--\ndrivers/of/unittest.c-1726-\ndrivers/of/unittest.c:1727:static void __init of_unittest_parse_interrupt_map(void)\ndrivers/of/unittest.c-1728-{\ndrivers/of/unittest.c:1729:\tconst struct of_unittest_expected_imap_item *expected_item;\ndrivers/of/unittest.c-1730-\tstruct device_node *imap_np, *expected_parent_np;\n--\ndrivers/of/unittest.c-1748-\ndrivers/of/unittest.c:1749:\texpected_item = of_unittest_expected_imap_items;\ndrivers/of/unittest.c-1750-\tcount = 0;\n--\ndrivers/of/unittest.c-1752-\tfor_each_of_imap_item(\u0026imap_parser, \u0026imap_item) {\ndrivers/of/unittest.c:1753:\t\tif (unittest(count \u003c ARRAY_SIZE(of_unittest_expected_imap_items),\ndrivers/of/unittest.c-1754-\t\t\t \"imap item number %d not expected. Max number %zu\\n\",\ndrivers/of/unittest.c:1755:\t\t\t count, ARRAY_SIZE(of_unittest_expected_imap_items) - 1)) {\ndrivers/of/unittest.c-1756-\t\t\tof_node_put(imap_item.parent_args.np);\n--\ndrivers/of/unittest.c-1798-\ndrivers/of/unittest.c:1799:\tunittest(count == ARRAY_SIZE(of_unittest_expected_imap_items),\ndrivers/of/unittest.c-1800-\t\t \"Missing items. %d parsed, expected %zu\\n\",\ndrivers/of/unittest.c:1801:\t\t count, ARRAY_SIZE(of_unittest_expected_imap_items));\ndrivers/of/unittest.c-1802-end:\n--\ndrivers/of/unittest.c-1806-#if IS_ENABLED(CONFIG_OF_DYNAMIC)\ndrivers/of/unittest.c:1807:static void __init of_unittest_irq_refcount(void)\ndrivers/of/unittest.c-1808-{\n--\ndrivers/of/unittest.c-1868-#else\ndrivers/of/unittest.c:1869:static inline void __init of_unittest_irq_refcount(void) { }\ndrivers/of/unittest.c-1870-#endif\n--\ndrivers/of/unittest.c=1889=static struct {\n--\ndrivers/of/unittest.c-1906-\ndrivers/of/unittest.c:1907:static void __init of_unittest_match_node(void)\ndrivers/of/unittest.c-1908-{\n--\ndrivers/of/unittest.c=1939=static const struct platform_device_info test_bus_info = {\n--\ndrivers/of/unittest.c-1941-};\ndrivers/of/unittest.c:1942:static void __init of_unittest_platform_populate(void)\ndrivers/of/unittest.c-1943-{\n--\ndrivers/of/unittest.c=2350=static struct platform_driver unittest_gpio_driver = {\n--\ndrivers/of/unittest.c-2358-\ndrivers/of/unittest.c:2359:static void __init of_unittest_overlay_gpio(void)\ndrivers/of/unittest.c-2360-{\n--\ndrivers/of/unittest.c-2370-\t * The overlays are applied by overlay_data_apply()\ndrivers/of/unittest.c:2371:\t * instead of of_unittest_apply_overlay() so that they\ndrivers/of/unittest.c-2372-\t * will not be tracked. Thus they will not be removed\ndrivers/of/unittest.c:2373:\t * by of_unittest_remove_tracked_overlays().\ndrivers/of/unittest.c-2374-\t *\n--\ndrivers/of/unittest.c-2484-\ndrivers/of/unittest.c:2485:static void __init of_unittest_overlay_gpio(void)\ndrivers/of/unittest.c-2486-{\n--\ndrivers/of/unittest.c=2544=static const char *unittest_path(int nr, enum overlay_type ovtype)\n--\ndrivers/of/unittest.c-2564-\ndrivers/of/unittest.c:2565:static int of_unittest_device_exists(int unittest_nr, enum overlay_type ovtype)\ndrivers/of/unittest.c-2566-{\n--\ndrivers/of/unittest.c=2597=static int track_ovcs_id_cnt;\ndrivers/of/unittest.c-2598-\ndrivers/of/unittest.c:2599:static void of_unittest_track_overlay(int ovcs_id, int overlay_nr)\ndrivers/of/unittest.c-2600-{\n--\ndrivers/of/unittest.c-2608-\ndrivers/of/unittest.c:2609:static void of_unittest_untrack_overlay(int ovcs_id)\ndrivers/of/unittest.c-2610-{\n--\ndrivers/of/unittest.c-2619-\ndrivers/of/unittest.c:2620:static void of_unittest_remove_tracked_overlays(void)\ndrivers/of/unittest.c-2621-{\n--\ndrivers/of/unittest.c-2635-\t\t}\ndrivers/of/unittest.c:2636:\t\tof_unittest_untrack_overlay(save_ovcs_id);\ndrivers/of/unittest.c-2637-\t}\n--\ndrivers/of/unittest.c-2640-\ndrivers/of/unittest.c:2641:static int __init of_unittest_apply_overlay(int overlay_nr, int *ovcs_id)\ndrivers/of/unittest.c-2642-{\n--\ndrivers/of/unittest.c-2644-\t * The overlay will be tracked, thus it will be removed\ndrivers/of/unittest.c:2645:\t * by of_unittest_remove_tracked_overlays().\ndrivers/of/unittest.c-2646-\t */\n--\ndrivers/of/unittest.c-2655-\t}\ndrivers/of/unittest.c:2656:\tof_unittest_track_overlay(*ovcs_id, overlay_nr);\ndrivers/of/unittest.c-2657-\n--\ndrivers/of/unittest.c-2660-\ndrivers/of/unittest.c:2661:static int __init __of_unittest_apply_overlay_check(int overlay_nr,\ndrivers/of/unittest.c-2662-\t\tint unittest_nr, int before, int after,\n--\ndrivers/of/unittest.c-2667-\t/* unittest device must be in before state */\ndrivers/of/unittest.c:2668:\tif (of_unittest_device_exists(unittest_nr, ovtype) != before) {\ndrivers/of/unittest.c-2669-\t\tunittest(0, \"%s with device @\\\"%s\\\" %s\\n\",\n--\ndrivers/of/unittest.c-2677-\tovcs_id = 0;\ndrivers/of/unittest.c:2678:\tret = of_unittest_apply_overlay(overlay_nr, \u0026ovcs_id);\ndrivers/of/unittest.c-2679-\tif (ret != 0) {\ndrivers/of/unittest.c:2680:\t\t/* of_unittest_apply_overlay already called unittest() */\ndrivers/of/unittest.c-2681-\t\treturn ret;\n--\ndrivers/of/unittest.c-2684-\t/* unittest device must be in after state */\ndrivers/of/unittest.c:2685:\tif (of_unittest_device_exists(unittest_nr, ovtype) != after) {\ndrivers/of/unittest.c-2686-\t\tunittest(0, \"%s with device @\\\"%s\\\" %s\\n\",\n--\ndrivers/of/unittest.c-2696-/* apply an overlay while checking before and after states */\ndrivers/of/unittest.c:2697:static int __init of_unittest_apply_overlay_check(int overlay_nr,\ndrivers/of/unittest.c-2698-\t\tint unittest_nr, int before, int after,\n--\ndrivers/of/unittest.c-2700-{\ndrivers/of/unittest.c:2701:\tint ovcs_id = __of_unittest_apply_overlay_check(overlay_nr,\ndrivers/of/unittest.c-2702-\t\t\t\tunittest_nr, before, after, ovtype);\n--\ndrivers/of/unittest.c-2709-/* apply an overlay and then revert it while checking before, after states */\ndrivers/of/unittest.c:2710:static int __init of_unittest_apply_revert_overlay_check(int overlay_nr,\ndrivers/of/unittest.c-2711-\t\tint unittest_nr, int before, int after,\n--\ndrivers/of/unittest.c-2715-\ndrivers/of/unittest.c:2716:\tovcs_id = __of_unittest_apply_overlay_check(overlay_nr, unittest_nr,\ndrivers/of/unittest.c-2717-\t\t\t\t\t\t before, after, ovtype);\n--\ndrivers/of/unittest.c-2729-\t}\ndrivers/of/unittest.c:2730:\tof_unittest_untrack_overlay(save_ovcs_id);\ndrivers/of/unittest.c-2731-\ndrivers/of/unittest.c-2732-\t/* unittest device must be again in before state */\ndrivers/of/unittest.c:2733:\tif (of_unittest_device_exists(unittest_nr, ovtype) != before) {\ndrivers/of/unittest.c-2734-\t\tunittest(0, \"%s with device @\\\"%s\\\" %s\\n\",\n--\ndrivers/of/unittest.c-2744-/* test activation of device */\ndrivers/of/unittest.c:2745:static void __init of_unittest_overlay_0(void)\ndrivers/of/unittest.c-2746-{\n--\ndrivers/of/unittest.c-2752-\t/* device should enable */\ndrivers/of/unittest.c:2753:\tret = of_unittest_apply_overlay_check(0, 0, 0, 1, PDEV_OVERLAY);\ndrivers/of/unittest.c-2754-\n--\ndrivers/of/unittest.c-2764-/* test deactivation of device */\ndrivers/of/unittest.c:2765:static void __init of_unittest_overlay_1(void)\ndrivers/of/unittest.c-2766-{\n--\ndrivers/of/unittest.c-2772-\t/* device should disable */\ndrivers/of/unittest.c:2773:\tret = of_unittest_apply_overlay_check(1, 1, 1, 0, PDEV_OVERLAY);\ndrivers/of/unittest.c-2774-\n--\ndrivers/of/unittest.c-2785-/* test activation of device */\ndrivers/of/unittest.c:2786:static void __init of_unittest_overlay_2(void)\ndrivers/of/unittest.c-2787-{\n--\ndrivers/of/unittest.c-2793-\t/* device should enable */\ndrivers/of/unittest.c:2794:\tret = of_unittest_apply_overlay_check(2, 2, 0, 1, PDEV_OVERLAY);\ndrivers/of/unittest.c-2795-\n--\ndrivers/of/unittest.c-2804-/* test deactivation of device */\ndrivers/of/unittest.c:2805:static void __init of_unittest_overlay_3(void)\ndrivers/of/unittest.c-2806-{\n--\ndrivers/of/unittest.c-2812-\t/* device should disable */\ndrivers/of/unittest.c:2813:\tret = of_unittest_apply_overlay_check(3, 3, 1, 0, PDEV_OVERLAY);\ndrivers/of/unittest.c-2814-\n--\ndrivers/of/unittest.c-2824-/* test activation of a full device node */\ndrivers/of/unittest.c:2825:static void __init of_unittest_overlay_4(void)\ndrivers/of/unittest.c-2826-{\ndrivers/of/unittest.c-2827-\t/* device should disable */\ndrivers/of/unittest.c:2828:\tif (of_unittest_apply_overlay_check(4, 4, 0, 1, PDEV_OVERLAY))\ndrivers/of/unittest.c-2829-\t\treturn;\n--\ndrivers/of/unittest.c-2834-/* test overlay apply/revert sequence */\ndrivers/of/unittest.c:2835:static void __init of_unittest_overlay_5(void)\ndrivers/of/unittest.c-2836-{\n--\ndrivers/of/unittest.c-2842-\t/* device should disable */\ndrivers/of/unittest.c:2843:\tret = of_unittest_apply_revert_overlay_check(5, 5, 0, 1, PDEV_OVERLAY);\ndrivers/of/unittest.c-2844-\n--\ndrivers/of/unittest.c-2854-/* test overlay application in sequence */\ndrivers/of/unittest.c:2855:static void __init of_unittest_overlay_6(void)\ndrivers/of/unittest.c-2856-{\n--\ndrivers/of/unittest.c-2865-\tfor (i = 0; i \u003c 2; i++) {\ndrivers/of/unittest.c:2866:\t\tif (of_unittest_device_exists(unittest_nr + i, PDEV_OVERLAY)\ndrivers/of/unittest.c-2867-\t\t\t\t!= before) {\n--\ndrivers/of/unittest.c-2890-\tsave_ovcs_id[0] = ovcs_id;\ndrivers/of/unittest.c:2891:\tof_unittest_track_overlay(ovcs_id, overlay_nr + 0);\ndrivers/of/unittest.c-2892-\n--\ndrivers/of/unittest.c-2907-\tsave_ovcs_id[1] = ovcs_id;\ndrivers/of/unittest.c:2908:\tof_unittest_track_overlay(ovcs_id, overlay_nr + 1);\ndrivers/of/unittest.c-2909-\n--\ndrivers/of/unittest.c-2915-\t\t/* unittest device must be in after state */\ndrivers/of/unittest.c:2916:\t\tif (of_unittest_device_exists(unittest_nr + i, PDEV_OVERLAY)\ndrivers/of/unittest.c-2917-\t\t\t\t!= after) {\n--\ndrivers/of/unittest.c-2935-\t\t}\ndrivers/of/unittest.c:2936:\t\tof_unittest_untrack_overlay(save_ovcs_id[i]);\ndrivers/of/unittest.c-2937-\t}\n--\ndrivers/of/unittest.c-2940-\t\t/* unittest device must be again in before state */\ndrivers/of/unittest.c:2941:\t\tif (of_unittest_device_exists(unittest_nr + i, PDEV_OVERLAY)\ndrivers/of/unittest.c-2942-\t\t\t\t!= before) {\n--\ndrivers/of/unittest.c-2956-/* test overlay application in sequence */\ndrivers/of/unittest.c:2957:static void __init of_unittest_overlay_8(void)\ndrivers/of/unittest.c-2958-{\n--\ndrivers/of/unittest.c-2981-\tsave_ovcs_id[0] = ovcs_id;\ndrivers/of/unittest.c:2982:\tof_unittest_track_overlay(ovcs_id, overlay_nr + 0);\ndrivers/of/unittest.c-2983-\n--\ndrivers/of/unittest.c-3000-\tsave_ovcs_id[1] = ovcs_id;\ndrivers/of/unittest.c:3001:\tof_unittest_track_overlay(ovcs_id, overlay_nr + 1);\ndrivers/of/unittest.c-3002-\n--\ndrivers/of/unittest.c-3041-\t\t}\ndrivers/of/unittest.c:3042:\t\tof_unittest_untrack_overlay(save_ovcs_id[i]);\ndrivers/of/unittest.c-3043-\t}\n--\ndrivers/of/unittest.c-3048-/* test insertion of a bus with parent devices */\ndrivers/of/unittest.c:3049:static void __init of_unittest_overlay_10(void)\ndrivers/of/unittest.c-3050-{\n--\ndrivers/of/unittest.c-3054-\t/* device should disable */\ndrivers/of/unittest.c:3055:\tret = of_unittest_apply_overlay_check(10, 10, 0, 1, PDEV_OVERLAY);\ndrivers/of/unittest.c-3056-\n--\ndrivers/of/unittest.c-3072-/* test insertion of a bus with parent devices (and revert) */\ndrivers/of/unittest.c:3073:static void __init of_unittest_overlay_11(void)\ndrivers/of/unittest.c-3074-{\n--\ndrivers/of/unittest.c-3077-\t/* device should disable */\ndrivers/of/unittest.c:3078:\tret = of_unittest_apply_revert_overlay_check(11, 11, 0, 1,\ndrivers/of/unittest.c-3079-\t\t\tPDEV_OVERLAY);\n--\ndrivers/of/unittest.c=3284=static struct i2c_driver unittest_i2c_mux_driver = {\n--\ndrivers/of/unittest.c-3294-\ndrivers/of/unittest.c:3295:static int of_unittest_overlay_i2c_init(void)\ndrivers/of/unittest.c-3296-{\n--\ndrivers/of/unittest.c-3327-\ndrivers/of/unittest.c:3328:static void of_unittest_overlay_i2c_cleanup(void)\ndrivers/of/unittest.c-3329-{\n--\ndrivers/of/unittest.c-3336-\ndrivers/of/unittest.c:3337:static void __init of_unittest_overlay_i2c_12(void)\ndrivers/of/unittest.c-3338-{\n--\ndrivers/of/unittest.c-3344-\ndrivers/of/unittest.c:3345:\tret = of_unittest_apply_overlay_check(12, 12, 0, 1, I2C_OVERLAY);\ndrivers/of/unittest.c-3346-\n--\ndrivers/of/unittest.c-3356-/* test deactivation of device */\ndrivers/of/unittest.c:3357:static void __init of_unittest_overlay_i2c_13(void)\ndrivers/of/unittest.c-3358-{\n--\ndrivers/of/unittest.c-3364-\t/* device should disable */\ndrivers/of/unittest.c:3365:\tret = of_unittest_apply_overlay_check(13, 13, 1, 0, I2C_OVERLAY);\ndrivers/of/unittest.c-3366-\n--\ndrivers/of/unittest.c-3376-/* just check for i2c mux existence */\ndrivers/of/unittest.c:3377:static void of_unittest_overlay_i2c_14(void)\ndrivers/of/unittest.c-3378-{\n--\ndrivers/of/unittest.c-3380-\ndrivers/of/unittest.c:3381:static void __init of_unittest_overlay_i2c_15(void)\ndrivers/of/unittest.c-3382-{\n--\ndrivers/of/unittest.c-3388-\ndrivers/of/unittest.c:3389:\tret = of_unittest_apply_overlay_check(15, 15, 0, 1, I2C_OVERLAY);\ndrivers/of/unittest.c-3390-\n--\ndrivers/of/unittest.c-3401-\ndrivers/of/unittest.c:3402:static inline void of_unittest_overlay_i2c_14(void) { }\ndrivers/of/unittest.c:3403:static inline void of_unittest_overlay_i2c_15(void) { }\ndrivers/of/unittest.c-3404-\n--\ndrivers/of/unittest.c=3475=static struct notifier_block of_nb = {\n--\ndrivers/of/unittest.c-3478-\ndrivers/of/unittest.c:3479:static void __init of_unittest_overlay_notify(void)\ndrivers/of/unittest.c-3480-{\n--\ndrivers/of/unittest.c-3491-\t * The overlays are applied by overlay_data_apply()\ndrivers/of/unittest.c:3492:\t * instead of of_unittest_apply_overlay() so that they\ndrivers/of/unittest.c-3493-\t * will not be tracked. Thus they will not be removed\ndrivers/of/unittest.c:3494:\t * by of_unittest_remove_tracked_overlays().\ndrivers/of/unittest.c-3495-\t *\n--\ndrivers/of/unittest.c-3589-\ndrivers/of/unittest.c:3590:static void __init of_unittest_overlay(void)\ndrivers/of/unittest.c-3591-{\n--\ndrivers/of/unittest.c-3610-\ndrivers/of/unittest.c:3611:\tif (!of_unittest_device_exists(100, PDEV_OVERLAY)) {\ndrivers/of/unittest.c-3612-\t\tunittest(0, \"could not find unittest0 @ \\\"%s\\\"\\n\",\n--\ndrivers/of/unittest.c-3616-\ndrivers/of/unittest.c:3617:\tif (of_unittest_device_exists(101, PDEV_OVERLAY)) {\ndrivers/of/unittest.c-3618-\t\tunittest(0, \"unittest1 @ \\\"%s\\\" should not exist\\n\",\n--\ndrivers/of/unittest.c-3625-\t/* tests in sequence */\ndrivers/of/unittest.c:3626:\tof_unittest_overlay_0();\n\n"
} |
| 11/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 15842 output: 36 thoughts: 61 Thoughts: **Examining the Open Firmware Unit Test Suite** Okay, so I'm looking at `drivers/of/unittest.c`, which I recognize as the Open Firmware unit test suite. Now, I want to quickly scan the file, specifically focusing on the end. I need to see if they've implemented any sysfs or debugfs interfaces here, or if there are any module exports. This suite might be providing a way to interact with the device tree directly or debug its functionality, and the presence of these elements would be a key indicator of how that is accomplished. Let's see what we can find. |
| 12/2 | 2026/09/19 11:56 | tool | read-file |
0mArgs:{
"File": "drivers/of/unittest.c",
"FirstLine": 4560,
"LineCount": 40
}Results: {
"Contents": "4560:\t\t/* Double check linkage after removing testcase data */\n4561:\t\tof_unittest_check_tree_linkage();\n4562:\t\n4563:\t\tof_unittest_overlay_high_level();\n4564:\t\n4565:\t\tpr_info(\"end of unittest - %i passed, %i failed\\n\",\n4566:\t\t\tunittest_results.passed, unittest_results.failed);\n4567:\t\n4568:\t\treturn 0;\n4569:\t}\n4570:\tlate_initcall(of_unittest);\n"
} |
| 13/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 16231 output: 27 thoughts: 18 Thoughts: Here's my summary, as if I were thinking these thoughts: **Analyzing the Build Process for `unittest.c`** Okay, I need to understand exactly how `unittest.c` is being compiled and linked. Given how I've set up the project structure, the most logical place to start is the `drivers/of/Makefile`. That file is where a lot of the low-level build configurations are likely defined, and it seems like the most probable location to find the specific rules that govern the build process for this particular source file. Time to dive in and see what the Makefile reveals about the dependencies, compiler flags, and linking steps involved in generating the object file or executable that incorporates `unittest.c`. Hopefully, it's well-structured and documented! |
| 14/2 | 2026/09/19 11:56 | tool | grepper |
0mArgs:{
"Expression": "unittest\\.o",
"PathPrefix": "drivers/of/"
}Results: {
"Output": "drivers/of/Makefile=9=obj-$(CONFIG_OF_IRQ) += irq.o\ndrivers/of/Makefile:10:obj-$(CONFIG_OF_UNITTEST) += unittest.o\ndrivers/of/Makefile-11-obj-$(CONFIG_OF_RESERVED_MEM) += of_reserved_mem.o\n"
} |
| 15/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 16528 output: 29 thoughts: 34 Thoughts: **Examining the Unit Test Configuration in Device Tree Drivers** Okay, so I'm diving into this `drivers/of` directory, specifically looking at its `Kconfig` file. I've got a hunch there's a configuration option related to unit tests in here. Let's see... Ah, there it is: `CONFIG_OF_UNITTEST`. It's a boolean, as I expected, so I need to understand its implications for the build and execution of unit tests within the device tree framework. My next step will be to explore how this flag is actually *used* within the code base. I need to trace its dependencies and impacts on the driver configuration. |
| 16/2 | 2026/09/19 11:56 | tool | grepper |
0mArgs:{
"Expression": "config OF_UNITTEST",
"PathPrefix": "drivers/of/"
}Results: {
"Output": "drivers/of/Kconfig=19=if OF\ndrivers/of/Kconfig-20-\ndrivers/of/Kconfig:21:config OF_UNITTEST\ndrivers/of/Kconfig-22-\tbool \"Device Tree runtime unit tests\"\n"
} |
| 17/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 16805 output: 33 thoughts: 21 Thoughts: Here's my take on those lines in `drivers/of/Kconfig`, roughly from line 20 to 45: **Diving into the Device Tree Kconfig** Okay, let's pull up that `drivers/of/Kconfig` file and zero in on lines 20 through 45. I'm guessing this section probably covers the core configuration options related to the Device Tree binding and core features. I'm expecting to see things like: * **Enabling Device Tree Support:** Likely a top-level `CONFIG_OF` symbol that controls whether the entire Device Tree infrastructure is even compiled in. Absolutely critical. * **DT Blob Parsing:** I imagine there's a setting to enable or disable the parsing of the Device Tree Blob (`.dtb`). Could be separate options for compressed vs. uncompressed blobs. * **Error Handling:** It would be good to see some fine-grained control over how the kernel handles Device Tree parsing errors. Are we talking about warnings, fatal errors, or maybe even options to skip nodes or properties? I'm hoping for flexibility. * **Flattened Device Tree (FDT) vs. Device Tree Source (DTS):** Possibly we see something to choose which format or formats of device tree are supported. * **Memory Management:** There might be some configuration options related to how the kernel allocates memory for Device Tree data structures. Performance tweaks, perhaps? * **Debugging Options:** Hopefully, there are debug flags available to output more verbose messages during Device Tree parsing and device binding. Helpful when things go sideways. Essentially, I'm expecting this section to provide the essential building blocks for incorporating Device Tree into a kernel build. Let's see how close I am...time to read the fine print. |
| 18/2 | 2026/09/19 11:56 | tool | read-file |
0mArgs:{
"File": "drivers/of/Kconfig",
"FirstLine": 19,
"LineCount": 35
}Results: {
"Contents": " 19:\tif OF\n 20:\t\n 21:\tconfig OF_UNITTEST\n 22:\t\tbool \"Device Tree runtime unit tests\"\n 23:\t\tdepends on OF_EARLY_FLATTREE\n 24:\t\tselect IRQ_DOMAIN\n 25:\t\tselect OF_RESOLVE\n 26:\t\thelp\n 27:\t\t This option builds in test cases for the device tree infrastructure\n 28:\t\t that are executed once at boot time, and the results dumped to the\n 29:\t\t console.\n 30:\t\n 31:\t\t This option should only be enabled for a development kernel. The tests\n 32:\t\t will taint the kernel with TAINT_TEST. The tests will cause ERROR and\n 33:\t\t WARNING messages to print on the console. The tests will cause stack\n 34:\t\t traces to print on the console. It is possible that the tests will\n 35:\t\t leave the devicetree in a corrupted state.\n 36:\t\n 37:\t\t The unittest output will be verbose. Copy the output to a file\n 38:\t\t via capturing the console output or via the dmesg command. Process\n 39:\t\t this file with scripts/dtc/of_unittest_expect to reduce the\n 40:\t\t verbosity, test whether expected output is present, and to\n 41:\t\t summarize the results.\n 42:\t\n 43:\t\t If unsure, say N here. This option is not safe to enable.\n 44:\t\n 45:\tconfig OF_KUNIT_TEST\n 46:\t\ttristate \"Devicetree KUnit Test\" if !KUNIT_ALL_TESTS\n 47:\t\tdepends on KUNIT\n 48:\t\tdefault KUNIT_ALL_TESTS\n 49:\t\thelp\n 50:\t\t This option builds KUnit unit tests for device tree infrastructure.\n 51:\t\n 52:\t\t If unsure, say N here, but this option is safe to enable.\n 53:\t\n"
} |
| 19/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 17751 output: 34 thoughts: 784 Thoughts: **Analyzing the Fuzzability of Device Tree Unit Tests** Okay, let's break this down. I'm looking at `CONFIG_OF_UNITTEST` and how it relates to fuzzing with syzkaller. The description clearly states these are boot-time tests, dumping results to the console. They're marked for development kernels and come with warnings about kernel tainting, error messages, stack traces, and potential device tree corruption. Crucially, they use `late_initcall(of_unittest)` and include a function marked with `__init`, namely `of_unittest_pci_dma_ranges`. Now, the instructions are crystal clear: Reachability is key. We can only fuzz code that executes in standard virtualized environments. I need to make sure this meets the criteria for being "WorthFuzzing". Section 2 lays out the "negative criteria" – when we *shouldn't* fuzz. My initial thought is to consider it according to Section 2: * **Non-kernel and non-executable changes:** Maybe not. This modifies device tree stuff, and is kernel code. * **Structurally unreachable hardware:** Likely not. The device tree is more like the bare bones of hardware abstraction. * **Unreachable execution paths:** This is where it gets interesting. Here's the problem: syzkaller runs *after* the kernel has booted, right? And `late_initcall` functions, like `of_unittest`, execute *during* boot, *before* userspace starts! Even more importantly, functions marked `__init` are discarded from memory after boot by `free_initmem()`. So, once syzkaller starts sending syscalls from userspace, all the code related to these `__init` functions is gone. There's no way syzkaller can call, or fuzz these boot-time initialization routines. But wait! Let's check `of_unittest_pci_dma_ranges` specifically. Is it possible for this code to be reachable under a standard amd64 QEMU boot? Is it possible for amd64 to even boot with `OF_EARLY_FLATTREE`? We need to look at the configurations for `CONFIG_OF_EARLY_FLATTREE` on x86/amd64. |
| 20/2 | 2026/09/19 11:56 | tool | grepper |
0mArgs:{
"Expression": "OF_EARLY_FLATTREE",
"PathPrefix": "arch/x86/"
}Results: {
"Output": "arch/x86/Kconfig=669=config X86_INTEL_CE\n--\narch/x86/Kconfig-677-\tselect OF\narch/x86/Kconfig:678:\tselect OF_EARLY_FLATTREE\narch/x86/Kconfig-679-\thelp\n--\narch/x86/kernel/devicetree.c=339=void __init x86_flattree_get_config(void)\narch/x86/kernel/devicetree.c-340-{\narch/x86/kernel/devicetree.c:341:#ifdef CONFIG_OF_EARLY_FLATTREE\narch/x86/kernel/devicetree.c-342-\tu32 size, map_len;\n"
} |
| 21/2 | 2026/09/19 11:56 | llm | patch-evaluator |
0mModel:gemini-3.8-flash Args: null Results: null Tokens: input: 19278 output: 121 thoughts: 528 Thoughts: **Analysis of the Patch's Impact on Syzkaller Fuzzing** Okay, let's break this down. My initial observation is that the patch, specifically the addition of `of_node_put(np)`, resides within the `of_unittest_pci_dma_ranges()` function. This function, however, is a part of the device tree unit test, which is initiated during boot via `late_initcall`. It's crucial to recognize that the unit test is executed and then discarded before the system transitions to userspace, and more critically, before Syzkaller can even be deployed. Looking at the Kconfig, only `X86_INTEL_CE` selects `OF_EARLY_FLATTREE`, so this is specific to a legacy Intel CE4100 Media Processor, which is not the standard x86 PC/QEMU setup that would boot via ACPI. Even if `OF_UNITTEST` were enabled, the modified code in `of_unittest_pci_dma_ranges()` is marked `__init`. The code is executed once during initialization and never again. The code is only reachable by a hardcoded dummy testcase node: `"/testcase-data/address-tests/pci@90000000"`. Therefore, the patch's target code isn't accessible after the boot process; it's within the `__init` section and cannot be triggered or reached by userspace fuzzing or virtual devices. Syzkaller's input generation, syscall execution, and hardware emulation capabilities are simply irrelevant in this context. Consequently, this change is not going to impact Syzkaller's ability to discover bugs. The conclusion is evident: The patch modifies code that is inherently unreachable by Syzkaller fuzzing. The `WorthFuzzing` is `false`, the patch's `Reasoning` aligns perfectly with the understanding, and the `EnableConfigs` and `FocusSymbols` are empty. I'm satisfied. Let's `set-results`. |
| 22/2 | 2026/09/19 11:56 | tool | set-results |
0mArgs:{
"EnableConfigs": [],
"FocusSymbols": [],
"Reasoning": "The patch adds a missing of_node_put() in an error path within of_unittest_pci_dma_ranges() in drivers/of/unittest.c. This is part of the Device Tree unit test suite and is marked __init, executed solely once during kernel boot (late_initcall) before userspace starts, after which init memory is released. It cannot be reached or exercised by syzkaller fuzzing.",
"WorthFuzzing": false
}Results: {
"EnableConfigs": null,
"FocusSymbols": [],
"Reasoning": "The patch adds a missing of_node_put() in an error path within of_unittest_pci_dma_ranges() in drivers/of/unittest.c. This is part of the Device Tree unit test suite and is marked __init, executed solely once during kernel boot (late_initcall) before userspace starts, after which init memory is released. It cannot be reached or exercised by syzkaller fuzzing.",
"WorthFuzzing": false
} |
| 23/1 | 2026/09/19 11:56 | action | If |
0mArgs:{
"WorthFuzzing": false
}Results: null |
| Total Calls | Total Tokens | Avg Tokens | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|
| Total Calls | Total Duration (Seconds) | Avg Duration (Seconds) |
|---|