Re: [PATCH v3 0/6] initramfs: test and improve cpio hex header validation
From: Andrew Morton
Date: Mon Mar 23 2026 - 18:09:13 EST
On Mon, 23 Mar 2026 15:54:16 +0100 Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:
> The series that introduced simple_strntoul() had passed into kernel
> without proper review and hence reinvented a wheel that's not needed.
> Here is the refactoring to show that. It can go via PRINTK or VFS
> tree.
>
> I have tested this on x86, but I believe the same result will be
> on big-endian CPUs (I deduced that from how strtox() works).
AI review asked a few questions:
https://sashiko.dev/#/patchset/20260323150054.3587083-1-andriy.shevchenko@xxxxxxxxxxxxxxx
The "Is it possible for kzalloc() to fail and return NULL here?" one
should be ignored - I've asked Roman&Chris to teach the reviewbot that
unchecked allocations in __init code are OK.