AI Trajectory


Trajectory: (Expand/Collapse All)
Seq Timestamp Type Name Duration
0/0 2026/09/23 17:48 flow patch-triage
2m Args:
null

Results:
{
  "EnableConfigs": null,
  "FocusSymbols": [],
  "KMSANReasoning": "",
  "NeedsKMSAN": false,
  "Reasoning": "The patch modifies drivers/i2c/busses/i2c-xiic.c, which implements an I2C bus driver for Xilinx FPGA IP cores (xps-iic, axi-iic) and specialized PCIe add-in cards (mgb4, timberdale, ptp_ocp). These devices require dedicated physical hardware (or embedded Device Tree configurations) not emulated in standard virtualized fuzzing environments (QEMU/GCE) on amd64. Therefore, the modified code is structurally unreachable.",
  "WorthFuzzing": false
}

1/1 2026/09/23 17:48 action read-patch-diff
0m Args:
null

Results:
{
  "PatchDiff": "commit 3240378a41eeb53ab6e99ac467a2044970b70e03\nAuthor: syz-cluster \u003ctriage@syzkaller.com\u003e\nDate:   Wed Sep 23 17:48:36 2026 +0000\n\n    syz-cluster: applied patch under review\n\ndiff --git a/drivers/i2c/busses/i2c-xiic.c b/drivers/i2c/busses/i2c-xiic.c\nindex 3e7735e1dae00..d5e7b089a2b80 100644\n--- a/drivers/i2c/busses/i2c-xiic.c\n+++ b/drivers/i2c/busses/i2c-xiic.c\n@@ -73,6 +73,9 @@ enum i2c_scl_freq {\n  * @prev_msg_tx: Previous message is Tx\n  * @quirks: To hold platform specific bug info\n  * @smbus_block_read: Flag to handle block read\n+ * @smbus_actual_len: Valid byte count (length + payload + optional PEC) of a\n+ *\tpadded SMBus block read. msg-\u003elen is trimmed to this on completion.\n+ *\tZero when no trimming is needed.\n  * @input_clk: Input clock to I2C controller\n  * @i2c_clk: I2C SCL frequency\n  * @atomic: Mode of transfer\n@@ -98,6 +101,7 @@ struct xiic_i2c {\n \tbool prev_msg_tx;\n \tu32 quirks;\n \tbool smbus_block_read;\n+\tunsigned int smbus_actual_len;\n \tunsigned long input_clk;\n \tunsigned int i2c_clk;\n \tbool atomic;\n@@ -539,30 +543,33 @@ static void xiic_smbus_block_read_setup(struct xiic_i2c *i2c)\n \n \t/* Check if received length is valid */\n \tif (rxmsg_len \u003c= I2C_SMBUS_BLOCK_MAX) {\n+\t\tunsigned int pec_len = i2c-\u003erx_msg-\u003elen - 1;\n+\n \t\t/* Set Receive fifo depth */\n-\t\tif (rxmsg_len \u003e IIC_RX_FIFO_DEPTH) {\n+\t\tif (rxmsg_len + pec_len \u003e IIC_RX_FIFO_DEPTH) {\n \t\t\t/*\n-\t\t\t * When Rx msg len greater than or equal to Rx fifo capacity\n-\t\t\t * Receive fifo depth should set to Rx fifo capacity minus 1\n+\t\t\t * Trailing payload (data + optional PEC) exceeds Rx FIFO\n+\t\t\t * capacity; drain in chunks. Fire RX_FULL when the FIFO is\n+\t\t\t * full and let the ISR re-arm for the remainder.\n \t\t\t */\n \t\t\trfd_set = IIC_RX_FIFO_DEPTH - 1;\n-\t\t\ti2c-\u003erx_msg-\u003elen = rxmsg_len + 1;\n-\t\t} else if ((rxmsg_len == 1) ||\n-\t\t\t(rxmsg_len == 0)) {\n+\t\t\ti2c-\u003erx_msg-\u003elen = rxmsg_len + 1 + pec_len;\n+\t\t} else if (1 + rxmsg_len + pec_len \u003c SMBUS_BLOCK_READ_MIN_LEN) {\n \t\t\t/*\n-\t\t\t * Minimum of 3 bytes required to exit cleanly. 1 byte\n-\t\t\t * already received, Second byte is being received. Have\n-\t\t\t * to set NACK in read_rx before receiving the last byte\n+\t\t\t * The HW needs SMBUS_BLOCK_READ_MIN_LEN bytes on the\n+\t\t\t * bus to exit cleanly: by the time the ISR reads the\n+\t\t\t * length byte the second byte is already being clocked\n+\t\t\t * in, too late to NACK. Pad the drain target and record\n+\t\t\t * the real length, trimmed back on completion so the\n+\t\t\t * PEC check sees the right byte.\n \t\t\t */\n \t\t\trfd_set = 0;\n \t\t\ti2c-\u003erx_msg-\u003elen = SMBUS_BLOCK_READ_MIN_LEN;\n+\t\t\ti2c-\u003esmbus_actual_len = 1 + rxmsg_len + pec_len;\n \t\t} else {\n-\t\t\t/*\n-\t\t\t * When Rx msg len less than Rx fifo capacity\n-\t\t\t * Receive fifo depth should set to Rx msg len minus 2\n-\t\t\t */\n-\t\t\trfd_set = rxmsg_len - 2;\n-\t\t\ti2c-\u003erx_msg-\u003elen = rxmsg_len + 1;\n+\t\t\t/* Defer RX_FULL until all trailing bytes are in FIFO. */\n+\t\t\trfd_set = rxmsg_len + pec_len - 1;\n+\t\t\ti2c-\u003erx_msg-\u003elen = rxmsg_len + 1 + pec_len;\n \t\t}\n \t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);\n \n@@ -797,6 +804,13 @@ static irqreturn_t xiic_process(int irq, void *dev_id)\n \n \t\txiic_read_rx(i2c);\n \t\tif (xiic_rx_space(i2c) == 0) {\n+\t\t\t/*\n+\t\t\t * Undo the setup-time padding before rx_msg is cleared,\n+\t\t\t * so the PEC check sees the right byte.\n+\t\t\t */\n+\t\t\tif (i2c-\u003erx_msg \u0026\u0026 i2c-\u003esmbus_actual_len)\n+\t\t\t\ti2c-\u003erx_msg-\u003elen = i2c-\u003esmbus_actual_len;\n+\n \t\t\t/* this is the last part of the message */\n \t\t\ti2c-\u003erx_msg = NULL;\n \n@@ -865,8 +879,11 @@ static irqreturn_t xiic_process(int irq, void *dev_id)\n \n \t\tif (i2c-\u003etx_msg \u0026\u0026 i2c-\u003esmbus_block_read) {\n \t\t\ti2c-\u003esmbus_block_read = false;\n-\t\t\t/* Set requested message len=1 to indicate STATE_DONE */\n-\t\t\ti2c-\u003etx_msg-\u003elen = 1;\n+\t\t\t/*\n+\t\t\t * Drive xiic_tx_space() to 0 to signal STATE_DONE\n+\t\t\t * without truncating the rx_msg length.\n+\t\t\t */\n+\t\t\ti2c-\u003etx_pos = i2c-\u003etx_msg-\u003elen;\n \t\t}\n \n \t\tif (!i2c-\u003etx_msg)\n@@ -955,6 +972,9 @@ static void xiic_start_recv(struct xiic_i2c *i2c)\n \tu8 cr = 0, rfd_set = 0;\n \tstruct i2c_msg *msg = i2c-\u003erx_msg = i2c-\u003etx_msg;\n \n+\t/* A stale value from an aborted block read would truncate this msg. */\n+\ti2c-\u003esmbus_actual_len = 0;\n+\n \tif (!i2c-\u003eatomic)\n \t\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s entry, ISR: 0x%x, CR: 0x%x\\n\",\n \t\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\n"
}

2/1 2026/09/23 17:48 agent patch-evaluator
2m Model:
core

Args:
null

