From patchwork Tue Jan 25 08:50:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Li Zhijian X-Patchwork-Id: 12723438 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id A8379C433F5 for ; Tue, 25 Jan 2022 08:56:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1452984AbiAYI4R (ORCPT ); Tue, 25 Jan 2022 03:56:17 -0500 Received: from mail.cn.fujitsu.com ([183.91.158.132]:7819 "EHLO heian.cn.fujitsu.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1452913AbiAYIvJ (ORCPT ); Tue, 25 Jan 2022 03:51:09 -0500 IronPort-Data: A9a23:f+t1z6NoIFg2P8rvrR2qlsFynXyQoLVcMsFnjC/WdQG/hTJzhjEAx2tJC2uAbKuDNGX1ft1xbNnk8k8HvZ7dm99gGjLY11k3ESsS9pCt6fd1j6vIF3rLaJWFFSqL1u1GAjX7BJ1yHi+0SiuFaOC79yElj/zQH9IQNcafUsxPbV49IMseoUI78wIJqtYAbemRW2thi/uryyHsEAPNNwpPD44hw/nrRCWDExjFkGhwUlQWPZintbJF/pUfJMp3yaqZdxMUTmTId9NWSdovzJnhlo/Y1xwrTN24kLfnaVBMSbnXVeSMoiMOHfH83V4Z/Wpvuko4HKN0hUN/jzSbn9FzydxLnZKtSwY1JbCKk+MYO/VdO3gkZf0dqeSYfxBTtuTWlSUqaUDE2e1jBVstOosY4utfDmRH9PheIzcIBjiRluCk0bDhErE0rssmJcjveogYvxlIyTDQC/k5TJbbTqPFzd9F1Sg9h4ZFGvO2T8YQb3xtKgvBZxlOM1IMIJM4gOqswHL4dlVwtFWQrLElpWfJywl43KruMfLUfMCHQYNemUPwjmbL+GLRARwAMtGbjz2f/RqEj+/GhyT9XKoUCry09/csi1qWrkQWAhkRXluTp+e4hk+3HdlYLiQ85i0rhbQ78FSmX5/2WBjQiHqFuAMMHtldCes37CmTxafOpQWUHG4JSnhGctNOnMs3QyE6k0WFmtrBGzNiqvuWRGib+7PSqim9UQAXImAqdy4JVQZD6NCLnW2ZpnojVf46SOjs0IKzQmq2nli3QOEFr+17paY2O2+TpzgrWw6Rm6U= IronPort-HdrOrdr: A9a23:cDoT2azdJwcasm1ok+CQKrPwEL1zdoMgy1knxilNoH1uA6ilfqWV8cjzuiWbtN9vYhsdcLy7WZVoIkmskKKdg7NhXotKNTOO0ASVxepZnOnfKlPbexHWx6p00KdMV+xEAsTsMF4St63HyTj9P9E+4NTvysyVuds= X-IronPort-AV: E=Sophos;i="5.88,314,1635177600"; d="scan'208";a="120839376" Received: from unknown (HELO cn.fujitsu.com) ([10.167.33.5]) by heian.cn.fujitsu.com with ESMTP; 25 Jan 2022 16:44:35 +0800 Received: from G08CNEXMBPEKD06.g08.fujitsu.local (unknown [10.167.33.206]) by cn.fujitsu.com (Postfix) with ESMTP id DE3824D15A5C; Tue, 25 Jan 2022 16:44:33 +0800 (CST) Received: from G08CNEXCHPEKD09.g08.fujitsu.local (10.167.33.85) by G08CNEXMBPEKD06.g08.fujitsu.local (10.167.33.206) with Microsoft SMTP Server (TLS) id 15.0.1497.23; Tue, 25 Jan 2022 16:44:31 +0800 Received: from localhost.localdomain (10.167.225.141) by G08CNEXCHPEKD09.g08.fujitsu.local (10.167.33.209) with Microsoft SMTP Server id 15.0.1497.23 via Frontend Transport; Tue, 25 Jan 2022 16:44:31 +0800 From: Li Zhijian To: , , , , , , CC: , , , , , , , Li Zhijian Subject: [RFC PATCH v2 9/9] RDMA/rxe: Add RD FLUSH service support Date: Tue, 25 Jan 2022 16:50:41 +0800 Message-ID: <20220125085041.49175-10-lizhijian@cn.fujitsu.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20220125085041.49175-1-lizhijian@cn.fujitsu.com> References: <20220125085041.49175-1-lizhijian@cn.fujitsu.com> MIME-Version: 1.0 X-yoursite-MailScanner-ID: DE3824D15A5C.AEA72 X-yoursite-MailScanner: Found to be clean X-yoursite-MailScanner-From: lizhijian@fujitsu.com Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org Although the SPEC said FLUSH is supported by RC/RD/XRC services, XRC has not been supported by the rxe. So XRC FLUSH will not be supported until rxe implements XRC service. Signed-off-by: Li Zhijian --- I have not setup a RD environment to test this protocol --- drivers/infiniband/sw/rxe/rxe_opcode.c | 20 ++++++++++++++++++++ include/rdma/ib_pack.h | 1 + 2 files changed, 21 insertions(+) diff --git a/drivers/infiniband/sw/rxe/rxe_opcode.c b/drivers/infiniband/sw/rxe/rxe_opcode.c index adea6c16dfb5..3d86129558f7 100644 --- a/drivers/infiniband/sw/rxe/rxe_opcode.c +++ b/drivers/infiniband/sw/rxe/rxe_opcode.c @@ -922,6 +922,26 @@ struct rxe_opcode_info rxe_opcode[RXE_NUM_OPCODE] = { RXE_RDETH_BYTES, } }, + [IB_OPCODE_RD_RDMA_FLUSH] = { + .name = "IB_OPCODE_RD_RDMA_FLUSH", + .mask = RXE_RDETH_MASK | RXE_FETH_MASK | RXE_RETH_MASK | + RXE_FLUSH_MASK | RXE_START_MASK | + RXE_END_MASK | RXE_REQ_MASK, + .length = RXE_BTH_BYTES + RXE_FETH_BYTES + RXE_RETH_BYTES, + .offset = { + [RXE_BTH] = 0, + [RXE_RDETH] = RXE_BTH_BYTES, + [RXE_FETH] = RXE_BTH_BYTES + + RXE_RDETH_BYTES, + [RXE_RETH] = RXE_BTH_BYTES + + RXE_RDETH_BYTES + + RXE_FETH_BYTES, + [RXE_PAYLOAD] = RXE_BTH_BYTES + + RXE_RDETH_BYTES + + RXE_FETH_BYTES + + RXE_RETH_BYTES, + } + }, /* UD */ [IB_OPCODE_UD_SEND_ONLY] = { diff --git a/include/rdma/ib_pack.h b/include/rdma/ib_pack.h index d19edb502de6..40568a33ead8 100644 --- a/include/rdma/ib_pack.h +++ b/include/rdma/ib_pack.h @@ -151,6 +151,7 @@ enum { IB_OPCODE(RD, ATOMIC_ACKNOWLEDGE), IB_OPCODE(RD, COMPARE_SWAP), IB_OPCODE(RD, FETCH_ADD), + IB_OPCODE(RD, RDMA_FLUSH), /* UD */ IB_OPCODE(UD, SEND_ONLY),