diff options
| author | Pavel Begunkov <asml.silence@gmail.com> | 2025-09-16 15:27:45 +0100 |
|---|---|---|
| committer | Jens Axboe <axboe@kernel.dk> | 2025-09-16 12:37:20 -0600 |
| commit | bdc0d478a1632a72afa6d359d7fdd49dd08c0b25 (patch) | |
| tree | 1d009c5fee3fe1000b99de84082c8046ca1dfba5 | |
| parent | 9eb3c571787d1ef7e2c3393c153b1a6b103a26e3 (diff) | |
io_uring/zcrx: replace memchar_inv with is_zero
memchr_inv() is more ambiguous than mem_is_zero(), so use the latter
for zero checks.
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
| -rw-r--r-- | io_uring/zcrx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/io_uring/zcrx.c b/io_uring/zcrx.c index c02045e4c1b6..a4a0560e8269 100644 --- a/io_uring/zcrx.c +++ b/io_uring/zcrx.c @@ -566,7 +566,7 @@ int io_register_zcrx_ifq(struct io_ring_ctx *ctx, return -EFAULT; if (copy_from_user(&rd, u64_to_user_ptr(reg.region_ptr), sizeof(rd))) return -EFAULT; - if (memchr_inv(®.__resv, 0, sizeof(reg.__resv)) || + if (!mem_is_zero(®.__resv, sizeof(reg.__resv)) || reg.__resv2 || reg.zcrx_id) return -EINVAL; if (reg.if_rxq == -1 || !reg.rq_entries || reg.flags) |
