Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f1465d88 authored by Vulupala Shashank Reddy's avatar Vulupala Shashank Reddy Committed by nshrivas
Browse files

qcacld-3.0: Tx Power included instead of Ack RSSI in Radio tap header

For virtual mon interface RSSI in Radio tap header is filled with Tx
power. The RSSI is normalized with Noise Floor (-96), which is not
required for TPC value, so add Normalized Noise Floor (96).

Change-Id: Ic8c35a93d8c121527058bc1dd265e24952c92b73
CRs-Fixed: 2555934
parent 3f2f0f5b
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -115,6 +115,8 @@ enum dpt_set_param_debugfs {
#define OL_TXRX_PEER_DEC_REF_CNT_SILENT(peer) \
	qdf_atomic_dec(&peer->ref_cnt)

#define NORMALIZED_TO_NOISE_FLOOR (-96)

ol_txrx_peer_handle
ol_txrx_peer_find_by_local_id_inc_ref(struct ol_txrx_pdev_t *pdev,
			      uint8_t local_peer_id);
@@ -5858,7 +5860,11 @@ ol_txrx_update_tx_status(struct ol_txrx_pdev_t *pdev,
		IEEE80211_CHAN_2GHZ : IEEE80211_CHAN_5GHZ);

	tx_status->chan_flags = channel_flags;
	tx_status->ant_signal_db = mon_hdr->rssi_comb;
	/* RSSI is filled with TPC which will be normalized
	 * during radiotap updation, so add 96 here
	 */
	tx_status->ant_signal_db =
				mon_hdr->rssi_comb - NORMALIZED_TO_NOISE_FLOOR;
	tx_status->tx_status = mon_hdr->status;
	tx_status->add_rtap_ext = true;
	tx_status->tx_retry_cnt = mon_hdr->tx_retry_cnt;
+4 −5
Original line number Diff line number Diff line
@@ -2777,6 +2777,7 @@ static const char *wma_get_status_str(uint32_t status)

#define RATE_LIMIT 16
#define RESERVE_BYTES   100
#define NORMALIZED_TO_NOISE_FLOOR (-96)

/**
 * wma_process_mon_mgmt_tx_data(): process management tx packets
@@ -2875,12 +2876,10 @@ wma_process_mon_mgmt_tx_data(wmi_mgmt_hdr *hdr,
	txrx_status.chan_freq = hdr->chan_freq;
	/* hdr->rate is in Kbps, convert into Mbps */
	txrx_status.rate = (hdr->rate_kbps / 1000);
	txrx_status.ant_signal_db = hdr->rssi;
	/* RSSI -128 is invalid rssi for TX, add 96 here,
	 * will be normalized during radiotap updation
	/* RSSI is filled with TPC which will be normalized
	 * during radiotap updation, so add 96 here
	 */
	if (txrx_status.ant_signal_db == -128)
		txrx_status.ant_signal_db += 96;
	txrx_status.ant_signal_db = hdr->rssi - NORMALIZED_TO_NOISE_FLOOR;

	txrx_status.nr_ant = 1;
	txrx_status.rtap_flags |=