public inbox for drm-ai-reviews@public-inbox.freedesktop.org
 help / color / mirror / Atom feed
From: Claude Code Review Bot <claude-review@example.com>
To: dri-devel-reviews@example.com
Subject: Claude review: staging: fbtft: replace empty macro args with identity converter
Date: Mon, 13 Apr 2026 18:56:21 +1000	[thread overview]
Message-ID: <review-patch1-20260412172147.2817-2-mzndmzn@gmail.com> (raw)
In-Reply-To: <20260412172147.2817-2-mzndmzn@gmail.com>

Patch Review

**Commit message:**
> Remove trailing space and comma before closing parenthesis ')' in define_fbtft_write_reg macro as reported by checkpatch.pl.

**Critical bug — will not compile.** The macro `define_fbtft_write_reg` is defined with 4 parameters:

```c
#define define_fbtft_write_reg(func, buffer_type, data_type, modifier)
```

But the patch changes the invocations from 4 arguments (with an empty 4th) to 3:

```c
-define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8, )
+define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8)
```

Calling a fixed-arity 4-parameter macro with only 3 arguments is a hard error from the preprocessor. GCC will emit: `error: macro "define_fbtft_write_reg" requires 4 arguments, but only 3 given`.

The existing code with the empty 4th argument (`, )`) is actually well-defined in C99 and GNU C (which the kernel uses via `-std=gnu11`). An empty macro argument is a valid "placemarker" preprocessing token per C99 §6.10.3. When `modifier` is empty, `modifier((data_type)va_arg(args, unsigned int))` expands to `((data_type)va_arg(args, unsigned int))` — a correctly parenthesized identity operation. The checkpatch warning is cosmetic and the existing code is correct.

**Verdict:** NAK. This patch introduces a build failure.

---

---
Generated by Claude Code Patch Reviewer

  parent reply	other threads:[~2026-04-13  8:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-12 17:21 [PATCH] staging: fbtft: fix coding style issue in fbtft-bus.c Baker
2026-04-12 17:21 ` [PATCH] staging: fbtft: replace empty macro args with identity converter Baker
2026-04-13  8:56   ` Claude review: " Claude Code Review Bot
2026-04-13  8:56   ` Claude Code Review Bot [this message]
2026-04-13  8:56 ` Claude review: staging: fbtft: fix coding style issue in fbtft-bus.c Claude Code Review Bot

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=review-patch1-20260412172147.2817-2-mzndmzn@gmail.com \
    --to=claude-review@example.com \
    --cc=dri-devel-reviews@example.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox