From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5B138267733; Wed, 30 Jul 2025 09:55:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753869338; cv=none; b=mk3LwC1Pwms46xtFVqHURJ/sgEOQZOHAHVaHNJ6e2FdWmgYH+AluaTG4V9TNjnaTX/7HZJ4CcVX9gPzv3kh87w4FbPoo5x4tSEyM+MsFEQc3Ttx8LAMSHqBcLmWO//jAtKRkPVyCvOxuwZ5P697LQ3esOBtXRURVRCMOMbWBhqo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1753869338; c=relaxed/simple; bh=Co9bmhSiRwO4sIQH0ByKPC0oKWvMDMUOp9/OnAng9Xk=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=oj1jN7RJzxT/V8hggpRev0ED/uwKyr9Hvf9tR0WA6xKMX/XW1OmzwLHjww4V4Hx1Y0cW2w02bE/JMYYkuVTiRYARPDTe3TbJeqSxiVrky5CW9EyBbzLS/S2CezK5B6amPtLkGUNEi2irVoE2qy43eytOqZHvoMW0+nT05gcVFA4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=KB7MO0Br; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="KB7MO0Br" Received: by smtp.kernel.org (Postfix) with ESMTPSA id BF252C4CEF6; Wed, 30 Jul 2025 09:55:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1753869338; bh=Co9bmhSiRwO4sIQH0ByKPC0oKWvMDMUOp9/OnAng9Xk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=KB7MO0BrvAD5GfzA003RXlaYGgwUqXCvBp8iUN7LYkqJDVjP8IUvMSOWCoRPRkbJu +a9rI5MKq/gl/s8l7hAy2LNgJQAFk6Nvgv6O4R0m/T3MkHAD9ADtggeYolLQ2lk8Av 7x572v6b9nlKJY93h2sb6psre3axf0xlJXTpPmp4= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Jacek Kowalski , Vlad URSU , Simon Horman , Vitaly Lifshits , Mor Bar-Gabay , Tony Nguyen Subject: [PATCH 6.15 68/92] e1000e: ignore uninitialized checksum word on tgp Date: Wed, 30 Jul 2025 11:36:16 +0200 Message-ID: <20250730093233.380534849@linuxfoundation.org> X-Mailer: git-send-email 2.50.1 In-Reply-To: <20250730093230.629234025@linuxfoundation.org> References: <20250730093230.629234025@linuxfoundation.org> User-Agent: quilt/0.68 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Jacek Kowalski commit 61114910a5f6a71d0b6ea3b95082dfe031b19dfe upstream. As described by Vitaly Lifshits: > Starting from Tiger Lake, LAN NVM is locked for writes by SW, so the > driver cannot perform checksum validation and correction. This means > that all NVM images must leave the factory with correct checksum and > checksum valid bit set. Unfortunately some systems have left the factory with an uninitialized value of 0xFFFF at register address 0x3F (checksum word location). So on Tiger Lake platform we ignore the computed checksum when such condition is encountered. Signed-off-by: Jacek Kowalski Tested-by: Vlad URSU Fixes: 4051f68318ca9 ("e1000e: Do not take care about recovery NVM checksum") Cc: stable@vger.kernel.org Reviewed-by: Simon Horman Reviewed-by: Vitaly Lifshits Tested-by: Mor Bar-Gabay Signed-off-by: Tony Nguyen Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/intel/e1000e/defines.h | 3 +++ drivers/net/ethernet/intel/e1000e/nvm.c | 6 ++++++ 2 files changed, 9 insertions(+) --- a/drivers/net/ethernet/intel/e1000e/defines.h +++ b/drivers/net/ethernet/intel/e1000e/defines.h @@ -638,6 +638,9 @@ /* For checksumming, the sum of all words in the NVM should equal 0xBABA. */ #define NVM_SUM 0xBABA +/* Uninitialized ("empty") checksum word value */ +#define NVM_CHECKSUM_UNINITIALIZED 0xFFFF + /* PBA (printed board assembly) number words */ #define NVM_PBA_OFFSET_0 8 #define NVM_PBA_OFFSET_1 9 --- a/drivers/net/ethernet/intel/e1000e/nvm.c +++ b/drivers/net/ethernet/intel/e1000e/nvm.c @@ -558,6 +558,12 @@ s32 e1000e_validate_nvm_checksum_generic checksum += nvm_data; } + if (hw->mac.type == e1000_pch_tgp && + nvm_data == NVM_CHECKSUM_UNINITIALIZED) { + e_dbg("Uninitialized NVM Checksum on TGP platform - ignoring\n"); + return 0; + } + if (checksum != (u16)NVM_SUM) { e_dbg("NVM Checksum Invalid\n"); return -E1000_ERR_NVM;