From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: dyndbg: Upgrade class param storage to u64 for 64-bit classmaps Date: Thu, 04 Jun 2026 14:06:59 +1000 Message-ID: In-Reply-To: <20260601-dd-maint-2-v3-18-4a15b241bd3c@gmail.com> References: <20260601-dd-maint-2-v3-0-4a15b241bd3c@gmail.com> <20260601-dd-maint-2-v3-18-4a15b241bd3c@gmail.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review Important fix for 32-bit architectures where `unsigned long` truncates 64-bit classmaps. The `CLASSMAP_BITMASK` macro: ```c #define CLASSMAP_BITMASK(width) ((width) == 64 ? ~0ULL : (1ULL << (width)) - 1) ``` correctly handles the width==64 case to avoid undefined behavior. The DRM changes (`__drm_debug` to `u64`, `struct ddebug_class_param` to `struct _ddebug_class_param`) are straightforward. Minor nit: the operator precedence in `CLASSMAP_BITMASK` -- `(1ULL << (width)) - 1` -- is technically correct since `<<` binds tighter than `-`, but adding parens around the subtraction `((1ULL << (width)) - 1)` would be clearer. --- Generated by Claude Code Patch Reviewer