Results:
{
  "EnableConfigs": null,
  "FocusSymbols": [],
  "Reasoning": "The patch modifies drivers/i2c/busses/i2c-xiic.c, which implements an I2C bus driver for Xilinx FPGA IP cores (xps-iic, axi-iic) and specialized PCIe add-in cards (mgb4, timberdale, ptp_ocp). These devices require dedicated physical hardware (or embedded Device Tree configurations) not emulated in standard virtualized fuzzing environments (QEMU/GCE) on amd64. Therefore, the modified code is structurally unreachable.",
  "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 3240378a41eeb53ab6e99ac467a2044970b70e03
Author: syz-cluster <triage@syzkaller.com>
Date:   Wed Sep 23 17:48:36 2026 +0000

    syz-cluster: applied patch under review

diff --git a/drivers/i2c/busses/i2c-xiic.c b/drivers/i2c/busses/i2c-xiic.c
index 3e7735e1dae00..d5e7b089a2b80 100644
--- a/drivers/i2c/busses/i2c-xiic.c
+++ b/drivers/i2c/busses/i2c-xiic.c
@@ -73,6 +73,9 @@ enum i2c_scl_freq {
  * @prev_msg_tx: Previous message is Tx
  * @quirks: To hold platform specific bug info
  * @smbus_block_read: Flag to handle block read
+ * @smbus_actual_len: Valid byte count (length + payload + optional PEC) of a
+ *	padded SMBus block read. msg->len is trimmed to this on completion.
+ *	Zero when no trimming is needed.
  * @input_clk: Input clock to I2C controller
  * @i2c_clk: I2C SCL frequency
  * @atomic: Mode of transfer
@@ -98,6 +101,7 @@ struct xiic_i2c {
 	bool prev_msg_tx;
 	u32 quirks;
 	bool smbus_block_read;
+	unsigned int smbus_actual_len;
 	unsigned long input_clk;
 	unsigned int i2c_clk;
 	bool atomic;
@@ -539,30 +543,33 @@ static void xiic_smbus_block_read_setup(struct xiic_i2c *i2c)
 
 	/* Check if received length is valid */
 	if (rxmsg_len <= I2C_SMBUS_BLOCK_MAX) {
+		unsigned int pec_len = i2c->rx_msg->len - 1;
+
 		/* Set Receive fifo depth */
-		if (rxmsg_len > IIC_RX_FIFO_DEPTH) {
+		if (rxmsg_len + pec_len > IIC_RX_FIFO_DEPTH) {
 			/*
-			 * When Rx msg len greater than or equal to Rx fifo capacity
-			 * Receive fifo depth should set to Rx fifo capacity minus 1
+			 * Trailing payload (data + optional PEC) exceeds Rx FIFO
+			 * capacity; drain in chunks. Fire RX_FULL when the FIFO is
+			 * full and let the ISR re-arm for the remainder.
 			 */
 			rfd_set = IIC_RX_FIFO_DEPTH - 1;
-			i2c->rx_msg->len = rxmsg_len + 1;
-		} else if ((rxmsg_len == 1) ||
-			(rxmsg_len == 0)) {
+			i2c->rx_msg->len = rxmsg_len + 1 + pec_len;
+		} else if (1 + rxmsg_len + pec_len < SMBUS_BLOCK_READ_MIN_LEN) {
 			/*
-			 * Minimum of 3 bytes required to exit cleanly. 1 byte
-			 * already received, Second byte is being received. Have
-			 * to set NACK in read_rx before receiving the last byte
+			 * The HW needs SMBUS_BLOCK_READ_MIN_LEN bytes on the
+			 * bus to exit cleanly: by the time the ISR reads the
+			 * length byte the second byte is already being clocked
+			 * in, too late to NACK. Pad the drain target and record
+			 * the real length, trimmed back on completion so the
+			 * PEC check sees the right byte.
 			 */
 			rfd_set = 0;
 			i2c->rx_msg->len = SMBUS_BLOCK_READ_MIN_LEN;
+			i2c->smbus_actual_len = 1 + rxmsg_len + pec_len;
 		} else {
-			/*
-			 * When Rx msg len less than Rx fifo capacity
-			 * Receive fifo depth should set to Rx msg len minus 2
-			 */
-			rfd_set = rxmsg_len - 2;
-			i2c->rx_msg->len = rxmsg_len + 1;
+			/* Defer RX_FULL until all trailing bytes are in FIFO. */
+			rfd_set = rxmsg_len + pec_len - 1;
+			i2c->rx_msg->len = rxmsg_len + 1 + pec_len;
 		}
 		xiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);
 
@@ -797,6 +804,13 @@ static irqreturn_t xiic_process(int irq, void *dev_id)
 
 		xiic_read_rx(i2c);
 		if (xiic_rx_space(i2c) == 0) {
+			/*
+			 * Undo the setup-time padding before rx_msg is cleared,
+			 * so the PEC check sees the right byte.
+			 */
+			if (i2c->rx_msg && i2c->smbus_actual_len)
+				i2c->rx_msg->len = i2c->smbus_actual_len;
+
 			/* this is the last part of the message */
 			i2c->rx_msg = NULL;
 
@@ -865,8 +879,11 @@ static irqreturn_t xiic_process(int irq, void *dev_id)
 
 		if (i2c->tx_msg && i2c->smbus_block_read) {
 			i2c->smbus_block_read = false;
-			/* Set requested message len=1 to indicate STATE_DONE */
-			i2c->tx_msg->len = 1;
+			/*
+			 * Drive xiic_tx_space() to 0 to signal STATE_DONE
+			 * without truncating the rx_msg length.
+			 */
+			i2c->tx_pos = i2c->tx_msg->len;
 		}
 
 		if (!i2c->tx_msg)
@@ -955,6 +972,9 @@ static void xiic_start_recv(struct xiic_i2c *i2c)
 	u8 cr = 0, rfd_set = 0;
 	struct i2c_msg *msg = i2c->rx_msg = i2c->tx_msg;
 
+	/* A stale value from an aborted block read would truncate this msg. */
+	i2c->smbus_actual_len = 0;
+
 	if (!i2c->atomic)
 		dev_dbg(i2c->adap.dev.parent, "%s entry, ISR: 0x%x, CR: 0x%x\n",
 			__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),

3/2 2026/09/23 17:48 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 4370
							output: 34
							thoughts: 201
						

Thoughts:
**Evaluating the Linux Kernel Patch**

Okay, so I need to evaluate a patch for the Linux kernel, specifically targeting the amd64 architecture. The target file is `drivers/i2c/busses/i2c-xiic.c`. Alright, let's dive in. First, I need to understand what this `i2c-xiic.c` driver is actually *for*. The name itself doesn't immediately ring any bells. I need to figure out the hardware it controls. Let's start with a quick search within the kernel source to see if I can get some context. Is it a platform driver? Given the name, my initial hunch is that it might be related to a Xilinx FPGA or SoC I2C IP core. Now, the next crucial question is: Can this hardware be tested in standard virtualized environments like QEMU on amd64, or is it tied to hardware that I don't have access to, or can't reproduce? To be sure, I should check the `drivers/i2c/busses/Kconfig` file and the `i2c-xiic.c` file itself. That should give me a solid clue about the hardware dependencies and any associated configuration options.



4/2 2026/09/23 17:48 tool grepper
0m Args:
{
  "Expression": "i2c-xiic",
  "PathPrefix": "drivers/i2c/busses"
}

Results:
{
  "Output": "drivers/i2c/busses/Makefile=128=i2c-thunderx-y\t\t\t:= i2c-octeon-core.o i2c-thunderx-pcidrv.o\ndrivers/i2c/busses/Makefile:129:obj-$(CONFIG_I2C_XILINX)\t+= i2c-xiic.o\ndrivers/i2c/busses/Makefile-130-obj-$(CONFIG_I2C_XLP9XX)\t+= i2c-xlp9xx.o\n--\ndrivers/i2c/busses/i2c-xiic.c-2-/*\ndrivers/i2c/busses/i2c-xiic.c:3: * i2c-xiic.c\ndrivers/i2c/busses/i2c-xiic.c-4- * Copyright (c) 2002-2007 Xilinx Inc.\n--\ndrivers/i2c/busses/i2c-xiic.c-26-#include \u003clinux/completion.h\u003e\ndrivers/i2c/busses/i2c-xiic.c:27:#include \u003clinux/platform_data/i2c-xiic.h\u003e\ndrivers/i2c/busses/i2c-xiic.c-28-#include \u003clinux/io.h\u003e\n"
}

5/2 2026/09/23 17:48 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 5206
							output: 34
							thoughts: 30
						

Thoughts:
Okay, here's my take on those thoughts, framed as a first-person expert summary:

**Digging into the I2C Xilinx Driver Configuration**

Alright, my brain just went straight to `drivers/i2c/busses/Kconfig`. That's where I expect to find the configuration options for the Xilinx I2C controller driver, specifically around the `CONFIG_I2C_XILINX` symbol. I need to refresh my memory on what options are available there. I'm thinking I'll be looking for things like: whether it's enabled by default, if there are any dependencies on other configurations or hardware features (like the specific Xilinx IP core version), and what features can be optionally enabled or disabled through Kconfig options. I'll need to check if there are any specific Xilinx-related defines or variables I should be aware of. Knowing the Kconfig options will let me configure it effectively and anticipate potential issues.



6/2 2026/09/23 17:49 tool grepper
0m Args:
{
  "Expression": "config I2C_XILINX",
  "PathPrefix": "drivers/i2c"
}

Results:
{
  "Output": "drivers/i2c/busses/Kconfig=1280=config I2C_THUNDERX\n--\ndrivers/i2c/busses/Kconfig-1290-\ndrivers/i2c/busses/Kconfig:1291:config I2C_XILINX\ndrivers/i2c/busses/Kconfig-1292-\ttristate \"Xilinx I2C Controller\"\n"
}

7/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 5594
							output: 40
							thoughts: 19
						

Thoughts:
Okay, here's my interpretation of that thought process, tailored for an expert audience, and written in the first person:

**Analyzing the Kconfig Entry: I2C_XILINX**

Alright, let's dive into this `I2C_XILINX` Kconfig entry. My immediate instinct is to dissect this. I need to understand what Xilinx-specific configurations are being introduced for I2C. Is this just a driver enabling macro? Or does it also bring in options for specific Xilinx IP blocks or custom hardware implementations? I'm already looking for keywords in the entry: dependencies on other Xilinx components (like clocking or interrupt controllers, potentially). Are there any default settings for clock frequencies or bus speeds? That would be useful background, as these are all important factors to take into account.

I'll be looking for possible conflicts with other I2C drivers – are there any exclusivity checks? This could point to hardware sharing scenarios or potential architecture-specific choices. I need to note any platform dependencies: Is this just for specific Xilinx FPGA families? Or is there any Zynq or Versal System-on-Chip (SoC) integration here? I'm hoping it's well-documented, too. Good Kconfig entries should provide context beyond just the basic option definition.

Ultimately, I’m trying to determine the scope of this configuration option and how it impacts the overall system build and runtime behavior. Is this entry robust, complete, and does it provide the necessary degree of configurability to solve specific implementation or use cases, or will I need to perform my own modification or integration.



8/2 2026/09/23 17:49 tool read-file
0m Args:
{
  "File": "drivers/i2c/busses/Kconfig",
  "FirstLine": 1290,
  "LineCount": 25
}

Results:
{
  "Contents": "1290:\t\n1291:\tconfig I2C_XILINX\n1292:\t\ttristate \"Xilinx I2C Controller\"\n1293:\t\tdepends on HAS_IOMEM\n1294:\t\thelp\n1295:\t\t  If you say yes to this option, support will be included for the\n1296:\t\t  Xilinx I2C controller.\n1297:\t\n1298:\t\t  This driver can also be built as a module.  If so, the module\n1299:\t\t  will be called xilinx_i2c.\n1300:\t\n1301:\tconfig I2C_XLP9XX\n1302:\t\ttristate \"Cavium ThunderX2 I2C support\"\n1303:\t\tdepends on ARCH_THUNDER2 || COMPILE_TEST\n1304:\t\thelp\n1305:\t\t  This driver enables support for the on-chip I2C interface of\n1306:\t\t  the Cavium ThunderX2 processors. (Originally on Netlogic XLP SoCs.)\n1307:\t\n1308:\t\t  This driver can also be built as a module.  If so, the module will\n1309:\t\t  be called i2c-xlp9xx.\n1310:\t\n1311:\tconfig I2C_RCAR\n1312:\t\ttristate \"Renesas R-Car I2C Controller\"\n1313:\t\tdepends on ARCH_RENESAS || COMPILE_TEST\n1314:\t\tselect I2C_SLAVE\n"
}

9/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 6409
							output: 46
							thoughts: 44
						

Thoughts:
Okay, let's dive into this. Here's how I'd approach this task, as if these were my internal thoughts:

**Analyzing the I2C-XIIC Probe**

Alright, time to get to the core of this. First things first, I need to understand the probing mechanism of `i2c-xiic.c`. Is this driver utilizing a standard platform driver approach? I need to verify that because that shapes my expectations of how devices are being identified and initialized.

Then, I'm going to jump straight into the heart of the matter: I'll carefully examine the `i2c-xiic.c` source code, specifically focusing on the `probe` function and the device match tables. I'll need to understand how the driver matches against devices, what criteria it uses for recognizing its target hardware. That means looking for the device IDs, compatible strings, and anything else the code uses to identify and configure the I2C controller. I need to see how the kernel associates the driver with the actual hardware. I'll be looking for potential mismatches or interesting ways of matching. This is the critical step to understand if there are specific nuances or potential issues in device identification.



10/2 2026/09/23 17:49 tool grepper
0m Args:
{
  "Expression": "module_platform_driver|platform_driver",
  "PathPrefix": "drivers/i2c/busses/i2c-xiic.c"
}

Results:
{
  "Output": "drivers/i2c/busses/i2c-xiic.c=1570=static const struct dev_pm_ops xiic_dev_pm_ops = {\n--\ndrivers/i2c/busses/i2c-xiic.c-1574-\ndrivers/i2c/busses/i2c-xiic.c:1575:static struct platform_driver xiic_i2c_driver = {\ndrivers/i2c/busses/i2c-xiic.c-1576-\t.probe   = xiic_i2c_probe,\n--\ndrivers/i2c/busses/i2c-xiic.c-1584-\ndrivers/i2c/busses/i2c-xiic.c:1585:module_platform_driver(xiic_i2c_driver);\ndrivers/i2c/busses/i2c-xiic.c-1586-\n"
}

11/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 6998
							output: 46
							thoughts: 29
						

Thoughts:
Okay, let's dive into this. Here's my summary, taking on the persona you requested:

**Diving into the xiic_i2c_driver Probe Function**

Alright, I need to get a handle on this `xiic_i2c_driver`. Time to head straight to the source, to the `i2c-xiic.c` file. I specifically want to zero in on the `probe` function within that driver. I need to understand how the Xilinx I2C controller is being initialized, configured, and, ultimately, brought online. I want to see how the platform data, device tree information, or whatever configuration method is being used, is being processed and used to set the registers and states. I expect to see the standard device registration, resource allocation, and perhaps some interrupt setup. The `probe` is the starting point, the entry gate. I need to understand it to grasp the whole picture of this driver.



12/2 2026/09/23 17:49 tool read-file
0m Args:
{
  "File": "drivers/i2c/busses/i2c-xiic.c",
  "FirstLine": 1540,
  "LineCount": 50
}

Results:
{
  "Contents": "1540:\t\t\t/* add in known devices to the bus */\n1541:\t\t\tfor (i = 0; i \u003c pdata-\u003enum_devices; i++)\n1542:\t\t\t\ti2c_new_client_device(\u0026i2c-\u003eadap, pdata-\u003edevices + i);\n1543:\t\t}\n1544:\t\n1545:\t\tdev_dbg(dev, \"mmio %pR irq %d scl clock frequency %d\\n\",\n1546:\t\t\tres, irq, i2c-\u003ei2c_clk);\n1547:\t\n1548:\t\treturn 0;\n1549:\t}\n1550:\t\n1551:\tstatic void xiic_i2c_remove(struct platform_device *pdev)\n1552:\t{\n1553:\t\tstruct device *dev = \u0026pdev-\u003edev;\n1554:\t\tstruct xiic_i2c *i2c = platform_get_drvdata(pdev);\n1555:\t\tint ret;\n1556:\t\n1557:\t\t/* remove adapter \u0026 data */\n1558:\t\ti2c_del_adapter(\u0026i2c-\u003eadap);\n1559:\t\n1560:\t\tret = pm_runtime_get_sync(dev);\n1561:\t\tif (ret \u003c 0)\n1562:\t\t\tdev_warn(dev, \"Failed to activate device for removal (%pe)\\n\",\n1563:\t\t\t\t ERR_PTR(ret));\n1564:\t\telse\n1565:\t\t\txiic_deinit(i2c);\n1566:\t\n1567:\t\tpm_runtime_put_sync(dev);\n1568:\t}\n1569:\t\n1570:\tstatic const struct dev_pm_ops xiic_dev_pm_ops = {\n1571:\t\tSET_RUNTIME_PM_OPS(xiic_i2c_runtime_suspend,\n1572:\t\t\t\t   xiic_i2c_runtime_resume, NULL)\n1573:\t};\n1574:\t\n1575:\tstatic struct platform_driver xiic_i2c_driver = {\n1576:\t\t.probe   = xiic_i2c_probe,\n1577:\t\t.remove = xiic_i2c_remove,\n1578:\t\t.driver  = {\n1579:\t\t\t.name = DRIVER_NAME,\n1580:\t\t\t.of_match_table = of_match_ptr(xiic_of_match),\n1581:\t\t\t.pm = \u0026xiic_dev_pm_ops,\n1582:\t\t},\n1583:\t};\n1584:\t\n1585:\tmodule_platform_driver(xiic_i2c_driver);\n1586:\t\n1587:\tMODULE_ALIAS(\"platform:\" DRIVER_NAME);\n1588:\tMODULE_AUTHOR(\"info@mocean-labs.com\");\n1589:\tMODULE_DESCRIPTION(\"Xilinx I2C bus driver\");\n"
}

13/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 8067
							output: 46
							thoughts: 26
						

Thoughts:
Okay, here's my summary, presented as a stream of thought:

**Diving into the Xiic Driver Probe Functions**

Alright, I need to get a better handle on how this Xilinx I2C driver initializes, specifically `xiic_i2c_probe` and `xiic_of_match`. I need to understand the device tree integration and how the probe function handles that. I know the basics, but I need to see the nuances – how it handles resource allocation, clocking, interrupt setup… the whole shebang. I'm especially interested in how it interacts with the platform's device tree bindings. I'm expecting to see standard practices, but I want to confirm that it's doing everything correctly, perhaps looking for any subtle deviations from the established best practices. Let's dig in.



14/2 2026/09/23 17:49 tool read-file
0m Args:
{
  "File": "drivers/i2c/busses/i2c-xiic.c",
  "FirstLine": 1460,
  "LineCount": 80
}

Results:
{
  "Contents": "1460:\t\n1461:\t\ti2c-\u003ebase = devm_platform_get_and_ioremap_resource(pdev, 0, \u0026res);\n1462:\t\tif (IS_ERR(i2c-\u003ebase))\n1463:\t\t\treturn PTR_ERR(i2c-\u003ebase);\n1464:\t\n1465:\t\tirq = platform_get_irq(pdev, 0);\n1466:\t\tif (irq \u003c 0)\n1467:\t\t\treturn irq;\n1468:\t\n1469:\t\tpdata = dev_get_platdata(dev);\n1470:\t\n1471:\t\t/* hook up driver to tree */\n1472:\t\tplatform_set_drvdata(pdev, i2c);\n1473:\t\ti2c-\u003eadap = xiic_adapter;\n1474:\t\ti2c-\u003eadap.nr = pdev-\u003eid;\n1475:\t\ti2c_set_adapdata(\u0026i2c-\u003eadap, i2c);\n1476:\t\ti2c-\u003eadap.dev.parent = \u0026pdev-\u003edev;\n1477:\t\tdevice_set_node(\u0026i2c-\u003eadap.dev, fwnode);\n1478:\t\tsnprintf(i2c-\u003eadap.name, sizeof(i2c-\u003eadap.name),\n1479:\t\t\t DRIVER_NAME \" %s\", pdev-\u003ename);\n1480:\t\n1481:\t\tret = devm_mutex_init(dev, \u0026i2c-\u003elock);\n1482:\t\tif (ret)\n1483:\t\t\treturn ret;\n1484:\t\n1485:\t\tspin_lock_init(\u0026i2c-\u003eatomic_lock);\n1486:\t\n1487:\t\tif (is_of_node(fwnode)) {\n1488:\t\t\ti2c-\u003eclk = devm_clk_get_enabled(dev, NULL);\n1489:\t\t\tif (IS_ERR(i2c-\u003eclk))\n1490:\t\t\t\treturn dev_err_probe(dev, PTR_ERR(i2c-\u003eclk),\n1491:\t\t\t\t\t\t\"failed to enable input clock.\\n\");\n1492:\t\t}\n1493:\t\n1494:\t\ti2c-\u003edev = dev;\n1495:\t\n1496:\t\tpm_runtime_set_autosuspend_delay(dev, XIIC_PM_TIMEOUT);\n1497:\t\tpm_runtime_use_autosuspend(dev);\n1498:\t\tret = devm_pm_runtime_set_active_enabled(dev);\n1499:\t\tif (ret)\n1500:\t\t\treturn ret;\n1501:\t\n1502:\t\t/* SCL frequency configuration */\n1503:\t\ti2c-\u003einput_clk = clk_get_rate(i2c-\u003eclk);\n1504:\t\tret = device_property_read_u32(dev, \"clock-frequency\", \u0026i2c-\u003ei2c_clk);\n1505:\t\t/* If clock-frequency not specified in DT, do not configure in SW */\n1506:\t\tif (ret || i2c-\u003ei2c_clk \u003e I2C_MAX_FAST_MODE_PLUS_FREQ)\n1507:\t\t\ti2c-\u003ei2c_clk = 0;\n1508:\t\n1509:\t\tret = devm_request_threaded_irq(dev, irq, NULL, xiic_process,\n1510:\t\t\t\t\t\tIRQF_ONESHOT, pdev-\u003ename, i2c);\n1511:\t\tif (ret)\n1512:\t\t\treturn ret;\n1513:\t\n1514:\t\ti2c-\u003esinglemaster = device_property_read_bool(dev, \"single-master\");\n1515:\t\n1516:\t\t/*\n1517:\t\t * Detect endianness\n1518:\t\t * Try to reset the TX FIFO. Then check the EMPTY flag. If it is not\n1519:\t\t * set, assume that the endianness was wrong and swap.\n1520:\t\t */\n1521:\t\ti2c-\u003eendianness = LITTLE;\n1522:\t\txiic_setreg32(i2c, XIIC_CR_REG_OFFSET, XIIC_CR_TX_FIFO_RESET_MASK);\n1523:\t\t/* Reset is cleared in xiic_reinit */\n1524:\t\tsr = xiic_getreg32(i2c, XIIC_SR_REG_OFFSET);\n1525:\t\tif (!(sr \u0026 XIIC_SR_TX_FIFO_EMPTY_MASK))\n1526:\t\t\ti2c-\u003eendianness = BIG;\n1527:\t\n1528:\t\tret = xiic_reinit(i2c);\n1529:\t\tif (ret)\n1530:\t\t\treturn dev_err_probe(dev, ret, \"Cannot xiic_reinit\\n\");\n1531:\t\n1532:\t\t/* add i2c adapter to i2c tree */\n1533:\t\tret = i2c_add_numbered_adapter(\u0026i2c-\u003eadap);\n1534:\t\tif (ret) {\n1535:\t\t\txiic_deinit(i2c);\n1536:\t\t\treturn ret;\n1537:\t\t}\n1538:\t\n1539:\t\tif (pdata) {\n"
}

15/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 9703
							output: 46
							thoughts: 19
						

Thoughts:
Okay, here's my interpretation of that thought process, tailored for an expert audience, and written in the first person:

**Analyzing Driver and Match Relationships**

Alright, my internal gears are already turning. The mention of `DRIVER_NAME` immediately flags a specific system component - a driver, presumably for some piece of hardware or software. I need to understand its role and interactions. Then we have `xiic_of_match`. This suggests a relationship or association is in play. The 'xiic' prefix (or similar) is a convention, and the use of 'match' makes me think about an instance in a linked data type, a pointer within a set, an entity in a relational table, or an object stored inside of an array. The precise nature depends on the surrounding context, and I'd need more information to be certain. My mind is already searching for the likely data structures and control flow patterns these elements would be embedded within. It's a process of connecting the driver to specific matching criteria or objects. This looks like a step toward figuring out how some mechanism is selecting drivers or managing resources.



16/2 2026/09/23 17:49 tool read-file
0m Args:
{
  "File": "drivers/i2c/busses/i2c-xiic.c",
  "FirstLine": 1430,
  "LineCount": 30
}

Results:
{
  "Contents": "1430:\tstatic const struct xiic_version_data xiic_2_00 = {\n1431:\t\t.quirks = DYNAMIC_MODE_READ_BROKEN_BIT,\n1432:\t};\n1433:\t\n1434:\tstatic const struct of_device_id xiic_of_match[] = {\n1435:\t\t{ .compatible = \"xlnx,xps-iic-2.00.a\", .data = \u0026xiic_2_00 },\n1436:\t\t{ .compatible = \"xlnx,axi-iic-2.1\", },\n1437:\t\t{},\n1438:\t};\n1439:\tMODULE_DEVICE_TABLE(of, xiic_of_match);\n1440:\t\n1441:\tstatic int xiic_i2c_probe(struct platform_device *pdev)\n1442:\t{\n1443:\t\tstruct device *dev = \u0026pdev-\u003edev;\n1444:\t\tstruct fwnode_handle *fwnode = dev_fwnode(dev);\n1445:\t\tstruct xiic_i2c *i2c;\n1446:\t\tstruct xiic_i2c_platform_data *pdata;\n1447:\t\tconst struct xiic_version_data *data;\n1448:\t\tstruct resource *res;\n1449:\t\tint ret, irq;\n1450:\t\tu8 i;\n1451:\t\tu32 sr;\n1452:\t\n1453:\t\ti2c = devm_kzalloc(dev, sizeof(*i2c), GFP_KERNEL);\n1454:\t\tif (!i2c)\n1455:\t\t\treturn -ENOMEM;\n1456:\t\n1457:\t\tdata = device_get_match_data(dev);\n1458:\t\tif (data)\n1459:\t\t\ti2c-\u003equirks = data-\u003equirks;\n"
}

17/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 10514
							output: 20
							thoughts: 285
						

Thoughts:
**Analyzing I2C Driver Instantiation in Virtualized Environments**

Okay, let's break this down. First, I'm looking at the driver implementations here: `xiic_of_match`, `xlnx,xps-iic-2.00.a`, `xlnx,axi-iic-2.1`, and the `xiic_i2c_driver`. I see the driver's name is "xiic-i2c." My initial thought is, can this driver even *exist* in a standard virtualized environment like QEMU or Google Compute Engine running on amd64? This is a key question.

Can a platform device even be created from user space? Could it be set up via Syzkaller? Device Tree overlays? ConfigFS? Specifically, Syzkaller, in my experience, isn't going to randomly whip up platform devices with memory-mapped I/O resources and interrupts unless there's an emulation layer.

Now, a critical point: can QEMU even *emulate* `xlnx,xps-iic-2.00.a`? That's the real test. I need to check QEMU's capabilities and see if any x86/amd64 platforms actually instantiate "xiic-i2c." Is it actually even available on x86? Does x86 have either `xlnx,xps-iic-2.00.a` or the "xiic-i2c" name? Time to dive into the kernel source and search for any references to `xiic_i2c`, `xiic-i2c`, or `xps-iic`. This will be the clearest indicator of whether this driver is actually relevant in the environments I'm concerned with.



18/2 2026/09/23 17:49 tool grepper
0m Args:
{
  "Expression": "xiic-i2c"
}

Results:
{
  "Output": "drivers/i2c/busses/i2c-xiic.c-34-\ndrivers/i2c/busses/i2c-xiic.c:35:#define DRIVER_NAME \"xiic-i2c\"\ndrivers/i2c/busses/i2c-xiic.c-36-#define DYNAMIC_MODE_READ_BROKEN_BIT\tBIT(0)\n--\ndrivers/media/pci/mgb4/mgb4_core.c=269=static int init_i2c(struct mgb4_dev *mgbdev)\n--\ndrivers/media/pci/mgb4/mgb4_core.c-291-\ndrivers/media/pci/mgb4/mgb4_core.c:292:\trequest_module(\"platform:xiic-i2c\");\ndrivers/media/pci/mgb4/mgb4_core.c-293-\n--\ndrivers/media/pci/mgb4/mgb4_core.c-304-\ndrivers/media/pci/mgb4/mgb4_core.c:305:\t/* create dummy clock required by the xiic-i2c adapter */\ndrivers/media/pci/mgb4/mgb4_core.c:306:\tsnprintf(clk_name, sizeof(clk_name), \"xiic-i2c.%d\", id);\ndrivers/media/pci/mgb4/mgb4_core.c-307-\tmgbdev-\u003ei2c_clk = clk_hw_register_fixed_rate(NULL, clk_name, NULL,\n--\ndrivers/media/pci/mgb4/mgb4_core.c-312-\t}\ndrivers/media/pci/mgb4/mgb4_core.c:313:\tmgbdev-\u003ei2c_cl = clkdev_hw_create(mgbdev-\u003ei2c_clk, NULL, \"xiic-i2c.%d\",\ndrivers/media/pci/mgb4/mgb4_core.c-314-\t\t\t\t\t  id);\n--\ndrivers/media/pci/mgb4/mgb4_core.c-320-\ndrivers/media/pci/mgb4/mgb4_core.c:321:\tmgbdev-\u003ei2c_pdev = platform_device_register_resndata(dev, \"xiic-i2c\",\ndrivers/media/pci/mgb4/mgb4_core.c-322-\t\t\t\t\t\t\t     id, i2c_resources,\n--\ndrivers/media/pci/mgb4/mgb4_core.c=714=MODULE_LICENSE(\"GPL\");\ndrivers/media/pci/mgb4/mgb4_core.c:715:MODULE_SOFTDEP(\"pre: platform:xiic-i2c platform:xilinx_spi spi-nor\");\n--\ndrivers/mfd/timberdale.c=369=static const struct mfd_cell timberdale_cells_bar0_cfg0[] = {\n--\ndrivers/mfd/timberdale.c-382-\t{\ndrivers/mfd/timberdale.c:383:\t\t.name = \"xiic-i2c\",\ndrivers/mfd/timberdale.c-384-\t\t.num_resources = ARRAY_SIZE(timberdale_xiic_resources),\n--\ndrivers/mfd/timberdale.c=426=static const struct mfd_cell timberdale_cells_bar0_cfg1[] = {\n--\ndrivers/mfd/timberdale.c-444-\t{\ndrivers/mfd/timberdale.c:445:\t\t.name = \"xiic-i2c\",\ndrivers/mfd/timberdale.c-446-\t\t.num_resources = ARRAY_SIZE(timberdale_xiic_resources),\n--\ndrivers/mfd/timberdale.c=493=static const struct mfd_cell timberdale_cells_bar0_cfg2[] = {\n--\ndrivers/mfd/timberdale.c-506-\t{\ndrivers/mfd/timberdale.c:507:\t\t.name = \"xiic-i2c\",\ndrivers/mfd/timberdale.c-508-\t\t.num_resources = ARRAY_SIZE(timberdale_xiic_resources),\n--\ndrivers/ptp/ptp_ocp.c=541=static struct ocp_resource ocp_fb_resource[] = {\n--\ndrivers/ptp/ptp_ocp.c-688-\t\t.extra = \u0026(struct ptp_ocp_i2c_info) {\ndrivers/ptp/ptp_ocp.c:689:\t\t\t.name = \"xiic-i2c\",\ndrivers/ptp/ptp_ocp.c-690-\t\t\t.fixed_rate = 50000000,\n--\ndrivers/ptp/ptp_ocp.c=1074=static struct ocp_resource ocp_adva_x1_resource[] = {\n--\ndrivers/ptp/ptp_ocp.c-1248-\t\t.extra = \u0026(struct ptp_ocp_i2c_info) {\ndrivers/ptp/ptp_ocp.c:1249:\t\t\t.name = \"xiic-i2c\",\ndrivers/ptp/ptp_ocp.c-1250-\t\t\t.fixed_rate = 50000000,\n"
}

19/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 12571
							output: 47
							thoughts: 979
						

Thoughts:
**Analyzing the Reachability of `xiic-i2c` for Fuzzing**

Okay, so I need to figure out if this `xiic-i2c` code is even *reachable* in a standard fuzzing environment (QEMU or GCE). Let's break this down. First, I see where `xiic-i2c` is used: it's tied to Digiteq's MGB4 PCIe card, the Timberdale FPGA, the OpenCompute TimeCard, and various Xilinx SoCs via device tree nodes. Right away, alarms are going off – none of these are likely to be standard QEMU devices.

Let's confirm that suspicion. The MGB4, Timberdale, and TimeCard are *physical* PCIe cards; definitely not emulated. Then, Xilinx DT support... Wait, this is an amd64 target! On amd64, there's no Xilinx Zynq DT.

Okay, so the big question: can `xiic-i2c` be hit in a typical virtualized environment? The instructions are super clear: reachability is the primary gate. If the code is structurally unreachable in a standard virtualized environment, it's a no-go for fuzzing, no matter how much logic it might contain.

So, let's look for clues... Does QEMU emulate `xlnx,xps-iic-2.00.a` or anything related, or have any support for `xiic-i2c` on amd64? QEMU *does* have some Xilinx board emulations, like the `xlnx-zcu102`, but for ARM architectures. This is amd64! Is there *any* QEMU PCI device or sysfs mechanism to instantiate a platform device or i2c adapter that's relevant? Can a user instantiate a platform device from userspace?

In Linux, unless `CONFIG_OF_CONFIGFS` is enabled, and a DTBO is loaded, a user can't create platform devices. But on x86/amd64, DT isn't used (ACPI is), and syzkaller doesn't load DT overlays. What about ACPI? Does ACPI even *have* `xiic`? Nope. `xiic` only has OF and platform name.

Alright, what about sysfs? `/sys/bus/platform/drivers/xiic-i2c/bind` only *binds* existing platform devices. There are no `xiic-i2c` platform devices created on amd64 in QEMU/GCE, it seems. And are there any dummy/mock/test drivers in `i2c-xiic.c`? No. This is a real hardware bus driver.

Okay, let's shift gears. What *exactly* does `i2c-xiic.c` do and what was changed in the patch? It looks like it fixes an SMBus block read issue. Now, I have to figure out *why* this patch was even written, and get context: check the commit message or the wider context. We have a git grep for SMBUS_BLOCK_READ_MIN_LEN in `drivers/i2c/busses/i2c-xiic.c`.



20/2 2026/09/23 17:49 tool grepper
0m Args:
{
  "Expression": "SMBUS_BLOCK_READ_MIN_LEN",
  "PathPrefix": "drivers/i2c/busses/i2c-xiic.c"
}

Results:
{
  "Output": "drivers/i2c/busses/i2c-xiic.c-36-#define DYNAMIC_MODE_READ_BROKEN_BIT\tBIT(0)\ndrivers/i2c/busses/i2c-xiic.c:37:#define SMBUS_BLOCK_READ_MIN_LEN\t3\ndrivers/i2c/busses/i2c-xiic.c-38-\n--\ndrivers/i2c/busses/i2c-xiic.c=526=static void xiic_smbus_block_read_setup(struct xiic_i2c *i2c)\n--\ndrivers/i2c/busses/i2c-xiic.c-556-\t\t\ti2c-\u003erx_msg-\u003elen = rxmsg_len + 1 + pec_len;\ndrivers/i2c/busses/i2c-xiic.c:557:\t\t} else if (1 + rxmsg_len + pec_len \u003c SMBUS_BLOCK_READ_MIN_LEN) {\ndrivers/i2c/busses/i2c-xiic.c-558-\t\t\t/*\ndrivers/i2c/busses/i2c-xiic.c:559:\t\t\t * The HW needs SMBUS_BLOCK_READ_MIN_LEN bytes on the\ndrivers/i2c/busses/i2c-xiic.c-560-\t\t\t * bus to exit cleanly: by the time the ISR reads the\n--\ndrivers/i2c/busses/i2c-xiic.c-566-\t\t\trfd_set = 0;\ndrivers/i2c/busses/i2c-xiic.c:567:\t\t\ti2c-\u003erx_msg-\u003elen = SMBUS_BLOCK_READ_MIN_LEN;\ndrivers/i2c/busses/i2c-xiic.c-568-\t\t\ti2c-\u003esmbus_actual_len = 1 + rxmsg_len + pec_len;\n"
}

21/2 2026/09/23 17:49 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 14797
							output: 32
							thoughts: 428
						

Thoughts:
**My Assessment of syzkaller's I2C Coverage and xiic's Feasibility**

Okay, let's dive into this I2C situation within the context of syzkaller. I need to figure out if it has any existing support or descriptions specific to "xiic," or more generally, how it handles I2C interfaces. My initial thought is to check for the presence of `/dev/i2c-*` descriptions, and, sure enough, I find `dev_i2c.txt`. That's a good starting point.  This means syzkaller likely targets `/dev/i2c-N` where userspace can perform `ioctl(fd, I2C_SMBUS, ...)` or `ioctl(fd, I2C_RDWR, ...)` operations.  If an I2C adapter is registered correctly, then the user space should be able to send I2C and SMBus transactions through these `/dev/i2c-X` nodes.

But here's the crucial question: can the `i2c-xiic` driver *ever* actually register an adapter in typical virtualized environments like QEMU or GCE, specifically on amd64? This is what I need to investigate.

My immediate question is, how would `xiic_i2c_probe` even get called? It's triggered when a device matches the `xiic_i2c_driver`. So, the more fundamental question becomes: how could a device that matches the `xiic_i2c_driver` be created in these environments?  I see two primary avenues:

1.  **OpenFirmware (Device Tree):** However, on amd64, QEMU typically boots with ACPI, not Device Tree. Even if Device Tree were used, standard QEMU x86_64/amd64 configurations don't include Xilinx XPS or AXI IIC IP cores. This approach seems highly unlikely.

2.  **Platform Device Registered by Code:** This is where I need to look closely. I'll need to search the kernel source to see where `"xiic-i2c"` (or similar names) is used. Let's see...I did a grep, the results are:
    *   `drivers/media/pci/mgb4/mgb4_core.c`
    *   `drivers/mfd/timberdale.c`
    *   `drivers/ptp/ptp_ocp.c`
    *   `drivers/i2c/busses/i2c-xiic.c`
    Are there any other locations? It doesn't look like it!

Okay, it seems those are the only places in the kernel. Let's broaden the search slightly to include `xps-iic` and `axi-iic`. Hopefully, this will give me a clearer picture of how feasible `i2c-xiic` is in my target environments.



22/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "xlnx,xps-iic|xlnx,axi-iic"
}

Results:
{
  "Output": "Documentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-3----\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml:4:$id: http://devicetree.org/schemas/i2c/xlnx,xps-iic-2.00.a.yaml#\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-5-$schema: http://devicetree.org/meta-schemas/core.yaml#\n--\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml=15=properties:\n--\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-17-    enum:\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml:18:      - xlnx,axi-iic-2.1\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml:19:      - xlnx,xps-iic-2.00.a\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-20-\n--\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml=50=examples:\n--\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-52-    axi_iic_0: i2c@40800000 {\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml:53:      compatible = \"xlnx,xps-iic-2.00.a\";\nDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml-54-      clocks = \u003c\u0026clkc 15\u003e;\n--\nMAINTAINERS=3797=F:\tDocumentation/devicetree/bindings/i2c/cdns,i2c-r1p10.yaml\nMAINTAINERS:3798:F:\tDocumentation/devicetree/bindings/i2c/xlnx,xps-iic-2.00.a.yaml\nMAINTAINERS-3799-F:\tDocumentation/devicetree/bindings/memory-controllers/snps,dw-umctl2-ddrc.yaml\n--\narch/microblaze/boot/dts/system.dts=225=\t\tIIC_EEPROM: i2c@81600000 {\narch/microblaze/boot/dts/system.dts:226:\t\t\tcompatible = \"xlnx,xps-iic-2.00.a\";\narch/microblaze/boot/dts/system.dts-227-\t\t\tinterrupt-parent = \u003c\u0026xps_intc_0\u003e;\n--\narch/mips/boot/dts/xilfpga/nexys4ddr.dts=93=\taxi_i2c: i2c@10a00000 {\narch/mips/boot/dts/xilfpga/nexys4ddr.dts:94:\t    compatible = \"xlnx,xps-iic-2.00.a\";\narch/mips/boot/dts/xilfpga/nexys4ddr.dts-95-\t    interrupt-parent = \u003c\u0026axi_intc\u003e;\n--\ndrivers/i2c/busses/i2c-xiic.c=1252=static int xiic_start_xfer(struct xiic_i2c *i2c, struct i2c_msg *msgs, int num)\n--\ndrivers/i2c/busses/i2c-xiic.c-1311-\t * If read transaction as dynamic mode is broken for delayed reads\ndrivers/i2c/busses/i2c-xiic.c:1312:\t * in xlnx,axi-iic-2.0 / xlnx,xps-iic-2.00.a IP versions.\ndrivers/i2c/busses/i2c-xiic.c-1313-\t * If read length is \u003e 255 bytes.\n--\ndrivers/i2c/busses/i2c-xiic.c=1434=static const struct of_device_id xiic_of_match[] = {\ndrivers/i2c/busses/i2c-xiic.c:1435:\t{ .compatible = \"xlnx,xps-iic-2.00.a\", .data = \u0026xiic_2_00 },\ndrivers/i2c/busses/i2c-xiic.c:1436:\t{ .compatible = \"xlnx,axi-iic-2.1\", },\ndrivers/i2c/busses/i2c-xiic.c-1437-\t{},\n"
}

23/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 17253
							output: 33
							thoughts: 55
						

Thoughts:
Here's my summary, as the expert:

**Investigating PCI Driver Instantiations of xiic-i2c**

Okay, so I need to quickly identify how the `xiic-i2c` driver is being instantiated within the PCI context. Specifically, I want to pinpoint the drivers that are creating instances of this I2C driver via the PCI bus.  I've got a hunch, but let's confirm.  I'll start by checking the obvious candidate: `drivers/media/pci/mgb4/mgb4_core.c`.  My first move will be to examine that specific file to understand its PCI vendor and device IDs. This will allow me to correlate this instantiation with the hardware itself, and understand the intended use case.  Understanding the PCI IDs will give me a vital clue as to the intended hardware that uses this driver and its I2C communication.



24/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "PCI_DEVICE",
  "PathPrefix": "drivers/media/pci/mgb4"
}

Results:
{
  "Output": "drivers/media/pci/mgb4/mgb4_core.c=696=static const struct pci_device_id mgb4_pci_ids[] = {\ndrivers/media/pci/mgb4/mgb4_core.c:697:\t{ PCI_DEVICE(DIGITEQ_VID, T100_DID), },\ndrivers/media/pci/mgb4/mgb4_core.c:698:\t{ PCI_DEVICE(DIGITEQ_VID, T200_DID), },\ndrivers/media/pci/mgb4/mgb4_core.c-699-\t{ 0, }\n"
}

25/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 17706
							output: 32
							thoughts: 25
						

Thoughts:
Here's my analysis of the provided snippet, tailored for an expert audience and presented as if it were my thought process:

**Diving into the Timberdale Driver**

Okay, so we're looking at `drivers/mfd/timberdale.c`. My immediate thought is, "Right, Timberdale... probably some kind of multi-function device (MFD) controller." We're likely dealing with something that handles multiple sub-devices or functions, and this driver is the glue for it. The first order of business, as always when I encounter a new driver, is to establish its hardware profile. So, I need to understand what specific devices this driver supports.

Specifically, I need to know which PCI IDs Timberdale is compatible with. This will be the key to understanding which physical hardware this driver is designed to interact with. By identifying the PCI IDs, I can quickly reference datasheets, block diagrams, and other documentation for any relevant hardware. With the PCI ID information in hand, I can immediately start mapping the registers and exploring the driver's core functionality.



26/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "PCI_DEVICE",
  "PathPrefix": "drivers/mfd/timberdale.c"
}

Results:
{
  "Output": "drivers/mfd/timberdale.c=843=static const struct pci_device_id timberdale_pci_tbl[] = {\ndrivers/mfd/timberdale.c:844:\t{ PCI_DEVICE(PCI_VENDOR_ID_TIMB, PCI_DEVICE_ID_TIMB) },\ndrivers/mfd/timberdale.c-845-\t{ 0 }\n"
}

27/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 18092
							output: 35
							thoughts: 31
						

Thoughts:
Okay, here's my take on those thoughts, tailored for an expert audience, and written as if they were my own:

**Investigating the PCI ID Landscape in `drivers/ptp/ptp_ocp.c`**

Alright, let's dive into the `drivers/ptp/ptp_ocp.c` file. My immediate focus is going to be on the PCI device IDs associated with the ptp_ocp driver. I need to understand which specific hardware this driver is intended to support. Knowing the PCI IDs is fundamental – it’s the key to understanding the intended hardware targets and the design assumptions the driver makes. This will guide my understanding of the register offsets and configurations and let me see if anything is missing.



28/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "PCI_DEVICE",
  "PathPrefix": "drivers/ptp/ptp_ocp.c"
}

Results:
{
  "Output": "drivers/ptp/ptp_ocp.c-27-\ndrivers/ptp/ptp_ocp.c:28:#define PCI_DEVICE_ID_META_TIMECARD\t\t0x0400\ndrivers/ptp/ptp_ocp.c-29-\ndrivers/ptp/ptp_ocp.c-30-#define PCI_VENDOR_ID_CELESTICA\t\t\t0x18d4\ndrivers/ptp/ptp_ocp.c:31:#define PCI_DEVICE_ID_CELESTICA_TIMECARD\t0x1008\ndrivers/ptp/ptp_ocp.c-32-\ndrivers/ptp/ptp_ocp.c-33-#define PCI_VENDOR_ID_OROLIA\t\t\t0x1ad7\ndrivers/ptp/ptp_ocp.c:34:#define PCI_DEVICE_ID_OROLIA_ARTCARD\t\t0xa000\ndrivers/ptp/ptp_ocp.c-35-\ndrivers/ptp/ptp_ocp.c-36-#define PCI_VENDOR_ID_ADVA\t\t\t0xad5a\ndrivers/ptp/ptp_ocp.c:37:#define PCI_DEVICE_ID_ADVA_TIMECARD\t\t0x0400\ndrivers/ptp/ptp_ocp.c:38:#define PCI_DEVICE_ID_ADVA_TIMECARD_X1\t\t0x0410\ndrivers/ptp/ptp_ocp.c-39-\n--\ndrivers/ptp/ptp_ocp.c=1281=static const struct pci_device_id ptp_ocp_pcidev_id[] = {\ndrivers/ptp/ptp_ocp.c:1282:\t{ PCI_DEVICE_DATA(META, TIMECARD, \u0026ocp_fb_resource) },\ndrivers/ptp/ptp_ocp.c:1283:\t{ PCI_DEVICE_DATA(CELESTICA, TIMECARD, \u0026ocp_fb_resource) },\ndrivers/ptp/ptp_ocp.c:1284:\t{ PCI_DEVICE_DATA(OROLIA, ARTCARD, \u0026ocp_art_resource) },\ndrivers/ptp/ptp_ocp.c:1285:\t{ PCI_DEVICE_DATA(ADVA, TIMECARD, \u0026ocp_adva_resource) },\ndrivers/ptp/ptp_ocp.c:1286:\t{ PCI_DEVICE_DATA(ADVA, TIMECARD_X1, \u0026ocp_adva_x1_resource) },\ndrivers/ptp/ptp_ocp.c-1287-\t{ }\n"
}

29/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 18991
							output: 16
							thoughts: 187
						

Thoughts:
**Investigating PCI Device Emulation in QEMU**

Okay, so none of these PCI devices – the Digiteq MGB4, Timberdale FPGA, or the Meta/Celestica/Orolia/Adva TimeCard – are standard, out-of-the-box QEMU or GCE devices. That's the first obvious point. And, therefore, they are *not* emulated by QEMU. Just to be absolutely sure, let's explicitly confirm: Does QEMU have direct support for `mgb4`? Nope. What about `timberdale`? Nope. Okay, how about `ptp_ocp` or `timecard`? Negative. And, finally, `xlnx-axi-iic` on x86_64? Still a no.

Wait a second, though… could this `xiic-i2c` be instantiated in *any* other way, perhaps using a more generic method or through some other configuration? It's worth a second look, and I will be looking for any alternative kernel modules referencing 'xiic.' I will `grep` for `xiic` across the entire kernel source tree to see if it shows up anywhere else.



30/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "xiic"
}

