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 948AE45C9A; Thu, 7 Nov 2024 14:42:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id C5A8F42F1D; Thu, 7 Nov 2024 14:42:37 +0100 (CET) Received: from mail-pg1-f173.google.com (mail-pg1-f173.google.com [209.85.215.173]) by mails.dpdk.org (Postfix) with ESMTP id EED9342F09 for ; Thu, 7 Nov 2024 14:42:35 +0100 (CET) Received: by mail-pg1-f173.google.com with SMTP id 41be03b00d2f7-7eae96e6624so720073a12.2 for ; Thu, 07 Nov 2024 05:42:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1730986955; x=1731591755; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=hdZFHzhqZbUExHLoggJqJQeYouBHs2FoTqmotrk0U28=; b=bgEAwxjIwdBz4r4av8eX2BFldn0kApxjb9j8VTguFqDbDVxUkKvVmFOehc9hHNmEAv E8wKQjDI02LiBu+8e0F8q14KZ5OZ8t76oGCXJAdeQG0rUQZZV8pONPKDthKB2Av41v3q /d+99oqkfVi+FDp7GuJOFHD02tYu1r8eF1qFo= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1730986955; x=1731591755; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hdZFHzhqZbUExHLoggJqJQeYouBHs2FoTqmotrk0U28=; b=sPsgghfq/T7ceTWXt49t6RYchwx+U4fqdWgFNnlSGiX3UTudx61DJnKPphZCeV9iqV ZEetQjFcylWlpasD7ooQdnO5tscVW2Mukpl9kPjZpaFv0yPKS2p+MSGoWw/V8BlqUE11 5jPgbMRZzeYimkhoDnNqNAxfxdVao9Y7jjnoP3p3r/CSN+VV1ulJlDNVPe2JnLEEaC9F pcPCSDHPsn9+DC0kvI9lvjfXdg2N6aGFtuCq5dbkG9rTx4zrKR4CQmJctC2rw7XVophc N7dQdxv1QaH59/slSWW3+cV3GrCL0Ma2uALaNF+TJnOnaXSwl0+lUVzpBzL//qh4Lnia DxvQ== X-Gm-Message-State: AOJu0Yw2x/gT08h1bsSBthUFeJaLUmgVNAWQO8afdWkEQiBHF7doFrVu xZwjWNFqn3jIHM+HVfmxSuD5vRNB/RrZYcOcQ99lgwvpe9XtuuhnLpUhd83w8ngimCvlVlscmQI BEvscYP2WKZVDZqkwp/YK66o/9oCjEGAM0ib5sO05FwsnDLzIdofFG85yi2mGrSSAu7JfiOvBjW +yyDwwnryJyDWYw0wnK9uTRHbhqS7sKFAWBzVfxZEmxg== X-Google-Smtp-Source: AGHT+IH3pkHyTrphPvzaykQ21t7bePG37TK9dyA6PKRQzBywRY75ucV2vxmpylGbPazix3Wohlu6mA== X-Received: by 2002:a05:6a20:7f92:b0:1db:ed27:ea27 with SMTP id adf61e73a8af0-1dbed27f262mr15691683637.8.1730986954338; Thu, 07 Nov 2024 05:42:34 -0800 (PST) Received: from dhcp-10-123-154-23.dhcp.broadcom.net ([192.19.234.250]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2e9a5f52969sm1409878a91.2.2024.11.07.05.42.31 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Nov 2024 05:42:33 -0800 (PST) From: Sriharsha Basavapatna To: dev@dpdk.org Cc: Shahaji Bhosle , stable@dpdk.org, Sriharsha Basavapatna , Farah Smith , Kishore Padmanabha , Shuanglin Wang , Ajit Khaparde Subject: [PATCH v8 02/47] net/bnxt: tf_core: tcam manager data corruption Date: Thu, 7 Nov 2024 19:22:09 +0530 Message-Id: <20241107135254.1611676-3-sriharsha.basavapatna@broadcom.com> X-Mailer: git-send-email 2.39.0.189.g4dbebc36b0 In-Reply-To: <20241107135254.1611676-1-sriharsha.basavapatna@broadcom.com> References: <20241107135254.1611676-1-sriharsha.basavapatna@broadcom.com> 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 From: Shahaji Bhosle Max entries per session were not getting initialized to 0, when the sessions were closed. Reset max entries counter session when the session is initialized Fixes: 97435d7906d7 ("net/bnxt: update Truflow core") Cc: stable@dpdk.org Signed-off-by: Shahaji Bhosle Signed-off-by: Sriharsha Basavapatna Reviewed-by: Farah Smith Reviewed-by: Kishore Padmanabha Reviewed-by: Shuanglin Wang Reviewed-by: Ajit Khaparde --- drivers/net/bnxt/tf_core/cfa_tcam_mgr.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c b/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c index f26d93e7a9..9df2d2b937 100644 --- a/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c +++ b/drivers/net/bnxt/tf_core/cfa_tcam_mgr.c @@ -909,6 +909,7 @@ cfa_tcam_mgr_init(int sess_idx, enum cfa_tcam_mgr_device_type type, /* Now calculate the max entries per table and global max entries based * on the updated table limits. */ + cfa_tcam_mgr_max_entries[sess_idx] = 0; for (dir = 0; dir < ARRAY_SIZE(cfa_tcam_mgr_tables[sess_idx]); dir++) for (tbl_type = 0; tbl_type < ARRAY_SIZE(cfa_tcam_mgr_tables[sess_idx][dir]); @@ -958,8 +959,8 @@ cfa_tcam_mgr_init(int sess_idx, enum cfa_tcam_mgr_device_type type, if (parms != NULL) parms->max_entries = cfa_tcam_mgr_max_entries[sess_idx]; - CFA_TCAM_MGR_LOG(INFO, "Global TCAM table initialized for sess_idx %d.\n", - sess_idx); + CFA_TCAM_MGR_LOG(DEBUG, "Global TCAM table initialized for sess_idx %d max entries %d.\n", + sess_idx, cfa_tcam_mgr_max_entries[sess_idx]); return 0; } -- 2.39.3