Re: [PATCH v5 24/37] rust: Add a rust helper for krealloc()

From: Miguel Ojeda
Date: Fri Mar 08 2024 - 10:24:00 EST


On Wed, Mar 6, 2024 at 7:26 PM Suren Baghdasaryan <surenb@xxxxxxxxxx> wrote:
>
> +void * __must_check rust_helper_krealloc(const void *objp, size_t new_size,
> + gfp_t flags) __realloc_size(2)

The `__realloc_size(2)` should be placed earlier, i.e. this triggers:

rust/helpers.c:162:20: error: GCC does not allow '__alloc_size__'
attribute in this position on a function definition [-Wgcc-compat]

With that fixed:

Acked-by: Miguel Ojeda <ojeda@xxxxxxxxxx>

Cheers,
Miguel