Results:
{
  "Output": "\nFull output is too long, showing 500 out of 839 lines.\nUse more precise expression if possible.\n\nMAINTAINERS=3807=F:\tdrivers/i2c/busses/i2c-cadence.c\nMAINTAINERS:3808:F:\tdrivers/i2c/busses/i2c-xiic.c\nMAINTAINERS-3809-F:\tdrivers/mmc/host/sdhci-of-arasan.c\n--\ndrivers/i2c/busses/Makefile=128=i2c-thunderx-y\t\t\t:= i2c-octeon-core.o i2c-thunderx-pcidrv.o\ndrivers/i2c/busses/Makefile:129:obj-$(CONFIG_I2C_XILINX)\t+= i2c-xiic.o\ndrivers/i2c/busses/Makefile-130-obj-$(CONFIG_I2C_XLP9XX)\t+= i2c-xlp9xx.o\n--\ndrivers/i2c/busses/i2c-xiic.c-2-/*\ndrivers/i2c/busses/i2c-xiic.c:3: * i2c-xiic.c\ndrivers/i2c/busses/i2c-xiic.c-4- * Copyright (c) 2002-2007 Xilinx Inc.\n--\ndrivers/i2c/busses/i2c-xiic.c-26-#include \u003clinux/completion.h\u003e\ndrivers/i2c/busses/i2c-xiic.c:27:#include \u003clinux/platform_data/i2c-xiic.h\u003e\ndrivers/i2c/busses/i2c-xiic.c-28-#include \u003clinux/io.h\u003e\n--\ndrivers/i2c/busses/i2c-xiic.c-34-\ndrivers/i2c/busses/i2c-xiic.c:35:#define DRIVER_NAME \"xiic-i2c\"\ndrivers/i2c/busses/i2c-xiic.c-36-#define DYNAMIC_MODE_READ_BROKEN_BIT\tBIT(0)\n--\ndrivers/i2c/busses/i2c-xiic.c=39=enum xilinx_i2c_state {\n--\ndrivers/i2c/busses/i2c-xiic.c-44-\ndrivers/i2c/busses/i2c-xiic.c:45:enum xiic_endian {\ndrivers/i2c/busses/i2c-xiic.c-46-\tLITTLE,\n--\ndrivers/i2c/busses/i2c-xiic.c=50=enum i2c_scl_freq {\n--\ndrivers/i2c/busses/i2c-xiic.c-56-/**\ndrivers/i2c/busses/i2c-xiic.c:57: * struct xiic_i2c - Internal representation of the XIIC I2C bus\ndrivers/i2c/busses/i2c-xiic.c-58- * @dev: Pointer to device structure\n--\ndrivers/i2c/busses/i2c-xiic.c-84- */\ndrivers/i2c/busses/i2c-xiic.c:85:struct xiic_i2c {\ndrivers/i2c/busses/i2c-xiic.c-86-\tstruct device *dev;\n--\ndrivers/i2c/busses/i2c-xiic.c-95-\tint rx_pos;\ndrivers/i2c/busses/i2c-xiic.c:96:\tenum xiic_endian endianness;\ndrivers/i2c/busses/i2c-xiic.c-97-\tstruct clk *clk;\n--\ndrivers/i2c/busses/i2c-xiic.c-111-\ndrivers/i2c/busses/i2c-xiic.c:112:struct xiic_version_data {\ndrivers/i2c/busses/i2c-xiic.c-113-\tu32 quirks;\n--\ndrivers/i2c/busses/i2c-xiic.c=133=static const struct timing_regs timing_reg_values[] = {\n--\ndrivers/i2c/busses/i2c-xiic.c-247-\ndrivers/i2c/busses/i2c-xiic.c:248:#define xiic_tx_space(i2c) ((i2c)-\u003etx_msg-\u003elen - (i2c)-\u003etx_pos)\ndrivers/i2c/busses/i2c-xiic.c:249:#define xiic_rx_space(i2c) ((i2c)-\u003erx_msg-\u003elen - (i2c)-\u003erx_pos)\ndrivers/i2c/busses/i2c-xiic.c-250-\ndrivers/i2c/busses/i2c-xiic.c:251:static int xiic_start_xfer(struct xiic_i2c *i2c, struct i2c_msg *msgs, int num);\ndrivers/i2c/busses/i2c-xiic.c:252:static void __xiic_start_xfer(struct xiic_i2c *i2c);\ndrivers/i2c/busses/i2c-xiic.c-253-\ndrivers/i2c/busses/i2c-xiic.c:254:static int xiic_i2c_runtime_suspend(struct device *dev)\ndrivers/i2c/busses/i2c-xiic.c-255-{\ndrivers/i2c/busses/i2c-xiic.c:256:\tstruct xiic_i2c *i2c = dev_get_drvdata(dev);\ndrivers/i2c/busses/i2c-xiic.c-257-\n--\ndrivers/i2c/busses/i2c-xiic.c-262-\ndrivers/i2c/busses/i2c-xiic.c:263:static int xiic_i2c_runtime_resume(struct device *dev)\ndrivers/i2c/busses/i2c-xiic.c-264-{\ndrivers/i2c/busses/i2c-xiic.c:265:\tstruct xiic_i2c *i2c = dev_get_drvdata(dev);\ndrivers/i2c/busses/i2c-xiic.c-266-\tint ret;\n--\ndrivers/i2c/busses/i2c-xiic.c-284-\ndrivers/i2c/busses/i2c-xiic.c:285:static inline void xiic_setreg8(struct xiic_i2c *i2c, int reg, u8 value)\ndrivers/i2c/busses/i2c-xiic.c-286-{\n--\ndrivers/i2c/busses/i2c-xiic.c-292-\ndrivers/i2c/busses/i2c-xiic.c:293:static inline u8 xiic_getreg8(struct xiic_i2c *i2c, int reg)\ndrivers/i2c/busses/i2c-xiic.c-294-{\n--\ndrivers/i2c/busses/i2c-xiic.c-303-\ndrivers/i2c/busses/i2c-xiic.c:304:static inline void xiic_setreg16(struct xiic_i2c *i2c, int reg, u16 value)\ndrivers/i2c/busses/i2c-xiic.c-305-{\n--\ndrivers/i2c/busses/i2c-xiic.c-311-\ndrivers/i2c/busses/i2c-xiic.c:312:static inline void xiic_setreg32(struct xiic_i2c *i2c, int reg, int value)\ndrivers/i2c/busses/i2c-xiic.c-313-{\n--\ndrivers/i2c/busses/i2c-xiic.c-319-\ndrivers/i2c/busses/i2c-xiic.c:320:static inline int xiic_getreg32(struct xiic_i2c *i2c, int reg)\ndrivers/i2c/busses/i2c-xiic.c-321-{\n--\ndrivers/i2c/busses/i2c-xiic.c-330-\ndrivers/i2c/busses/i2c-xiic.c:331:static inline void xiic_irq_dis(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-332-{\ndrivers/i2c/busses/i2c-xiic.c:333:\tu32 ier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-334-\ndrivers/i2c/busses/i2c-xiic.c:335:\txiic_setreg32(i2c, XIIC_IIER_OFFSET, ier \u0026 ~mask);\ndrivers/i2c/busses/i2c-xiic.c-336-}\ndrivers/i2c/busses/i2c-xiic.c-337-\ndrivers/i2c/busses/i2c-xiic.c:338:static inline void xiic_irq_en(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-339-{\ndrivers/i2c/busses/i2c-xiic.c:340:\tu32 ier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-341-\ndrivers/i2c/busses/i2c-xiic.c:342:\txiic_setreg32(i2c, XIIC_IIER_OFFSET, ier | mask);\ndrivers/i2c/busses/i2c-xiic.c-343-}\ndrivers/i2c/busses/i2c-xiic.c-344-\ndrivers/i2c/busses/i2c-xiic.c:345:static inline void xiic_irq_clr(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-346-{\ndrivers/i2c/busses/i2c-xiic.c:347:\tu32 isr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-348-\ndrivers/i2c/busses/i2c-xiic.c:349:\txiic_setreg32(i2c, XIIC_IISR_OFFSET, isr \u0026 mask);\ndrivers/i2c/busses/i2c-xiic.c-350-}\ndrivers/i2c/busses/i2c-xiic.c-351-\ndrivers/i2c/busses/i2c-xiic.c:352:static inline void xiic_irq_clr_en(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-353-{\ndrivers/i2c/busses/i2c-xiic.c:354:\txiic_irq_clr(i2c, mask);\ndrivers/i2c/busses/i2c-xiic.c:355:\txiic_irq_en(i2c, mask);\ndrivers/i2c/busses/i2c-xiic.c-356-}\ndrivers/i2c/busses/i2c-xiic.c-357-\ndrivers/i2c/busses/i2c-xiic.c:358:static int xiic_clear_rx_fifo(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-359-{\n--\ndrivers/i2c/busses/i2c-xiic.c-363-\ttimeout = jiffies + XIIC_I2C_TIMEOUT;\ndrivers/i2c/busses/i2c-xiic.c:364:\tfor (sr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-365-\t\t!(sr \u0026 XIIC_SR_RX_FIFO_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c:366:\t\tsr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET)) {\ndrivers/i2c/busses/i2c-xiic.c:367:\t\txiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-368-\t\tif (time_after(jiffies, timeout)) {\n--\ndrivers/i2c/busses/i2c-xiic.c-376-\ndrivers/i2c/busses/i2c-xiic.c:377:static int xiic_wait_tx_empty(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-378-{\n--\ndrivers/i2c/busses/i2c-xiic.c-382-\ttimeout = jiffies + XIIC_I2C_TIMEOUT;\ndrivers/i2c/busses/i2c-xiic.c:383:\tfor (isr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-384-\t\t!(isr \u0026 XIIC_INTR_TX_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c:385:\t\t\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET)) {\ndrivers/i2c/busses/i2c-xiic.c-386-\t\tif (time_after(jiffies, timeout)) {\n--\ndrivers/i2c/busses/i2c-xiic.c-395-/**\ndrivers/i2c/busses/i2c-xiic.c:396: * xiic_setclk - Sets the configured clock rate\ndrivers/i2c/busses/i2c-xiic.c:397: * @i2c: Pointer to the xiic device structure\ndrivers/i2c/busses/i2c-xiic.c-398- *\n--\ndrivers/i2c/busses/i2c-xiic.c-406- */\ndrivers/i2c/busses/i2c-xiic.c:407:static int xiic_setclk(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-408-{\n--\ndrivers/i2c/busses/i2c-xiic.c-450-\ndrivers/i2c/busses/i2c-xiic.c:451:\txiic_setreg32(i2c, XIIC_THIGH_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-452-\ndrivers/i2c/busses/i2c-xiic.c-453-\t/* TLOW - Value same as THIGH */\ndrivers/i2c/busses/i2c-xiic.c:454:\txiic_setreg32(i2c, XIIC_TLOW_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-455-\n--\ndrivers/i2c/busses/i2c-xiic.c-457-\treg_val = (timing_reg_values[index].tsusta * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:458:\txiic_setreg32(i2c, XIIC_TSUSTA_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-459-\n--\ndrivers/i2c/busses/i2c-xiic.c-461-\treg_val = (timing_reg_values[index].tsusto * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:462:\txiic_setreg32(i2c, XIIC_TSUSTO_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-463-\n--\ndrivers/i2c/busses/i2c-xiic.c-465-\treg_val = (timing_reg_values[index].thdsta * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:466:\txiic_setreg32(i2c, XIIC_THDSTA_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-467-\n--\ndrivers/i2c/busses/i2c-xiic.c-469-\treg_val = (timing_reg_values[index].tsudat * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:470:\txiic_setreg32(i2c, XIIC_TSUDAT_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-471-\n--\ndrivers/i2c/busses/i2c-xiic.c-473-\treg_val = (timing_reg_values[index].tbuf * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:474:\txiic_setreg32(i2c, XIIC_TBUF_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-475-\ndrivers/i2c/busses/i2c-xiic.c-476-\t/* THDDAT */\ndrivers/i2c/busses/i2c-xiic.c:477:\txiic_setreg32(i2c, XIIC_THDDAT_REG_OFFSET, 1);\ndrivers/i2c/busses/i2c-xiic.c-478-\n--\ndrivers/i2c/busses/i2c-xiic.c-481-\ndrivers/i2c/busses/i2c-xiic.c:482:static int xiic_reinit(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-483-{\n--\ndrivers/i2c/busses/i2c-xiic.c-485-\ndrivers/i2c/busses/i2c-xiic.c:486:\txiic_setreg32(i2c, XIIC_RESETR_OFFSET, XIIC_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-487-\ndrivers/i2c/busses/i2c-xiic.c:488:\tret = xiic_setclk(i2c);\ndrivers/i2c/busses/i2c-xiic.c-489-\tif (ret)\n--\ndrivers/i2c/busses/i2c-xiic.c-492-\t/* Set receive Fifo depth to maximum (zero based). */\ndrivers/i2c/busses/i2c-xiic.c:493:\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, IIC_RX_FIFO_DEPTH - 1);\ndrivers/i2c/busses/i2c-xiic.c-494-\ndrivers/i2c/busses/i2c-xiic.c-495-\t/* Reset Tx Fifo. */\ndrivers/i2c/busses/i2c-xiic.c:496:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, XIIC_CR_TX_FIFO_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-497-\ndrivers/i2c/busses/i2c-xiic.c-498-\t/* Enable IIC Device, remove Tx Fifo reset \u0026 disable general call. */\ndrivers/i2c/busses/i2c-xiic.c:499:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, XIIC_CR_ENABLE_DEVICE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-500-\ndrivers/i2c/busses/i2c-xiic.c-501-\t/* make sure RX fifo is empty */\ndrivers/i2c/busses/i2c-xiic.c:502:\tret = xiic_clear_rx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-503-\tif (ret)\n--\ndrivers/i2c/busses/i2c-xiic.c-507-\tif (!i2c-\u003eatomic)\ndrivers/i2c/busses/i2c-xiic.c:508:\t\txiic_setreg32(i2c, XIIC_DGIER_OFFSET, XIIC_GINTR_ENABLE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-509-\ndrivers/i2c/busses/i2c-xiic.c:510:\txiic_irq_clr_en(i2c, XIIC_INTR_ARB_LOST_MASK);\ndrivers/i2c/busses/i2c-xiic.c-511-\n--\ndrivers/i2c/busses/i2c-xiic.c-514-\ndrivers/i2c/busses/i2c-xiic.c:515:static void xiic_deinit(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-516-{\n--\ndrivers/i2c/busses/i2c-xiic.c-518-\ndrivers/i2c/busses/i2c-xiic.c:519:\txiic_setreg32(i2c, XIIC_RESETR_OFFSET, XIIC_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-520-\ndrivers/i2c/busses/i2c-xiic.c-521-\t/* Disable IIC Device. */\ndrivers/i2c/busses/i2c-xiic.c:522:\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:523:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026 ~XIIC_CR_ENABLE_DEVICE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-524-}\ndrivers/i2c/busses/i2c-xiic.c-525-\ndrivers/i2c/busses/i2c-xiic.c:526:static void xiic_smbus_block_read_setup(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-527-{\n--\ndrivers/i2c/busses/i2c-xiic.c-539-\t/* Read byte from rx fifo and set message length */\ndrivers/i2c/busses/i2c-xiic.c:540:\trxmsg_len = xiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-541-\n--\ndrivers/i2c/busses/i2c-xiic.c-573-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:574:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);\ndrivers/i2c/busses/i2c-xiic.c-575-\n--\ndrivers/i2c/busses/i2c-xiic.c-584-\ndrivers/i2c/busses/i2c-xiic.c:585:static void xiic_read_rx(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-586-{\n--\ndrivers/i2c/busses/i2c-xiic.c-590-\ndrivers/i2c/busses/i2c-xiic.c:591:\tbytes_in_fifo = xiic_getreg8(i2c, XIIC_RFO_REG_OFFSET) + 1;\ndrivers/i2c/busses/i2c-xiic.c-592-\n--\ndrivers/i2c/busses/i2c-xiic.c-595-\t\t\t\"%s entry, bytes in fifo: %d, rem: %d, SR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:596:\t\t\t__func__, bytes_in_fifo, xiic_rx_space(i2c),\ndrivers/i2c/busses/i2c-xiic.c:597:\t\t\txiic_getreg8(i2c, XIIC_SR_REG_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:598:\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-599-\ndrivers/i2c/busses/i2c-xiic.c:600:\tif (bytes_in_fifo \u003e xiic_rx_space(i2c))\ndrivers/i2c/busses/i2c-xiic.c:601:\t\tbytes_in_fifo = xiic_rx_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c-602-\n--\ndrivers/i2c/busses/i2c-xiic.c-605-\tif (!i2c-\u003edynamic) {\ndrivers/i2c/busses/i2c-xiic.c:606:\t\tbytes_rem = xiic_rx_space(i2c) - bytes_in_fifo;\ndrivers/i2c/busses/i2c-xiic.c-607-\n--\ndrivers/i2c/busses/i2c-xiic.c-609-\t\tif (i2c-\u003erx_msg-\u003eflags \u0026 I2C_M_RECV_LEN) {\ndrivers/i2c/busses/i2c-xiic.c:610:\t\t\txiic_smbus_block_read_setup(i2c);\ndrivers/i2c/busses/i2c-xiic.c-611-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-620-\t\t\t/* Set NACK in CR to indicate slave transmitter */\ndrivers/i2c/busses/i2c-xiic.c:621:\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:622:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr |\ndrivers/i2c/busses/i2c-xiic.c-623-\t\t\t\t\tXIIC_CR_NO_ACK_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-628-\t\t\tif (i2c-\u003enmsgs == 1) {\ndrivers/i2c/busses/i2c-xiic.c:629:\t\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:630:\t\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-631-\t\t\t\t\t\t~XIIC_CR_MSMS_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-634-\t\t\t/* Make TXACK=0, clean up for next transaction */\ndrivers/i2c/busses/i2c-xiic.c:635:\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:636:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-637-\t\t\t\t\t~XIIC_CR_NO_ACK_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-643-\t\ti2c-\u003erx_msg-\u003ebuf[i2c-\u003erx_pos++] =\ndrivers/i2c/busses/i2c-xiic.c:644:\t\t\txiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-645-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-650-\t\t/* Receive remaining bytes if less than fifo depth */\ndrivers/i2c/busses/i2c-xiic.c:651:\t\tbytes = min_t(u8, xiic_rx_space(i2c), IIC_RX_FIFO_DEPTH);\ndrivers/i2c/busses/i2c-xiic.c-652-\t\tbytes--;\ndrivers/i2c/busses/i2c-xiic.c:653:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, bytes);\ndrivers/i2c/busses/i2c-xiic.c-654-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-656-\ndrivers/i2c/busses/i2c-xiic.c:657:static bool xiic_error_check(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-658-{\n--\ndrivers/i2c/busses/i2c-xiic.c-661-\ndrivers/i2c/busses/i2c-xiic.c:662:\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:663:\tier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-664-\tpend = isr \u0026 ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-668-\t    !(pend \u0026 XIIC_INTR_RX_FULL_MASK))) {\ndrivers/i2c/busses/i2c-xiic.c:669:\t\txiic_reinit(i2c);\ndrivers/i2c/busses/i2c-xiic.c-670-\t\tstatus = true;\n--\ndrivers/i2c/busses/i2c-xiic.c-676-\ndrivers/i2c/busses/i2c-xiic.c:677:static int xiic_tx_fifo_space(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-678-{\ndrivers/i2c/busses/i2c-xiic.c-679-\t/* return the actual space left in the FIFO */\ndrivers/i2c/busses/i2c-xiic.c:680:\treturn IIC_TX_FIFO_DEPTH - xiic_getreg8(i2c, XIIC_TFO_REG_OFFSET) - 1;\ndrivers/i2c/busses/i2c-xiic.c-681-}\ndrivers/i2c/busses/i2c-xiic.c-682-\ndrivers/i2c/busses/i2c-xiic.c:683:static void xiic_fill_tx_fifo(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-684-{\ndrivers/i2c/busses/i2c-xiic.c:685:\tu8 fifo_space = xiic_tx_fifo_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c:686:\tint len = xiic_tx_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c-687-\n--\ndrivers/i2c/busses/i2c-xiic.c-696-\ndrivers/i2c/busses/i2c-xiic.c:697:\t\tif (!xiic_tx_space(i2c) \u0026\u0026 i2c-\u003enmsgs == 1) {\ndrivers/i2c/busses/i2c-xiic.c-698-\t\t\t/* last message in transfer -\u003e STOP */\n--\ndrivers/i2c/busses/i2c-xiic.c-705-\t\t\t\t/* Wait till FIFO is empty so STOP is sent last */\ndrivers/i2c/busses/i2c-xiic.c:706:\t\t\t\tstatus = xiic_wait_tx_empty(i2c);\ndrivers/i2c/busses/i2c-xiic.c-707-\t\t\t\tif (status)\n--\ndrivers/i2c/busses/i2c-xiic.c-710-\t\t\t\t/* Write to CR to stop */\ndrivers/i2c/busses/i2c-xiic.c:711:\t\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:712:\t\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-713-\t\t\t\t\t     ~XIIC_CR_MSMS_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-717-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:718:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET, data);\ndrivers/i2c/busses/i2c-xiic.c-719-\ndrivers/i2c/busses/i2c-xiic.c:720:\t\tif (i2c-\u003eatomic \u0026\u0026 xiic_error_check(i2c))\ndrivers/i2c/busses/i2c-xiic.c-721-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-724-\ndrivers/i2c/busses/i2c-xiic.c:725:static void xiic_wakeup(struct xiic_i2c *i2c, enum xilinx_i2c_state code)\ndrivers/i2c/busses/i2c-xiic.c-726-{\n--\ndrivers/i2c/busses/i2c-xiic.c-733-\ndrivers/i2c/busses/i2c-xiic.c:734:static irqreturn_t xiic_process(int irq, void *dev_id)\ndrivers/i2c/busses/i2c-xiic.c-735-{\ndrivers/i2c/busses/i2c-xiic.c:736:\tstruct xiic_i2c *i2c = dev_id;\ndrivers/i2c/busses/i2c-xiic.c-737-\tu32 pend, isr, ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-749-\tmutex_lock(\u0026i2c-\u003elock);\ndrivers/i2c/busses/i2c-xiic.c:750:\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:751:\tier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-752-\tpend = isr \u0026 ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-756-\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s: SR: 0x%x, msg: %p, nmsgs: %d\\n\",\ndrivers/i2c/busses/i2c-xiic.c:757:\t\t__func__, xiic_getreg8(i2c, XIIC_SR_REG_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c-758-\t\ti2c-\u003etx_msg, i2c-\u003enmsgs);\ndrivers/i2c/busses/i2c-xiic.c-759-\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:760:\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:761:\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-762-\n--\ndrivers/i2c/busses/i2c-xiic.c-778-\t\t */\ndrivers/i2c/busses/i2c-xiic.c:779:\t\tret = xiic_reinit(i2c);\ndrivers/i2c/busses/i2c-xiic.c-780-\t\tif (ret \u003c 0)\n--\ndrivers/i2c/busses/i2c-xiic.c-800-\t\t\t\t\"%s unexpected RX IRQ\\n\", __func__);\ndrivers/i2c/busses/i2c-xiic.c:801:\t\t\txiic_clear_rx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-802-\t\t\tgoto out;\n--\ndrivers/i2c/busses/i2c-xiic.c-804-\ndrivers/i2c/busses/i2c-xiic.c:805:\t\txiic_read_rx(i2c);\ndrivers/i2c/busses/i2c-xiic.c:806:\t\tif (xiic_rx_space(i2c) == 0) {\ndrivers/i2c/busses/i2c-xiic.c-807-\t\t\t/*\n--\ndrivers/i2c/busses/i2c-xiic.c-848-\ndrivers/i2c/busses/i2c-xiic.c:849:\t\tif (xiic_tx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:850:\t\t\txiic_fill_tx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-851-\t\t} else {\n--\ndrivers/i2c/busses/i2c-xiic.c-863-\t\t\t} else {\ndrivers/i2c/busses/i2c-xiic.c:864:\t\t\t\txiic_irq_dis(i2c, XIIC_INTR_TX_HALF_MASK);\ndrivers/i2c/busses/i2c-xiic.c-865-\n--\ndrivers/i2c/busses/i2c-xiic.c-877-\t\t/* The bus is not busy, disable BusNotBusy interrupt */\ndrivers/i2c/busses/i2c-xiic.c:878:\t\txiic_irq_dis(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-879-\n--\ndrivers/i2c/busses/i2c-xiic.c-882-\t\t\t/*\ndrivers/i2c/busses/i2c-xiic.c:883:\t\t\t * Drive xiic_tx_space() to 0 to signal STATE_DONE\ndrivers/i2c/busses/i2c-xiic.c-884-\t\t\t * without truncating the rx_msg length.\n--\ndrivers/i2c/busses/i2c-xiic.c-894-\t\tif (i2c-\u003enmsgs == 1 \u0026\u0026 !i2c-\u003erx_msg \u0026\u0026\ndrivers/i2c/busses/i2c-xiic.c:895:\t\t    xiic_tx_space(i2c) == 0)\ndrivers/i2c/busses/i2c-xiic.c-896-\t\t\twakeup_code = STATE_DONE;\n--\ndrivers/i2c/busses/i2c-xiic.c-903-\ndrivers/i2c/busses/i2c-xiic.c:904:\txiic_setreg32(i2c, XIIC_IISR_OFFSET, clr);\ndrivers/i2c/busses/i2c-xiic.c-905-\tif (xfer_more)\ndrivers/i2c/busses/i2c-xiic.c:906:\t\t__xiic_start_xfer(i2c);\ndrivers/i2c/busses/i2c-xiic.c-907-\tif (wakeup_req)\ndrivers/i2c/busses/i2c-xiic.c:908:\t\txiic_wakeup(i2c, wakeup_code);\ndrivers/i2c/busses/i2c-xiic.c-909-\n--\ndrivers/i2c/busses/i2c-xiic.c-915-\ndrivers/i2c/busses/i2c-xiic.c:916:static int xiic_bus_busy(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-917-{\ndrivers/i2c/busses/i2c-xiic.c:918:\tu8 sr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-919-\n--\ndrivers/i2c/busses/i2c-xiic.c-922-\ndrivers/i2c/busses/i2c-xiic.c:923:static int xiic_wait_not_busy(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-924-{\n--\ndrivers/i2c/busses/i2c-xiic.c-931-\t */\ndrivers/i2c/busses/i2c-xiic.c:932:\terr = xiic_bus_busy(i2c);\ndrivers/i2c/busses/i2c-xiic.c-933-\twhile (err \u0026\u0026 tries--) {\n--\ndrivers/i2c/busses/i2c-xiic.c-937-\t\t\tusleep_range(1000, 1100);\ndrivers/i2c/busses/i2c-xiic.c:938:\t\terr = xiic_bus_busy(i2c);\ndrivers/i2c/busses/i2c-xiic.c-939-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-943-\ndrivers/i2c/busses/i2c-xiic.c:944:static void xiic_recv_atomic(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-945-{\ndrivers/i2c/busses/i2c-xiic.c:946:\twhile (xiic_rx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:947:\t\tif (xiic_getreg32(i2c, XIIC_IISR_OFFSET) \u0026 XIIC_INTR_RX_FULL_MASK) {\ndrivers/i2c/busses/i2c-xiic.c:948:\t\t\txiic_read_rx(i2c);\ndrivers/i2c/busses/i2c-xiic.c-949-\ndrivers/i2c/busses/i2c-xiic.c-950-\t\t\t/* Clear Rx full and Tx error interrupts. */\ndrivers/i2c/busses/i2c-xiic.c:951:\t\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-952-\t\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\ndrivers/i2c/busses/i2c-xiic.c-953-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:954:\t\tif (xiic_error_check(i2c))\ndrivers/i2c/busses/i2c-xiic.c-955-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-958-\ti2c-\u003erx_msg = NULL;\ndrivers/i2c/busses/i2c-xiic.c:959:\txiic_irq_clr_en(i2c, XIIC_INTR_TX_ERROR_MASK);\ndrivers/i2c/busses/i2c-xiic.c-960-\n--\ndrivers/i2c/busses/i2c-xiic.c-964-\t\ti2c-\u003etx_msg++;\ndrivers/i2c/busses/i2c-xiic.c:965:\t\t__xiic_start_xfer(i2c);\ndrivers/i2c/busses/i2c-xiic.c-966-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-968-\ndrivers/i2c/busses/i2c-xiic.c:969:static void xiic_start_recv(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-970-{\n--\ndrivers/i2c/busses/i2c-xiic.c-979-\t\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s entry, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:980:\t\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:981:\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-982-\ndrivers/i2c/busses/i2c-xiic.c-983-\t/* Disable Tx interrupts */\ndrivers/i2c/busses/i2c-xiic.c:984:\txiic_irq_dis(i2c, XIIC_INTR_TX_HALF_MASK | XIIC_INTR_TX_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c-985-\n--\ndrivers/i2c/busses/i2c-xiic.c-990-\t\t/* Clear and enable Rx full interrupt. */\ndrivers/i2c/busses/i2c-xiic.c:991:\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-992-\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-1006-\t\t\tbytes--;\ndrivers/i2c/busses/i2c-xiic.c:1007:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, bytes);\ndrivers/i2c/busses/i2c-xiic.c-1008-\ndrivers/i2c/busses/i2c-xiic.c-1009-\t\t/* write the address */\ndrivers/i2c/busses/i2c-xiic.c:1010:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET,\ndrivers/i2c/busses/i2c-xiic.c-1011-\t\t\t      i2c_8bit_addr_from_msg(msg) |\n--\ndrivers/i2c/busses/i2c-xiic.c-1017-\ndrivers/i2c/busses/i2c-xiic.c:1018:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET, val);\ndrivers/i2c/busses/i2c-xiic.c-1019-\ndrivers/i2c/busses/i2c-xiic.c:1020:\t\txiic_irq_clr_en(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1021-\t} else {\n--\ndrivers/i2c/busses/i2c-xiic.c-1030-\ndrivers/i2c/busses/i2c-xiic.c:1031:\t\t\tstatus = xiic_wait_tx_empty(i2c);\ndrivers/i2c/busses/i2c-xiic.c-1032-\t\t\tif (status)\n--\ndrivers/i2c/busses/i2c-xiic.c-1035-\ndrivers/i2c/busses/i2c-xiic.c:1036:\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-1037-\n--\ndrivers/i2c/busses/i2c-xiic.c-1057-\t\t\t/* Already a master, RSTA should be set */\ndrivers/i2c/busses/i2c-xiic.c:1058:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, (cr |\ndrivers/i2c/busses/i2c-xiic.c-1059-\t\t\t\t\tXIIC_CR_REPEATED_START_MASK) \u0026\n--\ndrivers/i2c/busses/i2c-xiic.c-1062-\ndrivers/i2c/busses/i2c-xiic.c:1063:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);\ndrivers/i2c/busses/i2c-xiic.c-1064-\ndrivers/i2c/busses/i2c-xiic.c-1065-\t\t/* Clear and enable Rx full and transmit complete interrupts */\ndrivers/i2c/busses/i2c-xiic.c:1066:\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-1067-\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-1069-\t\t/* Write the address */\ndrivers/i2c/busses/i2c-xiic.c:1070:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET,\ndrivers/i2c/busses/i2c-xiic.c-1071-\t\t\t      i2c_8bit_addr_from_msg(msg));\n--\ndrivers/i2c/busses/i2c-xiic.c-1074-\t\tif ((cr \u0026 XIIC_CR_MSMS_MASK) == 0) {\ndrivers/i2c/busses/i2c-xiic.c:1075:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, (cr |\ndrivers/i2c/busses/i2c-xiic.c-1076-\t\t\t\t\tXIIC_CR_MSMS_MASK)\n--\ndrivers/i2c/busses/i2c-xiic.c-1080-\t\t\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s end, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:1081:\t\t\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:1082:\t\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-1083-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-1086-\t\t/* very last, enable bus not busy as well */\ndrivers/i2c/busses/i2c-xiic.c:1087:\t\txiic_irq_clr_en(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1088-\n--\ndrivers/i2c/busses/i2c-xiic.c-1095-\tif (!i2c-\u003eatomic)\ndrivers/i2c/busses/i2c-xiic.c:1096:\t\txiic_setreg32(i2c, XIIC_DGIER_OFFSET, XIIC_GINTR_ENABLE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1097-\telse\ndrivers/i2c/busses/i2c-xiic.c:1098:\t\txiic_recv_atomic(i2c);\ndrivers/i2c/busses/i2c-xiic.c-1099-}\ndrivers/i2c/busses/i2c-xiic.c-1100-\ndrivers/i2c/busses/i2c-xiic.c:1101:static void xiic_send_rem_atomic(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-1102-{\ndrivers/i2c/busses/i2c-xiic.c:1103:\twhile (xiic_tx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:1104:\t\tif (xiic_tx_fifo_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c-1105-\t\t\tu16 data;\n--\n\n"
}

