From patchwork Fri May 3 13:57:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Burakov, Anatoly" X-Patchwork-Id: 139836 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 A93A843F76; Fri, 3 May 2024 15:59:17 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0E919406B6; Fri, 3 May 2024 15:58:37 +0200 (CEST) Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.15]) by mails.dpdk.org (Postfix) with ESMTP id 2666340691 for ; Fri, 3 May 2024 15:58:35 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1714744715; x=1746280715; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=l9+PUKAsDi2uqwCxaMcNclP+NWYYilGNGmA3IVK50O0=; b=lDUgTbIHmcYH5TsM5MQkVDDDj9gz15Bk4JaPLLkRcAoJyp9sbmTesyDU Fde9BkEuEDWx856TWkiteyMC4nrDwNgEVkfnj2Sb+a3AELCbMMc6kBRTy YT/6bcT3LPNRQumLrzFQdQKq+wzXdMwuurwalz3R06W3BkneQhO+8qL7Y s0n1teXw2Do+z3DxaqtAUHzUjApoZTsA8ZDra11QR0Vwnu7P277mjHR8B TKSV3nDlnwokJbNXBlrdMbLl4wjXIJKNmYSVfGbgZfhj/H/FqEc+8N8WY Ctka0PqgfHGgRjo4R/aaGNFWsRSgzCvggG8bg5rlcdzXt8ULruKAUvD2G A==; X-CSE-ConnectionGUID: thv8vJUVSdqVaSOoHXagvQ== X-CSE-MsgGUID: Nj/O0J3+TmK1ZZKNLFKftQ== X-IronPort-AV: E=McAfee;i="6600,9927,11063"; a="10714923" X-IronPort-AV: E=Sophos;i="6.07,251,1708416000"; d="scan'208";a="10714923" Received: from fmviesa002.fm.intel.com ([10.60.135.142]) by fmvoesa109.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 May 2024 06:58:34 -0700 X-CSE-ConnectionGUID: JuqLDPCSRMe4A+L8/WE2UQ== X-CSE-MsgGUID: 9HaE7M1pT+GPxPmkIW2Sug== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.07,251,1708416000"; d="scan'208";a="50641972" Received: from silpixa00401119.ir.intel.com ([10.55.129.167]) by fmviesa002.fm.intel.com with ESMTP; 03 May 2024 06:58:32 -0700 From: Anatoly Burakov To: dev@dpdk.org Cc: Slawomir Mrozowicz , bruce.richardson@intel.com, vladimir.medvedkin@intel.com, Tyl@dpdk.org, RadoslawX , Skajewski@dpdk.org, PiotrX , nosbuild , Michael@dpdk.org, Alice Subject: [PATCH v2 08/27] net/ixgbe/base: fix crash while loading driver Date: Fri, 3 May 2024 14:57:39 +0100 Message-ID: <37776b322b3f097a0932f94b6c4ffc4d2e6456fd.1714744628.git.anatoly.burakov@intel.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: 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 From: Slawomir Mrozowicz Issue observed: system crash While loading the driver when debug macros were defined. The solution removes the debug macro call from ixgbe_set_mac_type() function which causes the crash. So far, the ixgbe_set_mac_type() function has called in the ixgbe driver ixgbe_probe() function before the struct ixgbe_hw is properly defined. In this case, the field back of the structure that must contain pointer to an adapter has not yet been defined and should not be used to obtain driver information which is needed in debug macros. Moreover bearing in mind the recommendations to not print out excessive amount of information it was decided to remove the debug information. Signed-off-by: Slawomir Mrozowicz Reviewed-by: Tyl, RadoslawX Reviewed-by: Skajewski, PiotrX Tested-by: nosbuild Reviewed-by: Michael, Alice --- Notes: This fix seems to be kernel-specific, so Cc:stable was intentionally omitted. drivers/net/ixgbe/base/ixgbe_api.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/net/ixgbe/base/ixgbe_api.c b/drivers/net/ixgbe/base/ixgbe_api.c index b322c181b4..89e1650d63 100644 --- a/drivers/net/ixgbe/base/ixgbe_api.c +++ b/drivers/net/ixgbe/base/ixgbe_api.c @@ -216,8 +216,6 @@ s32 ixgbe_set_mac_type(struct ixgbe_hw *hw) break; } - DEBUGOUT2("ixgbe_set_mac_type found mac: %d, returns: %d\n", - hw->mac.type, ret_val); return ret_val; }