ap_set_rfeature: Support new argument CAPI BSS_Term_TSF for MBO

Signed-off-by: priyadharshini gowthaman <pgowtham@qti.qualcomm.com>
diff --git a/ap.c b/ap.c
index ebbe388..515e21c 100644
--- a/ap.c
+++ b/ap.c
@@ -6739,6 +6739,7 @@
 		dut->mbo_self_ap_tuple.ap_ne_class = -1;
 		dut->mbo_self_ap_tuple.ap_ne_pref = -1; /* Not set */
 		dut->mbo_self_ap_tuple.ap_ne_op_ch = -1;
+		dut->ap_btmreq_bss_term_tsf = 0;
 		dut->ap_assoc_delay = 0;
 	}
 
@@ -7505,7 +7506,6 @@
 	char buf[100];
 	const char *val;
 	int cand_list = 1;
-	int tsf = 2;
 
 	val = get_param(cmd, "Dest_MAC");
 	if (!val || parse_mac_address(dut, val, mac_addr) < 0) {
@@ -7542,12 +7542,13 @@
 		 mac_addr[4], mac_addr[5], cand_list, disassoc_timer,
 		 dut->ap_btmreq_disassoc_imnt,
 		 dut->ap_btmreq_term_bit,
-		 tsf,
+		 dut->ap_btmreq_bss_term_tsf,
 		 dut->ap_btmreq_bss_term_dur);
 	run_system(dut, buf);
 
 	if (dut->ap_btmreq_term_bit) {
-		inform_and_sleep(dut, 3);
+		if (dut->ap_btmreq_bss_term_tsf >= 2)
+			inform_and_sleep(dut, dut->ap_btmreq_bss_term_tsf - 2);
 		run_system_wrapper(
 			dut, "iwpriv %s kickmac %02x:%02x:%02x:%02x:%02x:%02x",
 			ifname,
@@ -8867,6 +8868,10 @@
 	if (val)
 		dut->ap_btmreq_bss_term_dur = atoi(val);
 
+	val = get_param(cmd, "BSS_Term_TSF");
+	if (val)
+		dut->ap_btmreq_bss_term_tsf = atoi(val);
+
 	return 1;
 }
 
diff --git a/sigma_dut.h b/sigma_dut.h
index 5242dcf..6d4314b 100644
--- a/sigma_dut.h
+++ b/sigma_dut.h
@@ -523,6 +523,7 @@
 	int ap_interface_5g;
 	int ap_interface_2g;
 	int ap_assoc_delay;
+	int ap_btmreq_bss_term_tsf;
 
 	struct mbo_pref_ap mbo_pref_aps[MBO_MAX_PREF_BSSIDS];
 	struct mbo_pref_ap mbo_self_ap_tuple;