31/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 34117
							output: 27
							thoughts: 874
						

Thoughts:
**Reaching a Conclusion on `i2c-xiic.c` Fuzzability**

Okay, let's break this down. My initial assessment is: I need to determine if the modified code in `drivers/i2c/busses/i2c-xiic.c` is fuzzable, specifically whether it's *reachable*. The driver in question, `i2c-xiic.c`, is a platform driver for Xilinx I2C controllers. It's meant to work with hardware, specifically Xilinx IP cores used in embedded systems or on certain PCI cards (`mgb4`, `timberdale`, `ptp_ocp`).

Given the target architecture is amd64, the Device Tree configurations for Xilinx SoCs are irrelevant. The specific PCI cards listed are also physical, vendor-specific hardware that *aren't* emulated in standard environments like QEMU or Google Compute Engine. That immediately raises a red flag. In standard virtualization, this driver, without specific hardware, *cannot* be instantiated or probed from userspace. The code is structurally unreachable under these conditions.

Reviewing the "negative criteria" for when to return `WorthFuzzing=false`, it clearly mentions "structurally unreachable hardware" like vendor-specific PCIe cards, which seems like a perfect match for the identified PCI cards. And unreachable execution paths. And as the Core Triage Philosophy states, reachability is the primary gate. If the code cannot run in standard environments, fuzzing is a no-go.

