From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pl1-f227.google.com (mail-pl1-f227.google.com [209.85.214.227]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E27C33859E3 for ; Fri, 27 Feb 2026 22:35:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.214.227 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772231710; cv=none; b=D1Tz0f4fzMWThH+PNPWG3PFPdf7+es9C5/OkgDgILWVib0xIZh4YYTUA88CclewG7T7kGEHNWJ0Oy2fQKvP7SzH+ODfTN4lIkfQOFrJnEi3D+MDn5ccP6IMnM9iEq4BiqiYUql3mSGxlRGG5uc2p890DOfOkhNx5zfKPJ/HQ1ck= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1772231710; c=relaxed/simple; bh=mZRg9aJ/vT9KGxR37N9gh9XV0GFWpQmAWSI7PzYmIhE=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=T9/8fsQi5Ia4veCrqhpMxFfmq87MNZwb3dRiFM5c2qxfoQppFkkhaquwe/z+gGRm0rRsyWOu1+AvojGwRErIp/tietjltpN4/OE1v76tumOo69lAbnhk1u16CEPvluzEUs8fXeMQi+XhG5eYxJPDRsnNyss+HGVXJnGIf+eqtNA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=purestorage.com; spf=fail smtp.mailfrom=purestorage.com; dkim=pass (2048-bit key) header.d=purestorage.com header.i=@purestorage.com header.b=OPb3jkTm; arc=none smtp.client-ip=209.85.214.227 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=purestorage.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=purestorage.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=purestorage.com header.i=@purestorage.com header.b="OPb3jkTm" Received: by mail-pl1-f227.google.com with SMTP id d9443c01a7336-2ae3a007bd1so163095ad.2 for ; Fri, 27 Feb 2026 14:35:08 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=purestorage.com; s=google2022; t=1772231708; x=1772836508; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qVH9fXQsVA7juGOEz+1dE42o2vyEutyAkezbvq+KUlE=; b=OPb3jkTmEXXLtcPxCUrNGX64Mbsybraq0N6cFAJ18tF37G2/MXJV/9V12QETppXROe rHKH7JrhEeM7tVBMqVSdkfLIm7xKEkVd2V+eTIlPPO8SNGr0YXvpGoqljx9vkkLhOSn6 b+Z1/GjTYhrwRr+k+SK1bn05M7R2O+e93YSScgudgXQ/U/F56ScmqE2WfJZS1WCZX+uH TTHH+QpQLnDsz5+FZSujlKXC31LbbwxHxxrf+j7wFnafcESYUG2yHpa+eFa5DP3BCNCj NWN5I+Y/f8lFPojDZuIvm/1PsW23wg4WCvK7PdCl+8e3xDPikbjn17WggLcmuodAK1l0 2tAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1772231708; x=1772836508; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=qVH9fXQsVA7juGOEz+1dE42o2vyEutyAkezbvq+KUlE=; b=VsGfB89k1ODhjZPFrBmftYgXwUHfq76fsBltGCGYGQqga0NxWTxSEnwZoIPQ4P6elr IY8Xc0DdWob+IdB/aTMLTg9BdDDhF7Aov90P7A59V7w+7uego/fk/lSD/7N6QTc4Y8TT rz1rVqVWeq3AdM/V785mS23wgT/Sxm6dCYWWdsWIauzjMeo891U3vDeKnR9yUZz/VtPp SLc+Tb91vX3iCzOouyt02zVblLmZSlwhk33WCUgl8JVYgvhpSR47yMJtjkq+VWYB0JVQ R2rxvn3HX+iZQNRAVMIp1ITOjFy0z1U/fTChnDzStfdo21tlqU1hZUmM3PaJ7D4osCXG 1u4A== X-Forwarded-Encrypted: i=1; AJvYcCUadFcjuLaKDfNwprLbmh6dzfcHwPvPQmK+O62ihKNnAZRy7gKROHyd1IXM6bEQROss6BU1IiWOnhtn4bw=@vger.kernel.org X-Gm-Message-State: AOJu0YzhsxMFrVdBkqPkRRgGSqn9lJ6NxiAtLcXg0hV3OGwS5lq0bBu7 LUpwIAOlNfKEMigN9KyDAacUnSi/ORt00sTgw1Kczsy0+aJrufu84y4eK2u1pYAbt2jJLGlJwMT GKbNVSPV2B5ETZaY7aUjNOHF0fDoxG+dC9Ku5 X-Gm-Gg: ATEYQzyLGpdCU5vUVVAsR2Y3tH07uPpP539q+a7bP7sgnIjQrxI6Ne6P9W9JxVIrvE3 lgTp5j9/fTHg4YhxmZFn7EvzDzFjU67M2cSNosuEhpTe8+MJgyrUyVxxCLzPA91CD8rGl0Ejonc J800uDcY9kDF+8HfueRApYnmK+07oxDdbWwBW9oH5oYTGfPByKGkkKt/4kJAGCsrVcEL5bx6J7C cRrnfwYaVwXxTlgETqLxvbWvctMxMmROunhviX3qPGzECDoLAQc4dM+Ky90EfO9Pmkli+WKwMgh N5gJIWIJKi4BhIW9fVca9sZP9X23MdAD+RsllbRk6ZQFWFTN0e7CEgNU/42AvGSU1w/A6J0imdk a/1SvPrVWaSDcE1ewk0d6uZwVB/MA4MlvFfJfsQr0BxSM3SUp03BKbA== X-Received: by 2002:a17:902:e847:b0:2a7:cbe3:a6e3 with SMTP id d9443c01a7336-2ae2e3e0d9bmr31622965ad.2.1772231708194; Fri, 27 Feb 2026 14:35:08 -0800 (PST) Received: from c7-smtp-2023.dev.purestorage.com ([208.88.159.129]) by smtp-relay.gmail.com with ESMTPS id d9443c01a7336-2adfb5eec86sm7901965ad.41.2026.02.27.14.35.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 27 Feb 2026 14:35:08 -0800 (PST) X-Relaying-Domain: purestorage.com Received: from dev-csander.dev.purestorage.com (dev-csander.dev.purestorage.com [10.112.29.101]) by c7-smtp-2023.dev.purestorage.com (Postfix) with ESMTP id E9C1534179D; Fri, 27 Feb 2026 15:35:06 -0700 (MST) Received: by dev-csander.dev.purestorage.com (Postfix, from userid 1557716354) id E5700E420D8; Fri, 27 Feb 2026 15:35:06 -0700 (MST) From: Caleb Sander Mateos To: Jens Axboe , Christoph Hellwig , Keith Busch , Sagi Grimberg Cc: io-uring@vger.kernel.org, linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org, Anuj Gupta , Kanchan Joshi , Ming Lei , Caleb Sander Mateos Subject: [PATCH v4 2/5] io_uring: remove iopoll_queue from struct io_issue_def Date: Fri, 27 Feb 2026 15:35:00 -0700 Message-ID: <20260227223504.1162421-3-csander@purestorage.com> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20260227223504.1162421-1-csander@purestorage.com> References: <20260227223504.1162421-1-csander@purestorage.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The opcode iopoll_queue flag is now redundant with REQ_F_IOPOLL. Only io_{read,write}{,_fixed}() and io_uring_cmd() set the REQ_F_IOPOLL flag, and the opcodes with these ->issue() implementations are precisely the ones that set iopoll_queue. So don't bother checking the iopoll_queue flag in io_issue_sqe(). Remove the unused flag from struct io_issue_def. Signed-off-by: Caleb Sander Mateos Reviewed-by: Kanchan Joshi Reviewed-by: Anuj Gupta --- io_uring/io_uring.c | 3 +-- io_uring/opdef.c | 10 ---------- io_uring/opdef.h | 2 -- 3 files changed, 1 insertion(+), 14 deletions(-) diff --git a/io_uring/io_uring.c b/io_uring/io_uring.c index e7f392e962bd..46f39831d27c 100644 --- a/io_uring/io_uring.c +++ b/io_uring/io_uring.c @@ -1415,12 +1415,11 @@ static int io_issue_sqe(struct io_kiocb *req, unsigned int issue_flags) } if (ret == IOU_ISSUE_SKIP_COMPLETE) { ret = 0; - /* If the op doesn't have a file, we're not polling for it */ - if ((req->flags & REQ_F_IOPOLL) && def->iopoll_queue) + if (req->flags & REQ_F_IOPOLL) io_iopoll_req_issued(req, issue_flags); } return ret; } diff --git a/io_uring/opdef.c b/io_uring/opdef.c index 645980fa4651..c3ef52b70811 100644 --- a/io_uring/opdef.c +++ b/io_uring/opdef.c @@ -65,11 +65,10 @@ const struct io_issue_def io_issue_defs[] = { .buffer_select = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .vectored = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_readv, .issue = io_read, }, @@ -80,11 +79,10 @@ const struct io_issue_def io_issue_defs[] = { .pollout = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .vectored = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_writev, .issue = io_write, }, @@ -100,11 +98,10 @@ const struct io_issue_def io_issue_defs[] = { .pollin = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_read_fixed, .issue = io_read_fixed, }, [IORING_OP_WRITE_FIXED] = { @@ -114,11 +111,10 @@ const struct io_issue_def io_issue_defs[] = { .pollout = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_write_fixed, .issue = io_write_fixed, }, [IORING_OP_POLL_ADD] = { @@ -248,11 +244,10 @@ const struct io_issue_def io_issue_defs[] = { .buffer_select = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_read, .issue = io_read, }, [IORING_OP_WRITE] = { @@ -262,11 +257,10 @@ const struct io_issue_def io_issue_defs[] = { .pollout = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_write, .issue = io_write, }, [IORING_OP_FADVISE] = { @@ -421,11 +415,10 @@ const struct io_issue_def io_issue_defs[] = { [IORING_OP_URING_CMD] = { .buffer_select = 1, .needs_file = 1, .plug = 1, .iopoll = 1, - .iopoll_queue = 1, .async_size = sizeof(struct io_async_cmd), .prep = io_uring_cmd_prep, .issue = io_uring_cmd, }, [IORING_OP_SEND_ZC] = { @@ -554,11 +547,10 @@ const struct io_issue_def io_issue_defs[] = { .pollin = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .vectored = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_readv_fixed, .issue = io_read, }, @@ -569,11 +561,10 @@ const struct io_issue_def io_issue_defs[] = { .pollout = 1, .plug = 1, .audit_skip = 1, .ioprio = 1, .iopoll = 1, - .iopoll_queue = 1, .vectored = 1, .async_size = sizeof(struct io_async_rw), .prep = io_prep_writev_fixed, .issue = io_write, }, @@ -591,11 +582,10 @@ const struct io_issue_def io_issue_defs[] = { [IORING_OP_URING_CMD128] = { .buffer_select = 1, .needs_file = 1, .plug = 1, .iopoll = 1, - .iopoll_queue = 1, .is_128 = 1, .async_size = sizeof(struct io_async_cmd), .prep = io_uring_cmd_prep, .issue = io_uring_cmd, }, diff --git a/io_uring/opdef.h b/io_uring/opdef.h index faf3955dce8b..667f981e63b0 100644 --- a/io_uring/opdef.h +++ b/io_uring/opdef.h @@ -23,12 +23,10 @@ struct io_issue_def { unsigned pollin : 1; unsigned pollout : 1; unsigned poll_exclusive : 1; /* skip auditing */ unsigned audit_skip : 1; - /* have to be put into the iopoll list */ - unsigned iopoll_queue : 1; /* vectored opcode, set if 1) vectored, and 2) handler needs to know */ unsigned vectored : 1; /* set to 1 if this opcode uses 128b sqes in a mixed sq */ unsigned is_128 : 1; -- 2.45.2