From patchwork Tue Sep 13 22:30:50 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bob Pearson X-Patchwork-Id: 12975423 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 D570AC54EE9 for ; Tue, 13 Sep 2022 22:31:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229786AbiIMWb0 (ORCPT ); Tue, 13 Sep 2022 18:31:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35512 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229749AbiIMWbT (ORCPT ); Tue, 13 Sep 2022 18:31:19 -0400 Received: from mail-oa1-x2b.google.com (mail-oa1-x2b.google.com [IPv6:2001:4860:4864:20::2b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2C8FC72B50 for ; Tue, 13 Sep 2022 15:31:17 -0700 (PDT) Received: by mail-oa1-x2b.google.com with SMTP id 586e51a60fabf-1279948d93dso36064482fac.10 for ; Tue, 13 Sep 2022 15:31:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=tkaqMMw9p3X0dL/zjpn2XBuFPYQIcYLXNkKokBG+6u4=; b=Ic7wUp1lvJrgo+v4QvL6wdrBgjpWeXzvjTrEI1axt6EE7OjtEDp1oXG+skSTiINLDY ENskBCuVlXKAx9gc7ztwsXjoYHhmUHL6T3D19cqKJuw3hJTBU/SB3FqeMmxYz4BNxqiH VTSuNWzSDVswJ3wgy64c2ZIkCFimMUUg3dIzV3+yJi1Cr2JNpis5jasPk3VQEpZxNq+C n34gEwqKtdYgWjewDe+q/yuJXIj/4WrjccmeKg5JH8mPEJmuVmogRKQH1jDHDTW8tkjl 8R0nD9gBNAzz7fg5LtVNudPY/JU4TIOLaK1A4ggX0ve9a/iRXAFxqyuK2Ug9CsqiB+Pk e0DQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=tkaqMMw9p3X0dL/zjpn2XBuFPYQIcYLXNkKokBG+6u4=; b=UxW+ZnfkduvrB9S9heWBWD971Egavraf9dEvDFlh5I7SfVzLywAAKwUMhxT5oJq/TT qPaXTKrOsCsH6ZKZ3STE7WHrzvuY1M06AoLV7gHAQk3BZo6hicjHmm/I17HEZ0doUEnQ DEggOq2t9uXtILXr9J7mWaa5di/a8qVBpchMgHn4jnOQgximJrhrjxhfF2D59gxO7FQL 99hiP7+hTs2kqTbUNBYoPcGJSscdckYf9UfzAvTTlcCNKNkLnuXwCrXXY6mH0WDWqFQM vmhWx3N11/DRXOjMaT1ltCVm0li6l13Lf6vyx78hGCXpTGCPHugjIdS3GnhmGuB+kQxy HMyQ== X-Gm-Message-State: ACgBeo1DJlxAwWHNobts5+hffWK8aCCKssoO8QO76CMl303XQDw/HKVL ZRjBa5ho5RUQbyCSPpBe/CJ0eiwXOag= X-Google-Smtp-Source: AA6agR4YwH6pqP8yn19+wmhiwvALEHKaf0NFu+ixDB4zh1eAkAoGzCwyFdqWtoD2ZsBrqNaLlMNwqQ== X-Received: by 2002:aca:220d:0:b0:34f:7312:f1f with SMTP id b13-20020aca220d000000b0034f73120f1fmr674548oic.4.1663108276484; Tue, 13 Sep 2022 15:31:16 -0700 (PDT) Received: from ubuntu-22.tx.rr.com (2603-8081-140c-1a00-d098-9475-e37c-b40b.res6.spectrum.com. [2603:8081:140c:1a00:d098:9475:e37c:b40b]) by smtp.googlemail.com with ESMTPSA id v17-20020a05683018d100b0063696cbb6bdsm6537131ote.62.2022.09.13.15.31.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Sep 2022 15:31:15 -0700 (PDT) From: Bob Pearson To: jgg@nvidia.com, zyjzyj2000@gmail.com, linux-rdma@vger.kernel.org Cc: Bob Pearson Subject: [PATCH 1/2] Update kernel headers Date: Tue, 13 Sep 2022 17:30:50 -0500 Message-Id: <20220913223050.18416-2-rpearsonhpe@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220913223050.18416-1-rpearsonhpe@gmail.com> References: <20220913223050.18416-1-rpearsonhpe@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org To commit ?? ("RDMA/rxe: Remove redundant num_sge fields"). Signed-off-by: Bob Pearson --- kernel-headers/rdma/rdma_user_rxe.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel-headers/rdma/rdma_user_rxe.h b/kernel-headers/rdma/rdma_user_rxe.h index f09c5c9e..73f679df 100644 --- a/kernel-headers/rdma/rdma_user_rxe.h +++ b/kernel-headers/rdma/rdma_user_rxe.h @@ -74,7 +74,7 @@ struct rxe_av { struct rxe_send_wr { __aligned_u64 wr_id; - __u32 num_sge; + __u32 reserved; __u32 opcode; __u32 send_flags; union { @@ -166,7 +166,7 @@ struct rxe_send_wqe { struct rxe_recv_wqe { __aligned_u64 wr_id; - __u32 num_sge; + __u32 reserved; __u32 padding; struct rxe_dma_info dma; }; From patchwork Tue Sep 13 22:30:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bob Pearson X-Patchwork-Id: 12975424 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 502C6ECAAD8 for ; Tue, 13 Sep 2022 22:31:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229812AbiIMWb3 (ORCPT ); Tue, 13 Sep 2022 18:31:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229726AbiIMWbU (ORCPT ); Tue, 13 Sep 2022 18:31:20 -0400 Received: from mail-oa1-x2a.google.com (mail-oa1-x2a.google.com [IPv6:2001:4860:4864:20::2a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 83DE761119 for ; Tue, 13 Sep 2022 15:31:19 -0700 (PDT) Received: by mail-oa1-x2a.google.com with SMTP id 586e51a60fabf-1278a61bd57so36101849fac.7 for ; Tue, 13 Sep 2022 15:31:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=2RHp9JX9JRKmHW11AcriMY0FnL/jJyQCUF1ljHas1x4=; b=J6mFijn1Cq+JxTASpi+c/UQ0rH3jKS1vLRu5SaQCdbozq+xNYbGOyZ7NPkYU3sSuxL CRQ401essDxJ/Mk61bdoGTQP1CL99qjzTkNlMirq/HFBz19VTKQxr6gykN69mzzPJatp 97ZiHOwQEuoOsVPp6pdrnCA8jC0JOU3JZ0vNnzP1IfuzvJp1zTR+n7watt+7EjJlEgxy zd8JOZO9hC6rKOp0C5YOVUmuHciBm4VFxT1mIut2+JUaOMC6GVSqjii3aHen7IMbMapd /deQHiLOJRgynmpnNHvaY/Cu4lgvdt/jR312/miUWyTPJatQOn40bXoPNy3FDq+X/RIj JzUg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=2RHp9JX9JRKmHW11AcriMY0FnL/jJyQCUF1ljHas1x4=; b=7azSxD8QRV9dsbRtD4R/9ta1Hy0Rx4sCXgcNhxX65wxA/pQiZteX89lrcteYDSvFCU m4DqtID2dMW80kX1EKluOzII7zU2mvxkKOQjS8pKXngQRRp8m2GwgzC3PxsyHBhIaGNz KKtFgkZmdabuk3T5W9gr25jEF9193NcmP/Ld1XtAqsIfQOY5zS6t1nPbdHNgSVdumf/U NtvlXZZBOTmfIYGfd3V+qLtiK2Z9emMgJZDYxlbxPDVhNDgobyReo63jIbLdU/bktTgV c4oGDJjAhHZ8urlh/UrdIHhL3qGWDr3tf3TJf0T3SMiVcIVCUHgiokki+cIq+BTPsKsT LkxA== X-Gm-Message-State: ACgBeo0LuGQK+2fwN+pnxLr6yfjLyRhe/0evSTr+S9de4q5UE0o/F0ay Aq4WpG6MN0Ic3kl5b9WPyDaoK4q6lpo= X-Google-Smtp-Source: AA6agR4ImeTqaa8JqHULsam35xEBxDolqkgJaccsli18PwCmSpTae6iWn4+O8dBkjt7lNIhn9phBHg== X-Received: by 2002:a05:6870:1702:b0:127:cf3f:37b4 with SMTP id h2-20020a056870170200b00127cf3f37b4mr764265oae.254.1663108278833; Tue, 13 Sep 2022 15:31:18 -0700 (PDT) Received: from ubuntu-22.tx.rr.com (2603-8081-140c-1a00-d098-9475-e37c-b40b.res6.spectrum.com. [2603:8081:140c:1a00:d098:9475:e37c:b40b]) by smtp.googlemail.com with ESMTPSA id v17-20020a05683018d100b0063696cbb6bdsm6537131ote.62.2022.09.13.15.31.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 13 Sep 2022 15:31:17 -0700 (PDT) From: Bob Pearson To: jgg@nvidia.com, zyjzyj2000@gmail.com, linux-rdma@vger.kernel.org Cc: Bob Pearson Subject: [PATCH 2/2] providers/rxe: Remove redundant num_sge fields Date: Tue, 13 Sep 2022 17:30:51 -0500 Message-Id: <20220913223050.18416-3-rpearsonhpe@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220913223050.18416-1-rpearsonhpe@gmail.com> References: <20220913223050.18416-1-rpearsonhpe@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org This patch is a matching patch to a kernel patch "RDMA/rxe: Remove redundant num_sge fields" which performs the same function for the kernel rxe driver. Signed-off-by: Bob Pearson --- providers/rxe/rxe.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/providers/rxe/rxe.c b/providers/rxe/rxe.c index 9a900e4d..0e8f5605 100644 --- a/providers/rxe/rxe.c +++ b/providers/rxe/rxe.c @@ -679,6 +679,7 @@ static int rxe_post_one_recv(struct rxe_wq *rq, struct ibv_recv_wr *recv_wr) int i; struct rxe_recv_wqe *wqe; struct rxe_queue_buf *q = rq->queue; + int num_sge = recv_wr->num_sge; int length = 0; int rc = 0; @@ -687,7 +688,7 @@ static int rxe_post_one_recv(struct rxe_wq *rq, struct ibv_recv_wr *recv_wr) goto out; } - if (recv_wr->num_sge > rq->max_sge) { + if (num_sge > rq->max_sge) { rc = EINVAL; goto out; } @@ -695,18 +696,17 @@ static int rxe_post_one_recv(struct rxe_wq *rq, struct ibv_recv_wr *recv_wr) wqe = (struct rxe_recv_wqe *)producer_addr(q); wqe->wr_id = recv_wr->wr_id; - wqe->num_sge = recv_wr->num_sge; memcpy(wqe->dma.sge, recv_wr->sg_list, - wqe->num_sge*sizeof(*wqe->dma.sge)); + num_sge*sizeof(*wqe->dma.sge)); - for (i = 0; i < wqe->num_sge; i++) + for (i = 0; i < num_sge; i++) length += wqe->dma.sge[i].length; wqe->dma.length = length; wqe->dma.resid = length; wqe->dma.cur_sge = 0; - wqe->dma.num_sge = wqe->num_sge; + wqe->dma.num_sge = num_sge; wqe->dma.sge_offset = 0; advance_producer(q); @@ -1406,7 +1406,6 @@ static void convert_send_wr(struct rxe_qp *qp, struct rxe_send_wr *kwr, memset(kwr, 0, sizeof(*kwr)); kwr->wr_id = uwr->wr_id; - kwr->num_sge = uwr->num_sge; kwr->opcode = uwr->opcode; kwr->send_flags = uwr->send_flags; kwr->ex.imm_data = uwr->imm_data;