I also considered if `i2c-xiic` could be used with other, more common or virtualized peripherals, like USB or virtio devices. But no, it's not a USB device, not a virtio device, and doesn't appear to be part of any other software-emulated device. I checked for any ACPI matches – none. Also checked other drivers, like `i2c-stub` and `i2c-dev`, but these are separate and distinct drivers. Lastly, I checked the kernel source for any test or mock frameworks for `i2c-xiic`, like kunit, which could provide a fuzzing entrypoint. No luck there either.

Therefore, my conclusion is that the modified code in `drivers/i2c/busses/i2c-xiic.c` *is* structurally unreachable in standard virtualized environments. According to the guidelines, the code should *not* be fuzzed, and I should return `WorthFuzzing=false`.



32/2 2026/09/23 17:50 tool grepper
0m Args:
{
  "Expression": "xiic",
  "PathPrefix": "drivers/i2c"
}

Results:
{
  "Output": "\nFull output is too long, showing 500 out of 732 lines.\nUse more precise expression if possible.\n\ndrivers/i2c/busses/Makefile=128=i2c-thunderx-y\t\t\t:= i2c-octeon-core.o i2c-thunderx-pcidrv.o\ndrivers/i2c/busses/Makefile:129:obj-$(CONFIG_I2C_XILINX)\t+= i2c-xiic.o\ndrivers/i2c/busses/Makefile-130-obj-$(CONFIG_I2C_XLP9XX)\t+= i2c-xlp9xx.o\n--\ndrivers/i2c/busses/i2c-xiic.c-2-/*\ndrivers/i2c/busses/i2c-xiic.c:3: * i2c-xiic.c\ndrivers/i2c/busses/i2c-xiic.c-4- * Copyright (c) 2002-2007 Xilinx Inc.\n--\ndrivers/i2c/busses/i2c-xiic.c-26-#include \u003clinux/completion.h\u003e\ndrivers/i2c/busses/i2c-xiic.c:27:#include \u003clinux/platform_data/i2c-xiic.h\u003e\ndrivers/i2c/busses/i2c-xiic.c-28-#include \u003clinux/io.h\u003e\n--\ndrivers/i2c/busses/i2c-xiic.c-34-\ndrivers/i2c/busses/i2c-xiic.c:35:#define DRIVER_NAME \"xiic-i2c\"\ndrivers/i2c/busses/i2c-xiic.c-36-#define DYNAMIC_MODE_READ_BROKEN_BIT\tBIT(0)\n--\ndrivers/i2c/busses/i2c-xiic.c=39=enum xilinx_i2c_state {\n--\ndrivers/i2c/busses/i2c-xiic.c-44-\ndrivers/i2c/busses/i2c-xiic.c:45:enum xiic_endian {\ndrivers/i2c/busses/i2c-xiic.c-46-\tLITTLE,\n--\ndrivers/i2c/busses/i2c-xiic.c=50=enum i2c_scl_freq {\n--\ndrivers/i2c/busses/i2c-xiic.c-56-/**\ndrivers/i2c/busses/i2c-xiic.c:57: * struct xiic_i2c - Internal representation of the XIIC I2C bus\ndrivers/i2c/busses/i2c-xiic.c-58- * @dev: Pointer to device structure\n--\ndrivers/i2c/busses/i2c-xiic.c-84- */\ndrivers/i2c/busses/i2c-xiic.c:85:struct xiic_i2c {\ndrivers/i2c/busses/i2c-xiic.c-86-\tstruct device *dev;\n--\ndrivers/i2c/busses/i2c-xiic.c-95-\tint rx_pos;\ndrivers/i2c/busses/i2c-xiic.c:96:\tenum xiic_endian endianness;\ndrivers/i2c/busses/i2c-xiic.c-97-\tstruct clk *clk;\n--\ndrivers/i2c/busses/i2c-xiic.c-111-\ndrivers/i2c/busses/i2c-xiic.c:112:struct xiic_version_data {\ndrivers/i2c/busses/i2c-xiic.c-113-\tu32 quirks;\n--\ndrivers/i2c/busses/i2c-xiic.c=133=static const struct timing_regs timing_reg_values[] = {\n--\ndrivers/i2c/busses/i2c-xiic.c-247-\ndrivers/i2c/busses/i2c-xiic.c:248:#define xiic_tx_space(i2c) ((i2c)-\u003etx_msg-\u003elen - (i2c)-\u003etx_pos)\ndrivers/i2c/busses/i2c-xiic.c:249:#define xiic_rx_space(i2c) ((i2c)-\u003erx_msg-\u003elen - (i2c)-\u003erx_pos)\ndrivers/i2c/busses/i2c-xiic.c-250-\ndrivers/i2c/busses/i2c-xiic.c:251:static int xiic_start_xfer(struct xiic_i2c *i2c, struct i2c_msg *msgs, int num);\ndrivers/i2c/busses/i2c-xiic.c:252:static void __xiic_start_xfer(struct xiic_i2c *i2c);\ndrivers/i2c/busses/i2c-xiic.c-253-\ndrivers/i2c/busses/i2c-xiic.c:254:static int xiic_i2c_runtime_suspend(struct device *dev)\ndrivers/i2c/busses/i2c-xiic.c-255-{\ndrivers/i2c/busses/i2c-xiic.c:256:\tstruct xiic_i2c *i2c = dev_get_drvdata(dev);\ndrivers/i2c/busses/i2c-xiic.c-257-\n--\ndrivers/i2c/busses/i2c-xiic.c-262-\ndrivers/i2c/busses/i2c-xiic.c:263:static int xiic_i2c_runtime_resume(struct device *dev)\ndrivers/i2c/busses/i2c-xiic.c-264-{\ndrivers/i2c/busses/i2c-xiic.c:265:\tstruct xiic_i2c *i2c = dev_get_drvdata(dev);\ndrivers/i2c/busses/i2c-xiic.c-266-\tint ret;\n--\ndrivers/i2c/busses/i2c-xiic.c-284-\ndrivers/i2c/busses/i2c-xiic.c:285:static inline void xiic_setreg8(struct xiic_i2c *i2c, int reg, u8 value)\ndrivers/i2c/busses/i2c-xiic.c-286-{\n--\ndrivers/i2c/busses/i2c-xiic.c-292-\ndrivers/i2c/busses/i2c-xiic.c:293:static inline u8 xiic_getreg8(struct xiic_i2c *i2c, int reg)\ndrivers/i2c/busses/i2c-xiic.c-294-{\n--\ndrivers/i2c/busses/i2c-xiic.c-303-\ndrivers/i2c/busses/i2c-xiic.c:304:static inline void xiic_setreg16(struct xiic_i2c *i2c, int reg, u16 value)\ndrivers/i2c/busses/i2c-xiic.c-305-{\n--\ndrivers/i2c/busses/i2c-xiic.c-311-\ndrivers/i2c/busses/i2c-xiic.c:312:static inline void xiic_setreg32(struct xiic_i2c *i2c, int reg, int value)\ndrivers/i2c/busses/i2c-xiic.c-313-{\n--\ndrivers/i2c/busses/i2c-xiic.c-319-\ndrivers/i2c/busses/i2c-xiic.c:320:static inline int xiic_getreg32(struct xiic_i2c *i2c, int reg)\ndrivers/i2c/busses/i2c-xiic.c-321-{\n--\ndrivers/i2c/busses/i2c-xiic.c-330-\ndrivers/i2c/busses/i2c-xiic.c:331:static inline void xiic_irq_dis(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-332-{\ndrivers/i2c/busses/i2c-xiic.c:333:\tu32 ier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-334-\ndrivers/i2c/busses/i2c-xiic.c:335:\txiic_setreg32(i2c, XIIC_IIER_OFFSET, ier \u0026 ~mask);\ndrivers/i2c/busses/i2c-xiic.c-336-}\ndrivers/i2c/busses/i2c-xiic.c-337-\ndrivers/i2c/busses/i2c-xiic.c:338:static inline void xiic_irq_en(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-339-{\ndrivers/i2c/busses/i2c-xiic.c:340:\tu32 ier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-341-\ndrivers/i2c/busses/i2c-xiic.c:342:\txiic_setreg32(i2c, XIIC_IIER_OFFSET, ier | mask);\ndrivers/i2c/busses/i2c-xiic.c-343-}\ndrivers/i2c/busses/i2c-xiic.c-344-\ndrivers/i2c/busses/i2c-xiic.c:345:static inline void xiic_irq_clr(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-346-{\ndrivers/i2c/busses/i2c-xiic.c:347:\tu32 isr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-348-\ndrivers/i2c/busses/i2c-xiic.c:349:\txiic_setreg32(i2c, XIIC_IISR_OFFSET, isr \u0026 mask);\ndrivers/i2c/busses/i2c-xiic.c-350-}\ndrivers/i2c/busses/i2c-xiic.c-351-\ndrivers/i2c/busses/i2c-xiic.c:352:static inline void xiic_irq_clr_en(struct xiic_i2c *i2c, u32 mask)\ndrivers/i2c/busses/i2c-xiic.c-353-{\ndrivers/i2c/busses/i2c-xiic.c:354:\txiic_irq_clr(i2c, mask);\ndrivers/i2c/busses/i2c-xiic.c:355:\txiic_irq_en(i2c, mask);\ndrivers/i2c/busses/i2c-xiic.c-356-}\ndrivers/i2c/busses/i2c-xiic.c-357-\ndrivers/i2c/busses/i2c-xiic.c:358:static int xiic_clear_rx_fifo(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-359-{\n--\ndrivers/i2c/busses/i2c-xiic.c-363-\ttimeout = jiffies + XIIC_I2C_TIMEOUT;\ndrivers/i2c/busses/i2c-xiic.c:364:\tfor (sr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-365-\t\t!(sr \u0026 XIIC_SR_RX_FIFO_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c:366:\t\tsr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET)) {\ndrivers/i2c/busses/i2c-xiic.c:367:\t\txiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-368-\t\tif (time_after(jiffies, timeout)) {\n--\ndrivers/i2c/busses/i2c-xiic.c-376-\ndrivers/i2c/busses/i2c-xiic.c:377:static int xiic_wait_tx_empty(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-378-{\n--\ndrivers/i2c/busses/i2c-xiic.c-382-\ttimeout = jiffies + XIIC_I2C_TIMEOUT;\ndrivers/i2c/busses/i2c-xiic.c:383:\tfor (isr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-384-\t\t!(isr \u0026 XIIC_INTR_TX_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c:385:\t\t\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET)) {\ndrivers/i2c/busses/i2c-xiic.c-386-\t\tif (time_after(jiffies, timeout)) {\n--\ndrivers/i2c/busses/i2c-xiic.c-395-/**\ndrivers/i2c/busses/i2c-xiic.c:396: * xiic_setclk - Sets the configured clock rate\ndrivers/i2c/busses/i2c-xiic.c:397: * @i2c: Pointer to the xiic device structure\ndrivers/i2c/busses/i2c-xiic.c-398- *\n--\ndrivers/i2c/busses/i2c-xiic.c-406- */\ndrivers/i2c/busses/i2c-xiic.c:407:static int xiic_setclk(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-408-{\n--\ndrivers/i2c/busses/i2c-xiic.c-450-\ndrivers/i2c/busses/i2c-xiic.c:451:\txiic_setreg32(i2c, XIIC_THIGH_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-452-\ndrivers/i2c/busses/i2c-xiic.c-453-\t/* TLOW - Value same as THIGH */\ndrivers/i2c/busses/i2c-xiic.c:454:\txiic_setreg32(i2c, XIIC_TLOW_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-455-\n--\ndrivers/i2c/busses/i2c-xiic.c-457-\treg_val = (timing_reg_values[index].tsusta * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:458:\txiic_setreg32(i2c, XIIC_TSUSTA_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-459-\n--\ndrivers/i2c/busses/i2c-xiic.c-461-\treg_val = (timing_reg_values[index].tsusto * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:462:\txiic_setreg32(i2c, XIIC_TSUSTO_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-463-\n--\ndrivers/i2c/busses/i2c-xiic.c-465-\treg_val = (timing_reg_values[index].thdsta * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:466:\txiic_setreg32(i2c, XIIC_THDSTA_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-467-\n--\ndrivers/i2c/busses/i2c-xiic.c-469-\treg_val = (timing_reg_values[index].tsudat * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:470:\txiic_setreg32(i2c, XIIC_TSUDAT_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-471-\n--\ndrivers/i2c/busses/i2c-xiic.c-473-\treg_val = (timing_reg_values[index].tbuf * clk_in_mhz) / 1000;\ndrivers/i2c/busses/i2c-xiic.c:474:\txiic_setreg32(i2c, XIIC_TBUF_REG_OFFSET, reg_val - 1);\ndrivers/i2c/busses/i2c-xiic.c-475-\ndrivers/i2c/busses/i2c-xiic.c-476-\t/* THDDAT */\ndrivers/i2c/busses/i2c-xiic.c:477:\txiic_setreg32(i2c, XIIC_THDDAT_REG_OFFSET, 1);\ndrivers/i2c/busses/i2c-xiic.c-478-\n--\ndrivers/i2c/busses/i2c-xiic.c-481-\ndrivers/i2c/busses/i2c-xiic.c:482:static int xiic_reinit(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-483-{\n--\ndrivers/i2c/busses/i2c-xiic.c-485-\ndrivers/i2c/busses/i2c-xiic.c:486:\txiic_setreg32(i2c, XIIC_RESETR_OFFSET, XIIC_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-487-\ndrivers/i2c/busses/i2c-xiic.c:488:\tret = xiic_setclk(i2c);\ndrivers/i2c/busses/i2c-xiic.c-489-\tif (ret)\n--\ndrivers/i2c/busses/i2c-xiic.c-492-\t/* Set receive Fifo depth to maximum (zero based). */\ndrivers/i2c/busses/i2c-xiic.c:493:\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, IIC_RX_FIFO_DEPTH - 1);\ndrivers/i2c/busses/i2c-xiic.c-494-\ndrivers/i2c/busses/i2c-xiic.c-495-\t/* Reset Tx Fifo. */\ndrivers/i2c/busses/i2c-xiic.c:496:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, XIIC_CR_TX_FIFO_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-497-\ndrivers/i2c/busses/i2c-xiic.c-498-\t/* Enable IIC Device, remove Tx Fifo reset \u0026 disable general call. */\ndrivers/i2c/busses/i2c-xiic.c:499:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, XIIC_CR_ENABLE_DEVICE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-500-\ndrivers/i2c/busses/i2c-xiic.c-501-\t/* make sure RX fifo is empty */\ndrivers/i2c/busses/i2c-xiic.c:502:\tret = xiic_clear_rx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-503-\tif (ret)\n--\ndrivers/i2c/busses/i2c-xiic.c-507-\tif (!i2c-\u003eatomic)\ndrivers/i2c/busses/i2c-xiic.c:508:\t\txiic_setreg32(i2c, XIIC_DGIER_OFFSET, XIIC_GINTR_ENABLE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-509-\ndrivers/i2c/busses/i2c-xiic.c:510:\txiic_irq_clr_en(i2c, XIIC_INTR_ARB_LOST_MASK);\ndrivers/i2c/busses/i2c-xiic.c-511-\n--\ndrivers/i2c/busses/i2c-xiic.c-514-\ndrivers/i2c/busses/i2c-xiic.c:515:static void xiic_deinit(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-516-{\n--\ndrivers/i2c/busses/i2c-xiic.c-518-\ndrivers/i2c/busses/i2c-xiic.c:519:\txiic_setreg32(i2c, XIIC_RESETR_OFFSET, XIIC_RESET_MASK);\ndrivers/i2c/busses/i2c-xiic.c-520-\ndrivers/i2c/busses/i2c-xiic.c-521-\t/* Disable IIC Device. */\ndrivers/i2c/busses/i2c-xiic.c:522:\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:523:\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026 ~XIIC_CR_ENABLE_DEVICE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-524-}\ndrivers/i2c/busses/i2c-xiic.c-525-\ndrivers/i2c/busses/i2c-xiic.c:526:static void xiic_smbus_block_read_setup(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-527-{\n--\ndrivers/i2c/busses/i2c-xiic.c-539-\t/* Read byte from rx fifo and set message length */\ndrivers/i2c/busses/i2c-xiic.c:540:\trxmsg_len = xiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-541-\n--\ndrivers/i2c/busses/i2c-xiic.c-573-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:574:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);\ndrivers/i2c/busses/i2c-xiic.c-575-\n--\ndrivers/i2c/busses/i2c-xiic.c-584-\ndrivers/i2c/busses/i2c-xiic.c:585:static void xiic_read_rx(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-586-{\n--\ndrivers/i2c/busses/i2c-xiic.c-590-\ndrivers/i2c/busses/i2c-xiic.c:591:\tbytes_in_fifo = xiic_getreg8(i2c, XIIC_RFO_REG_OFFSET) + 1;\ndrivers/i2c/busses/i2c-xiic.c-592-\n--\ndrivers/i2c/busses/i2c-xiic.c-595-\t\t\t\"%s entry, bytes in fifo: %d, rem: %d, SR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:596:\t\t\t__func__, bytes_in_fifo, xiic_rx_space(i2c),\ndrivers/i2c/busses/i2c-xiic.c:597:\t\t\txiic_getreg8(i2c, XIIC_SR_REG_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:598:\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-599-\ndrivers/i2c/busses/i2c-xiic.c:600:\tif (bytes_in_fifo \u003e xiic_rx_space(i2c))\ndrivers/i2c/busses/i2c-xiic.c:601:\t\tbytes_in_fifo = xiic_rx_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c-602-\n--\ndrivers/i2c/busses/i2c-xiic.c-605-\tif (!i2c-\u003edynamic) {\ndrivers/i2c/busses/i2c-xiic.c:606:\t\tbytes_rem = xiic_rx_space(i2c) - bytes_in_fifo;\ndrivers/i2c/busses/i2c-xiic.c-607-\n--\ndrivers/i2c/busses/i2c-xiic.c-609-\t\tif (i2c-\u003erx_msg-\u003eflags \u0026 I2C_M_RECV_LEN) {\ndrivers/i2c/busses/i2c-xiic.c:610:\t\t\txiic_smbus_block_read_setup(i2c);\ndrivers/i2c/busses/i2c-xiic.c-611-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-620-\t\t\t/* Set NACK in CR to indicate slave transmitter */\ndrivers/i2c/busses/i2c-xiic.c:621:\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:622:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr |\ndrivers/i2c/busses/i2c-xiic.c-623-\t\t\t\t\tXIIC_CR_NO_ACK_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-628-\t\t\tif (i2c-\u003enmsgs == 1) {\ndrivers/i2c/busses/i2c-xiic.c:629:\t\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:630:\t\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-631-\t\t\t\t\t\t~XIIC_CR_MSMS_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-634-\t\t\t/* Make TXACK=0, clean up for next transaction */\ndrivers/i2c/busses/i2c-xiic.c:635:\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:636:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-637-\t\t\t\t\t~XIIC_CR_NO_ACK_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-643-\t\ti2c-\u003erx_msg-\u003ebuf[i2c-\u003erx_pos++] =\ndrivers/i2c/busses/i2c-xiic.c:644:\t\t\txiic_getreg8(i2c, XIIC_DRR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-645-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-650-\t\t/* Receive remaining bytes if less than fifo depth */\ndrivers/i2c/busses/i2c-xiic.c:651:\t\tbytes = min_t(u8, xiic_rx_space(i2c), IIC_RX_FIFO_DEPTH);\ndrivers/i2c/busses/i2c-xiic.c-652-\t\tbytes--;\ndrivers/i2c/busses/i2c-xiic.c:653:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, bytes);\ndrivers/i2c/busses/i2c-xiic.c-654-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-656-\ndrivers/i2c/busses/i2c-xiic.c:657:static bool xiic_error_check(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-658-{\n--\ndrivers/i2c/busses/i2c-xiic.c-661-\ndrivers/i2c/busses/i2c-xiic.c:662:\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:663:\tier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-664-\tpend = isr \u0026 ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-668-\t    !(pend \u0026 XIIC_INTR_RX_FULL_MASK))) {\ndrivers/i2c/busses/i2c-xiic.c:669:\t\txiic_reinit(i2c);\ndrivers/i2c/busses/i2c-xiic.c-670-\t\tstatus = true;\n--\ndrivers/i2c/busses/i2c-xiic.c-676-\ndrivers/i2c/busses/i2c-xiic.c:677:static int xiic_tx_fifo_space(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-678-{\ndrivers/i2c/busses/i2c-xiic.c-679-\t/* return the actual space left in the FIFO */\ndrivers/i2c/busses/i2c-xiic.c:680:\treturn IIC_TX_FIFO_DEPTH - xiic_getreg8(i2c, XIIC_TFO_REG_OFFSET) - 1;\ndrivers/i2c/busses/i2c-xiic.c-681-}\ndrivers/i2c/busses/i2c-xiic.c-682-\ndrivers/i2c/busses/i2c-xiic.c:683:static void xiic_fill_tx_fifo(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-684-{\ndrivers/i2c/busses/i2c-xiic.c:685:\tu8 fifo_space = xiic_tx_fifo_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c:686:\tint len = xiic_tx_space(i2c);\ndrivers/i2c/busses/i2c-xiic.c-687-\n--\ndrivers/i2c/busses/i2c-xiic.c-696-\ndrivers/i2c/busses/i2c-xiic.c:697:\t\tif (!xiic_tx_space(i2c) \u0026\u0026 i2c-\u003enmsgs == 1) {\ndrivers/i2c/busses/i2c-xiic.c-698-\t\t\t/* last message in transfer -\u003e STOP */\n--\ndrivers/i2c/busses/i2c-xiic.c-705-\t\t\t\t/* Wait till FIFO is empty so STOP is sent last */\ndrivers/i2c/busses/i2c-xiic.c:706:\t\t\t\tstatus = xiic_wait_tx_empty(i2c);\ndrivers/i2c/busses/i2c-xiic.c-707-\t\t\t\tif (status)\n--\ndrivers/i2c/busses/i2c-xiic.c-710-\t\t\t\t/* Write to CR to stop */\ndrivers/i2c/busses/i2c-xiic.c:711:\t\t\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:712:\t\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, cr \u0026\ndrivers/i2c/busses/i2c-xiic.c-713-\t\t\t\t\t     ~XIIC_CR_MSMS_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-717-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:718:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET, data);\ndrivers/i2c/busses/i2c-xiic.c-719-\ndrivers/i2c/busses/i2c-xiic.c:720:\t\tif (i2c-\u003eatomic \u0026\u0026 xiic_error_check(i2c))\ndrivers/i2c/busses/i2c-xiic.c-721-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-724-\ndrivers/i2c/busses/i2c-xiic.c:725:static void xiic_wakeup(struct xiic_i2c *i2c, enum xilinx_i2c_state code)\ndrivers/i2c/busses/i2c-xiic.c-726-{\n--\ndrivers/i2c/busses/i2c-xiic.c-733-\ndrivers/i2c/busses/i2c-xiic.c:734:static irqreturn_t xiic_process(int irq, void *dev_id)\ndrivers/i2c/busses/i2c-xiic.c-735-{\ndrivers/i2c/busses/i2c-xiic.c:736:\tstruct xiic_i2c *i2c = dev_id;\ndrivers/i2c/busses/i2c-xiic.c-737-\tu32 pend, isr, ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-749-\tmutex_lock(\u0026i2c-\u003elock);\ndrivers/i2c/busses/i2c-xiic.c:750:\tisr = xiic_getreg32(i2c, XIIC_IISR_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c:751:\tier = xiic_getreg32(i2c, XIIC_IIER_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-752-\tpend = isr \u0026 ier;\n--\ndrivers/i2c/busses/i2c-xiic.c-756-\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s: SR: 0x%x, msg: %p, nmsgs: %d\\n\",\ndrivers/i2c/busses/i2c-xiic.c:757:\t\t__func__, xiic_getreg8(i2c, XIIC_SR_REG_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c-758-\t\ti2c-\u003etx_msg, i2c-\u003enmsgs);\ndrivers/i2c/busses/i2c-xiic.c-759-\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:760:\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:761:\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-762-\n--\ndrivers/i2c/busses/i2c-xiic.c-778-\t\t */\ndrivers/i2c/busses/i2c-xiic.c:779:\t\tret = xiic_reinit(i2c);\ndrivers/i2c/busses/i2c-xiic.c-780-\t\tif (ret \u003c 0)\n--\ndrivers/i2c/busses/i2c-xiic.c-800-\t\t\t\t\"%s unexpected RX IRQ\\n\", __func__);\ndrivers/i2c/busses/i2c-xiic.c:801:\t\t\txiic_clear_rx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-802-\t\t\tgoto out;\n--\ndrivers/i2c/busses/i2c-xiic.c-804-\ndrivers/i2c/busses/i2c-xiic.c:805:\t\txiic_read_rx(i2c);\ndrivers/i2c/busses/i2c-xiic.c:806:\t\tif (xiic_rx_space(i2c) == 0) {\ndrivers/i2c/busses/i2c-xiic.c-807-\t\t\t/*\n--\ndrivers/i2c/busses/i2c-xiic.c-848-\ndrivers/i2c/busses/i2c-xiic.c:849:\t\tif (xiic_tx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:850:\t\t\txiic_fill_tx_fifo(i2c);\ndrivers/i2c/busses/i2c-xiic.c-851-\t\t} else {\n--\ndrivers/i2c/busses/i2c-xiic.c-863-\t\t\t} else {\ndrivers/i2c/busses/i2c-xiic.c:864:\t\t\t\txiic_irq_dis(i2c, XIIC_INTR_TX_HALF_MASK);\ndrivers/i2c/busses/i2c-xiic.c-865-\n--\ndrivers/i2c/busses/i2c-xiic.c-877-\t\t/* The bus is not busy, disable BusNotBusy interrupt */\ndrivers/i2c/busses/i2c-xiic.c:878:\t\txiic_irq_dis(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-879-\n--\ndrivers/i2c/busses/i2c-xiic.c-882-\t\t\t/*\ndrivers/i2c/busses/i2c-xiic.c:883:\t\t\t * Drive xiic_tx_space() to 0 to signal STATE_DONE\ndrivers/i2c/busses/i2c-xiic.c-884-\t\t\t * without truncating the rx_msg length.\n--\ndrivers/i2c/busses/i2c-xiic.c-894-\t\tif (i2c-\u003enmsgs == 1 \u0026\u0026 !i2c-\u003erx_msg \u0026\u0026\ndrivers/i2c/busses/i2c-xiic.c:895:\t\t    xiic_tx_space(i2c) == 0)\ndrivers/i2c/busses/i2c-xiic.c-896-\t\t\twakeup_code = STATE_DONE;\n--\ndrivers/i2c/busses/i2c-xiic.c-903-\ndrivers/i2c/busses/i2c-xiic.c:904:\txiic_setreg32(i2c, XIIC_IISR_OFFSET, clr);\ndrivers/i2c/busses/i2c-xiic.c-905-\tif (xfer_more)\ndrivers/i2c/busses/i2c-xiic.c:906:\t\t__xiic_start_xfer(i2c);\ndrivers/i2c/busses/i2c-xiic.c-907-\tif (wakeup_req)\ndrivers/i2c/busses/i2c-xiic.c:908:\t\txiic_wakeup(i2c, wakeup_code);\ndrivers/i2c/busses/i2c-xiic.c-909-\n--\ndrivers/i2c/busses/i2c-xiic.c-915-\ndrivers/i2c/busses/i2c-xiic.c:916:static int xiic_bus_busy(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-917-{\ndrivers/i2c/busses/i2c-xiic.c:918:\tu8 sr = xiic_getreg8(i2c, XIIC_SR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-919-\n--\ndrivers/i2c/busses/i2c-xiic.c-922-\ndrivers/i2c/busses/i2c-xiic.c:923:static int xiic_wait_not_busy(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-924-{\n--\ndrivers/i2c/busses/i2c-xiic.c-931-\t */\ndrivers/i2c/busses/i2c-xiic.c:932:\terr = xiic_bus_busy(i2c);\ndrivers/i2c/busses/i2c-xiic.c-933-\twhile (err \u0026\u0026 tries--) {\n--\ndrivers/i2c/busses/i2c-xiic.c-937-\t\t\tusleep_range(1000, 1100);\ndrivers/i2c/busses/i2c-xiic.c:938:\t\terr = xiic_bus_busy(i2c);\ndrivers/i2c/busses/i2c-xiic.c-939-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-943-\ndrivers/i2c/busses/i2c-xiic.c:944:static void xiic_recv_atomic(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-945-{\ndrivers/i2c/busses/i2c-xiic.c:946:\twhile (xiic_rx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:947:\t\tif (xiic_getreg32(i2c, XIIC_IISR_OFFSET) \u0026 XIIC_INTR_RX_FULL_MASK) {\ndrivers/i2c/busses/i2c-xiic.c:948:\t\t\txiic_read_rx(i2c);\ndrivers/i2c/busses/i2c-xiic.c-949-\ndrivers/i2c/busses/i2c-xiic.c-950-\t\t\t/* Clear Rx full and Tx error interrupts. */\ndrivers/i2c/busses/i2c-xiic.c:951:\t\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-952-\t\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\ndrivers/i2c/busses/i2c-xiic.c-953-\t\t}\ndrivers/i2c/busses/i2c-xiic.c:954:\t\tif (xiic_error_check(i2c))\ndrivers/i2c/busses/i2c-xiic.c-955-\t\t\treturn;\n--\ndrivers/i2c/busses/i2c-xiic.c-958-\ti2c-\u003erx_msg = NULL;\ndrivers/i2c/busses/i2c-xiic.c:959:\txiic_irq_clr_en(i2c, XIIC_INTR_TX_ERROR_MASK);\ndrivers/i2c/busses/i2c-xiic.c-960-\n--\ndrivers/i2c/busses/i2c-xiic.c-964-\t\ti2c-\u003etx_msg++;\ndrivers/i2c/busses/i2c-xiic.c:965:\t\t__xiic_start_xfer(i2c);\ndrivers/i2c/busses/i2c-xiic.c-966-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-968-\ndrivers/i2c/busses/i2c-xiic.c:969:static void xiic_start_recv(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-970-{\n--\ndrivers/i2c/busses/i2c-xiic.c-979-\t\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s entry, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:980:\t\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:981:\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-982-\ndrivers/i2c/busses/i2c-xiic.c-983-\t/* Disable Tx interrupts */\ndrivers/i2c/busses/i2c-xiic.c:984:\txiic_irq_dis(i2c, XIIC_INTR_TX_HALF_MASK | XIIC_INTR_TX_EMPTY_MASK);\ndrivers/i2c/busses/i2c-xiic.c-985-\n--\ndrivers/i2c/busses/i2c-xiic.c-990-\t\t/* Clear and enable Rx full interrupt. */\ndrivers/i2c/busses/i2c-xiic.c:991:\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-992-\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-1006-\t\t\tbytes--;\ndrivers/i2c/busses/i2c-xiic.c:1007:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, bytes);\ndrivers/i2c/busses/i2c-xiic.c-1008-\ndrivers/i2c/busses/i2c-xiic.c-1009-\t\t/* write the address */\ndrivers/i2c/busses/i2c-xiic.c:1010:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET,\ndrivers/i2c/busses/i2c-xiic.c-1011-\t\t\t      i2c_8bit_addr_from_msg(msg) |\n--\ndrivers/i2c/busses/i2c-xiic.c-1017-\ndrivers/i2c/busses/i2c-xiic.c:1018:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET, val);\ndrivers/i2c/busses/i2c-xiic.c-1019-\ndrivers/i2c/busses/i2c-xiic.c:1020:\t\txiic_irq_clr_en(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1021-\t} else {\n--\ndrivers/i2c/busses/i2c-xiic.c-1030-\ndrivers/i2c/busses/i2c-xiic.c:1031:\t\t\tstatus = xiic_wait_tx_empty(i2c);\ndrivers/i2c/busses/i2c-xiic.c-1032-\t\t\tif (status)\n--\ndrivers/i2c/busses/i2c-xiic.c-1035-\ndrivers/i2c/busses/i2c-xiic.c:1036:\t\tcr = xiic_getreg8(i2c, XIIC_CR_REG_OFFSET);\ndrivers/i2c/busses/i2c-xiic.c-1037-\n--\ndrivers/i2c/busses/i2c-xiic.c-1057-\t\t\t/* Already a master, RSTA should be set */\ndrivers/i2c/busses/i2c-xiic.c:1058:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, (cr |\ndrivers/i2c/busses/i2c-xiic.c-1059-\t\t\t\t\tXIIC_CR_REPEATED_START_MASK) \u0026\n--\ndrivers/i2c/busses/i2c-xiic.c-1062-\ndrivers/i2c/busses/i2c-xiic.c:1063:\t\txiic_setreg8(i2c, XIIC_RFD_REG_OFFSET, rfd_set);\ndrivers/i2c/busses/i2c-xiic.c-1064-\ndrivers/i2c/busses/i2c-xiic.c-1065-\t\t/* Clear and enable Rx full and transmit complete interrupts */\ndrivers/i2c/busses/i2c-xiic.c:1066:\t\txiic_irq_clr_en(i2c, XIIC_INTR_RX_FULL_MASK |\ndrivers/i2c/busses/i2c-xiic.c-1067-\t\t\t\tXIIC_INTR_TX_ERROR_MASK);\n--\ndrivers/i2c/busses/i2c-xiic.c-1069-\t\t/* Write the address */\ndrivers/i2c/busses/i2c-xiic.c:1070:\t\txiic_setreg16(i2c, XIIC_DTR_REG_OFFSET,\ndrivers/i2c/busses/i2c-xiic.c-1071-\t\t\t      i2c_8bit_addr_from_msg(msg));\n--\ndrivers/i2c/busses/i2c-xiic.c-1074-\t\tif ((cr \u0026 XIIC_CR_MSMS_MASK) == 0) {\ndrivers/i2c/busses/i2c-xiic.c:1075:\t\t\txiic_setreg8(i2c, XIIC_CR_REG_OFFSET, (cr |\ndrivers/i2c/busses/i2c-xiic.c-1076-\t\t\t\t\tXIIC_CR_MSMS_MASK)\n--\ndrivers/i2c/busses/i2c-xiic.c-1080-\t\t\tdev_dbg(i2c-\u003eadap.dev.parent, \"%s end, ISR: 0x%x, CR: 0x%x\\n\",\ndrivers/i2c/busses/i2c-xiic.c:1081:\t\t\t\t__func__, xiic_getreg32(i2c, XIIC_IISR_OFFSET),\ndrivers/i2c/busses/i2c-xiic.c:1082:\t\t\t\txiic_getreg8(i2c, XIIC_CR_REG_OFFSET));\ndrivers/i2c/busses/i2c-xiic.c-1083-\t}\n--\ndrivers/i2c/busses/i2c-xiic.c-1086-\t\t/* very last, enable bus not busy as well */\ndrivers/i2c/busses/i2c-xiic.c:1087:\t\txiic_irq_clr_en(i2c, XIIC_INTR_BNB_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1088-\n--\ndrivers/i2c/busses/i2c-xiic.c-1095-\tif (!i2c-\u003eatomic)\ndrivers/i2c/busses/i2c-xiic.c:1096:\t\txiic_setreg32(i2c, XIIC_DGIER_OFFSET, XIIC_GINTR_ENABLE_MASK);\ndrivers/i2c/busses/i2c-xiic.c-1097-\telse\ndrivers/i2c/busses/i2c-xiic.c:1098:\t\txiic_recv_atomic(i2c);\ndrivers/i2c/busses/i2c-xiic.c-1099-}\ndrivers/i2c/busses/i2c-xiic.c-1100-\ndrivers/i2c/busses/i2c-xiic.c:1101:static void xiic_send_rem_atomic(struct xiic_i2c *i2c)\ndrivers/i2c/busses/i2c-xiic.c-1102-{\ndrivers/i2c/busses/i2c-xiic.c:1103:\twhile (xiic_tx_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c:1104:\t\tif (xiic_tx_fifo_space(i2c)) {\ndrivers/i2c/busses/i2c-xiic.c-1105-\t\t\tu16 data;\n--\ndrivers/i2c/busses/i2c-xiic.c-1108-\t\t\ti2c-\u003etx_pos++;\ndrivers/i2c/busses/i2c-xiic.c:1109:\t\t\tif (!xiic_tx_space(i2c) \u0026\u0026 i2c-\u003enmsgs == 1) {\ndrivers/i2c/busses/i2c-xiic.c-1110-\t\t\t\t/* last message in transfer -\u003e STOP */\n--\n\n"
}

