From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2D88D45895; Thu, 29 Aug 2024 11:00:30 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 19B7C42D0B; Thu, 29 Aug 2024 11:00:30 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [198.175.65.17]) by mails.dpdk.org (Postfix) with ESMTP id 5010E42B71 for ; Thu, 29 Aug 2024 11:00:27 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1724922028; x=1756458028; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=GViP+ssLlrh+JHBZoaVKDhM/BrMYYwACmMeb4tqUhpE=; b=E7teH57o1gUyuwwE5bKVRw3qDqJBIGgejptopzBtIGygs7Ai+GhxTm9s A7L4K5dH8461n9cPjVMs0qRyudpb90Gillb/rb8ExyzRFouk+mTp9Z4Vn 81xaTs719DZ+VJqpv0iin9RF8rJ219k9thUfUkq+7NLOi8CDFMH7FmT9e nZrEtPWb/oIJgB/xFiVH0ynAC3lksE37u7ZT6sc+DLicGTOtYasjZ1P0n 9HER0d4yYsGAY/FgyBl99tT87uR9crAcpMnc4MInPl/+QzV299xmWmi0U PFnxrwZzV12vw8lHI1+mgXSG2SP1sVG0jZx46mnOdzodQ5lExHht1B8Pd A==; X-CSE-ConnectionGUID: D2vAruRGQ3aIFILXco8o/Q== X-CSE-MsgGUID: xhxGpuwASYSwSaTR9cfD2Q== X-IronPort-AV: E=McAfee;i="6700,10204,11178"; a="23663417" X-IronPort-AV: E=Sophos;i="6.10,185,1719903600"; d="scan'208";a="23663417" Received: from orviesa008.jf.intel.com ([10.64.159.148]) by orvoesa109.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Aug 2024 02:00:27 -0700 X-CSE-ConnectionGUID: TT/o+xt3QqC5Mrzn3cbd7g== X-CSE-MsgGUID: CvDB8qnlQT2XIGodexwEYQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.10,185,1719903600"; d="scan'208";a="64202933" Received: from silpixa00401119.ir.intel.com ([10.55.129.167]) by orviesa008.jf.intel.com with ESMTP; 29 Aug 2024 02:00:26 -0700 From: Anatoly Burakov To: dev@dpdk.org Subject: [PATCH v1 01/15] net/ixgbe/base: remove minsrevs code from DPDK Date: Thu, 29 Aug 2024 10:00:06 +0100 Message-ID: X-Mailer: git-send-email 2.43.5 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Commit add44414762c ("net/ixgbe/base: add E610 NVM-related operations") has added code to read minimum security revision from NVM. This code was not meant to be included in DPDK, and was only meant for other drivers derived from shared base code, but was present due to the way shared driver code snapshot was generated. Remove this code from DPDK driver. Fixes: add44414762c ("net/ixgbe/base: add E610 NVM-related operations") Signed-off-by: Anatoly Burakov --- drivers/net/ixgbe/base/ixgbe_e610.c | 54 ----------------------------- drivers/net/ixgbe/base/ixgbe_e610.h | 1 - 2 files changed, 55 deletions(-) diff --git a/drivers/net/ixgbe/base/ixgbe_e610.c b/drivers/net/ixgbe/base/ixgbe_e610.c index ac71980630..3e2be07731 100644 --- a/drivers/net/ixgbe/base/ixgbe_e610.c +++ b/drivers/net/ixgbe/base/ixgbe_e610.c @@ -2488,60 +2488,6 @@ static s32 ixgbe_read_nvm_sr_copy(struct ixgbe_hw *hw, return ixgbe_read_nvm_module(hw, bank, hdr_len + offset, data); } -/** - * ixgbe_get_nvm_minsrevs - Get the minsrevs values from flash - * @hw: pointer to the HW struct - * @minsrevs: structure to store NVM and OROM minsrev values - * - * Read the Minimum Security Revision TLV and extract - * the revision values from the flash image - * into a readable structure for processing. - * - * Return: the exit code of the operation. - */ -s32 ixgbe_get_nvm_minsrevs(struct ixgbe_hw *hw, - struct ixgbe_minsrev_info *minsrevs) -{ - struct ixgbe_aci_cmd_nvm_minsrev data; - s32 status; - u16 valid; - - status = ixgbe_acquire_nvm(hw, IXGBE_RES_READ); - if (status) - return status; - - status = ixgbe_aci_read_nvm(hw, IXGBE_ACI_NVM_MINSREV_MOD_ID, - 0, sizeof(data), &data, - true, false); - - ixgbe_release_nvm(hw); - - if (status) - return status; - - valid = IXGBE_LE16_TO_CPU(data.validity); - - /* Extract NVM minimum security revision */ - if (valid & IXGBE_ACI_NVM_MINSREV_NVM_VALID) { - u16 minsrev_l = IXGBE_LE16_TO_CPU(data.nvm_minsrev_l); - u16 minsrev_h = IXGBE_LE16_TO_CPU(data.nvm_minsrev_h); - - minsrevs->nvm = minsrev_h << 16 | minsrev_l; - minsrevs->nvm_valid = true; - } - - /* Extract the OROM minimum security revision */ - if (valid & IXGBE_ACI_NVM_MINSREV_OROM_VALID) { - u16 minsrev_l = IXGBE_LE16_TO_CPU(data.orom_minsrev_l); - u16 minsrev_h = IXGBE_LE16_TO_CPU(data.orom_minsrev_h); - - minsrevs->orom = minsrev_h << 16 | minsrev_l; - minsrevs->orom_valid = true; - } - - return IXGBE_SUCCESS; -} - /** * ixgbe_get_nvm_srev - Read the security revision from the NVM CSS header * @hw: pointer to the HW struct diff --git a/drivers/net/ixgbe/base/ixgbe_e610.h b/drivers/net/ixgbe/base/ixgbe_e610.h index 33c683d1c1..4babee821e 100644 --- a/drivers/net/ixgbe/base/ixgbe_e610.h +++ b/drivers/net/ixgbe/base/ixgbe_e610.h @@ -85,7 +85,6 @@ s32 ixgbe_aci_read_nvm(struct ixgbe_hw *hw, u16 module_typeid, u32 offset, s32 ixgbe_nvm_validate_checksum(struct ixgbe_hw *hw); s32 ixgbe_nvm_recalculate_checksum(struct ixgbe_hw *hw); -s32 ixgbe_get_nvm_minsrevs(struct ixgbe_hw *hw, struct ixgbe_minsrev_info *minsrevs); s32 ixgbe_get_inactive_nvm_ver(struct ixgbe_hw *hw, struct ixgbe_nvm_info *nvm); s32 ixgbe_get_active_nvm_ver(struct ixgbe_hw *hw, struct ixgbe_nvm_info *nvm); s32 ixgbe_init_nvm(struct ixgbe_hw *hw); -- 2.43.5