From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: arch: use rest_of_page() macro where appropriate Date: Thu, 05 Mar 2026 13:59:12 +1000 Message-ID: In-Reply-To: <20260304012717.201797-9-ynorov@nvidia.com> References: <20260304012717.201797-1-ynorov@nvidia.com> <20260304012717.201797-9-ynorov@nvidia.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Patch Review - `arch/arm64/kernel/patching.c`: Correct replacement. **Minor nit:** a bla= nk line between the `size =3D ...` assignment and `waddr =3D patch_map(...)= ` was removed. This is an unrelated whitespace change. ```c - size =3D min_t(size_t, PAGE_SIZE - offset_in_page(ptr), - len - patched); - + size =3D min_t(size_t, rest_of_page(ptr), len - patched); waddr =3D patch_map(ptr, FIX_TEXT_POKE0); ``` The original had a visual separator; removing it is a style change that s= hould be separate or at least mentioned. - `arch/powerpc/lib/code-patching.c`: Two comment updates and one code chan= ge. The comment updates replacing `(PAGE_SIZE - offset_in_page(addr))` with= `rest_of_page(addr)` in the function documentation are a nice touch. Code = change is correct. - `arch/riscv/kernel/sbi.c`: Two replacements in `sbi_debug_console_write()= ` and `sbi_debug_console_read()`. Correct =E2=80=94 the guard condition `PA= GE_SIZE < (offset_in_page(bytes) + num_bytes)` ensures we only reach the as= signment when `rest_of_page(bytes) < num_bytes`. --- Generated by Claude Code Patch Reviewer