From patchwork Mon Sep 18 02:11:20 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simei Su X-Patchwork-Id: 131524 X-Patchwork-Delegate: qi.z.zhang@intel.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 32F1C425C9; Mon, 18 Sep 2023 04:12:42 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 4E14D40648; Mon, 18 Sep 2023 04:12:31 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.55.52.151]) by mails.dpdk.org (Postfix) with ESMTP id 7347040A71 for ; Mon, 18 Sep 2023 04:12:29 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1695003149; x=1726539149; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=fAkwVSHRiZyA3PT1f2cNrWILhz+4ePiUyH+vk5IyGes=; b=IVk47vB9R5euldPhYcN9EGuEJYzNjiBE+xAGYODRMH/SpZZzpFL0TLch eanDjC/Hs4HrNTWVH5a6ry1Qxy+RoPafmuVy3w+goSMengqqWDNiCrsGN FMW8PoeUlaG1HfvGGrfvLNEe5SObBYLxZDYaDp/+IftaH+BydDMPtdIf7 hxQvr0xqY7qCi8C2PJpWJm8VLxaON+5Yp8yWI9oBB3zWWNG8oo1YKYkZn NGhArx0eW7EYLW4MH89209qFk2YOVtuvLFB197lX4myQOqduVw+XLiIRU GEVfzFaiZgYLdi1T/zaOhl65lsOnAU+30Kal2HE9fgDrvx2Dwt2fxU5PU A==; X-IronPort-AV: E=McAfee;i="6600,9927,10836"; a="359801703" X-IronPort-AV: E=Sophos;i="6.02,155,1688454000"; d="scan'208";a="359801703" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 17 Sep 2023 19:11:25 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10836"; a="815846890" X-IronPort-AV: E=Sophos;i="6.02,155,1688454000"; d="scan'208";a="815846890" Received: from dpdk-simei-icelake.sh.intel.com ([10.67.110.167]) by fmsmga004.fm.intel.com with ESMTP; 17 Sep 2023 19:11:23 -0700 From: Simei Su To: jingjing.wu@intel.com, beilei.xing@intel.com, qi.z.zhang@intel.com Cc: dev@dpdk.org, wenjun1.wu@intel.com, mingxia.liu@intel.com, wenjing.qiao@intel.com, Simei Su , Alan Brady Subject: [PATCH v4 08/18] common/idpf/base: add union for SW cookie fields in ctlq msg Date: Mon, 18 Sep 2023 10:11:20 +0800 Message-Id: <20230918021130.192982-9-simei.su@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230918021130.192982-1-simei.su@intel.com> References: <20230915021730.2681882-1-simei.su@intel.com> <20230918021130.192982-1-simei.su@intel.com> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Instead of using something like a byte offset, we can add a union to the struct here to enable direct addressing. Signed-off-by: Alan Brady Signed-off-by: Simei Su Acked-by: Beilei Xing --- .mailmap | 1 + drivers/common/idpf/base/idpf_controlq_api.h | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/.mailmap b/.mailmap index 23aed53102..2fcadb4e4c 100644 --- a/.mailmap +++ b/.mailmap @@ -1645,3 +1645,4 @@ Josh Hay Madhu Chittim Shailendra Bhatnagar Julianx Grajkowski +Alan Brady diff --git a/drivers/common/idpf/base/idpf_controlq_api.h b/drivers/common/idpf/base/idpf_controlq_api.h index 3780304256..f4e7b53ac9 100644 --- a/drivers/common/idpf/base/idpf_controlq_api.h +++ b/drivers/common/idpf/base/idpf_controlq_api.h @@ -77,6 +77,11 @@ struct idpf_ctlq_msg { u8 context[IDPF_INDIRECT_CTX_SIZE]; struct idpf_dma_mem *payload; } indirect; + struct { + u32 rsvd; + u16 data; + u16 flags; + } sw_cookie; } ctx; };