33/2 2026/09/23 17:50 llm patch-evaluator
0m Model:
gemini-3.8-flash

Args:
null

Results:
null

Tokens:
							input: 50242
							output: 145
							thoughts: 593
						

Thoughts:
**My Assessment: xiic Driver Unfuzzable on amd64 in Standard Environments**

Okay, let's break this down. First, I need to confirm if there are any existing test files or harnesses for `xiic`. Nope, nothing there. The core of this driver is the Xilinx I2C controller, specifically their FPGA IP cores. This is hardware-dependent.

The key here is that this is *not* a generic I2C driver. This driver is tied to Xilinx FPGA IP cores found on their FPGAs/SoCs, or devices like specialized PCIe cards. On `amd64`, the target architecture for this assessment, there's no emulated Xilinx I2C controller available in common virtualization environments like QEMU or GCE.

The cards that *do* use this driver on x86/amd64 are vendor-specific physical PCIe add-in cards— Digiteq MGB4, Timberdale FPGA, Meta TimeCard. None of those are emulated in QEMU. That's a major red flag.

Let's do a quick checklist to be thorough:

*   Target architecture? AMD64. Check.
*   Modified file? `drivers/i2c/busses/i2c-xiic.c`. Check.
*   Is it core or reachable? No, it's a very specific Xilinx IP core I2C bus master driver.
*   Can it be triggered from userspace via a virtual bus or software device (like USB, netdev, virtio)? Nope.
*   Can it be probed without physical hardware or a device tree on an architecture like amd64? No. It requires that specialized hardware.

