[PATCH v2 0/7] char: xillybus: Harden driver and improve code quality
From: Eli Billauer
Date: Wed Jul 22 2026 - 06:30:13 EST
This patch set consists of several boundary and sanity checks, gaining
better control of execution flow and fixing minor coding issues. No
difference is expected in the driver's behavior under normal conditions,
except for one change that might improve bandwidth performance
marginally.
These patches are the result of a comprehensive AI-assisted code review,
using Deepseek, Kimi Thinking K2.6, ChatGPT, and Claude Sonnet 4.6 as
plain prompt tools.
The v1 iteration of this series was rejected due to an error in the
error path. Specifically, the @rc variable was not assigned a value
before a goto statement following a failed allocation. This oversight
was caught during compilation with LLVM=1, but was missed by GCC and the
AI tools used during the review (and myself of course).
All patches are unchanged since v1, except for "Add defensive sanity
checks", which fixes the said error and also makes a couple of minor
adjustments.
Eli Billauer (7):
char: xillybus: Improve control of execution flow with mutexes
char: xillybus: Remove duplicate error path code
char: xillybus: Avoid possible bandwidth inefficiency
char: xillybus: Use unsigned arithmetic for jiffies differences
char: xillybus: Integer arithmetic improvements
char: xillybus: Add defensive sanity checks
char: xillybus: Ignore and report unsolicited interrupts
drivers/char/xillybus/xillybus.h | 3 +
drivers/char/xillybus/xillybus_class.c | 18 ++++-
drivers/char/xillybus/xillybus_class.h | 4 +
drivers/char/xillybus/xillybus_core.c | 100 ++++++++++++++++++++++---
drivers/char/xillybus/xillybus_of.c | 3 +
drivers/char/xillybus/xillyusb.c | 62 +++++++++++----
6 files changed, 162 insertions(+), 28 deletions(-)
--
2.34.1