[Bugfix][bug-view-1351]Fix nf_conntrack is full
Only Configure:No
Affected branch:master/INTEST_PM_SDK6.1_BASE
Affected module:unknow
Is it affected on both ZXIC and MTK:only ZXIC
Self-test:Yes
Change-Id: I250ab074601c2ce5f8c626eda50328ef38467b50
diff --git a/cap/zx297520v3/zxic_code/zxic_source/linux-5.10/net/core/fastproc/fast_common.c b/cap/zx297520v3/zxic_code/zxic_source/linux-5.10/net/core/fastproc/fast_common.c
index 80ad864..8db5811 100755
--- a/cap/zx297520v3/zxic_code/zxic_source/linux-5.10/net/core/fastproc/fast_common.c
+++ b/cap/zx297520v3/zxic_code/zxic_source/linux-5.10/net/core/fastproc/fast_common.c
@@ -729,7 +729,14 @@
spin_lock_bh(&fast_fw_spinlock);
entry->ct->fast_entry = NULL;
spin_unlock_bh(&fast_fw_spinlock);
- atomic_dec(&(entry->ct->ct_general.use));
+ //LYNQ_MODIFY_ZXW_BUG1351_CR2025052624A85E21_20250715_START
+ //atomic_dec(&(entry->ct->ct_general.use));
+ if (atomic_dec_and_test(&entry->ct->ct_general.use)){
+
+ nf_conntrack_destroy(&entry->ct->ct_general);
+
+ }
+ //LYNQ_MODIFY_ZXW_BUG1351_CR2025052624A85E21_20250715_END
fn_list_del(list_head, entry);
}
@@ -971,7 +978,14 @@
spin_lock_bh(&fast_fw_spinlock);
entry->ct->fast_entry = NULL;
spin_unlock_bh(&fast_fw_spinlock);
- atomic_dec(&(ct->ct_general.use));
+ //LYNQ_MODIFY_ZXW_BUG1351_CR2025052624A85E21_20250715_START
+ //atomic_dec(&(ct->ct_general.use));
+ if (atomic_dec_and_test(&ct->ct_general.use)){
+
+ nf_conntrack_destroy(&ct->ct_general);
+
+ }
+ //LYNQ_MODIFY_ZXW_BUG1351_CR2025052624A85E21_20250715_END
del_timer(&entry->timeout);
fn_list_del(entry->list_head, entry);
return 0;