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 C00B71A00D4; Tue, 16 Jul 2024 15:51:25 +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=1721145085; cv=none; b=pUgcwBj/6JyZ2kypdBHEpOb9amd2oXFgMITxPhTLsf86K6Y60Y/1gJyRQf+2/HgDgQp/6KluRavMRJXV/s2qsOKoII4HEV4yh3edqNA619tJHLQbXx/wf2yXSsBtHLHYtJ60Fgjc/CCBumJtSv74oe8TFoulUFHM50dHeZx45tw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1721145085; c=relaxed/simple; bh=qZ256fIQKgDuWXUv7x4pWoshUkoN1lBOo83iRDX/W7o=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=vE9Ke1ibXFkWOE2HRDfYBm+r6HzvL3nK447OpnopjYckbsjyPuC/9QAPfkyxIC2LObtoxIYBuCh1jdqDBRmoXyuQfg1+5R/kWo623rPejfDy4qrwUKpZGSXJ/SG3S90UV922X8FnK2lK9xIFTEPa0DXN97k5N9BvUneKoVeEUt4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=yfpmInjd; 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="yfpmInjd" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 3D18EC116B1; Tue, 16 Jul 2024 15:51:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1721145085; bh=qZ256fIQKgDuWXUv7x4pWoshUkoN1lBOo83iRDX/W7o=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=yfpmInjdebhY6EceUvrfiwmyweQDtrU+U+tkCiaQST85fKvX6BhIY0WeuKbDV2G0E vLzD0+gF5YaVzHGMyLcunnFxV1pMsrKrcFrtl8thnZ+WKZv9UWO2MnXSk2Aa/3LegV 0vpRGpMGONuRdOMsZ0DIvEnPOL4LK4HhZh/kXFSI= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Kiran Kumar K , Kalesh AP , "David S. Miller" , Sasha Levin Subject: [PATCH 6.9 063/143] octeontx2-af: fix issue with IPv6 ext match for RSS Date: Tue, 16 Jul 2024 17:30:59 +0200 Message-ID: <20240716152758.402438041@linuxfoundation.org> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20240716152755.980289992@linuxfoundation.org> References: <20240716152755.980289992@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.9-stable review patch. If anyone has any objections, please let me know. ------------------ From: Kiran Kumar K [ Upstream commit e23ac1095b9eb8ac48f98c398d81d6ba062c9b5d ] While performing RSS based on IPv6, extension ltype is not being considered. This will be problem for fragmented packets or packets with extension header. Adding changes to match IPv6 ext header along with IPv6 ltype. Fixes: 41a7aa7b800d ("octeontx2-af: NIX Rx flowkey configuration for RSS") Signed-off-by: Kiran Kumar K Reviewed-by: Kalesh AP Signed-off-by: David S. Miller Signed-off-by: Sasha Levin --- drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c b/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c index 00af8888e3291..19fe3ed5c0ee6 100644 --- a/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c +++ b/drivers/net/ethernet/marvell/octeontx2/af/rvu_nix.c @@ -3864,6 +3864,9 @@ static int get_flowkey_alg_idx(struct nix_hw *nix_hw, u32 flow_cfg) return -ERANGE; } +/* Mask to match ipv6(NPC_LT_LC_IP6) and ipv6 ext(NPC_LT_LC_IP6_EXT) */ +#define NPC_LT_LC_IP6_MATCH_MSK ((~(NPC_LT_LC_IP6 ^ NPC_LT_LC_IP6_EXT)) & 0xf) + static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) { int idx, nr_field, key_off, field_marker, keyoff_marker; @@ -3990,7 +3993,7 @@ static int set_flowkey_fields(struct nix_rx_flowkey_alg *alg, u32 flow_cfg) field->bytesm1 = 15; /* DIP,16 bytes */ } } - field->ltype_mask = 0xF; /* Match only IPv6 */ + field->ltype_mask = NPC_LT_LC_IP6_MATCH_MSK; break; case NIX_FLOW_KEY_TYPE_TCP: case NIX_FLOW_KEY_TYPE_UDP: -- 2.43.0