From: Pavel Begunkov Date: Sun, 20 Apr 2025 09:31:15 +0000 (+0100) Subject: io_uring/zcrx: remove duplicated freelist init X-Git-Tag: v6.16-rc1~215^2~49 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=37d26edd6bb4984849a71e21c6824c961fcd19db;p=thirdparty%2Fkernel%2Flinux.git io_uring/zcrx: remove duplicated freelist init Several lines below we already initialise the freelist, don't do it twice. Reviewed-by: David Wei Signed-off-by: Pavel Begunkov Link: https://lore.kernel.org/r/71b07c4e00d1db65899d1ed8d603d961fe7d1c28.1745141261.git.asml.silence@gmail.com Signed-off-by: Jens Axboe --- diff --git a/io_uring/zcrx.c b/io_uring/zcrx.c index fe86606b9f304..79f58c94494b0 100644 --- a/io_uring/zcrx.c +++ b/io_uring/zcrx.c @@ -245,9 +245,6 @@ static int io_zcrx_create_area(struct io_zcrx_ifq *ifq, if (!area->freelist) goto err; - for (i = 0; i < nr_iovs; i++) - area->freelist[i] = i; - area->user_refs = kvmalloc_array(nr_iovs, sizeof(area->user_refs[0]), GFP_KERNEL | __GFP_ZERO); if (!area->user_refs)