The negative criteria are also in alignment with my assessment. This falls squarely into the category of "Structurally unreachable hardware" – like vendor-specific PCIe switches, and drivers that require physical ASICs/PCIe cards not emulated in standard QEMU. It also aligns with "Code paths exclusive to architectures other than the target architecture."

Therefore, based on my understanding, there's no way to reach this code in a standard, fuzzable environment. The `WorthFuzzing` flag should be set to `false`. I can populate `EnableConfigs` and `FocusSymbols` with empty arrays. The rationale is quite clear and documented: the code requires specific Xilinx FPGA IP cores and physical PCIe cards, which are not emulated in standard environments (QEMU/GCE) on amd64.

Finally, I just need to verify that my analysis fits the `set-results` schema. Looks good, it does. `WorthFuzzing` is a boolean, `FocusSymbols` and `EnableConfigs` are string arrays, and `Reasoning` is a string. All set. I can call `set-results` with this data.



34/2 2026/09/23 17:51 tool set-results
0m Args:
{
  "EnableConfigs": [],
  "FocusSymbols": [],
  "Reasoning": "The patch modifies drivers/i2c/busses/i2c-xiic.c, which implements an I2C bus driver for Xilinx FPGA IP cores (xps-iic, axi-iic) and specialized PCIe add-in cards (mgb4, timberdale, ptp_ocp). These devices require dedicated physical hardware (or embedded Device Tree configurations) not emulated in standard virtualized fuzzing environments (QEMU/GCE) on amd64. Therefore, the modified code is structurally unreachable.",
  "WorthFuzzing": false
}

Results:
{
  "EnableConfigs": null,
  "FocusSymbols": [],
  "Reasoning": "The patch modifies drivers/i2c/busses/i2c-xiic.c, which implements an I2C bus driver for Xilinx FPGA IP cores (xps-iic, axi-iic) and specialized PCIe add-in cards (mgb4, timberdale, ptp_ocp). These devices require dedicated physical hardware (or embedded Device Tree configurations) not emulated in standard virtualized fuzzing environments (QEMU/GCE) on amd64. Therefore, the modified code is structurally unreachable.",
  "WorthFuzzing": false
}

35/1 2026/09/23 17:51 action If
0m Args:
{
  "WorthFuzzing": false
}

Results:
null

LLM Calls Summary:
Total Calls Total Tokens Avg Tokens Total Duration (Seconds) Avg Duration (Seconds)
Tool Calls Summary:
Total Calls Total Duration (Seconds) Avg Duration (Seconds)