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

Commit d51193d4 authored by Jahnavi Meher's avatar Jahnavi Meher Committed by John W. Linville
Browse files

rsi: Fixed warnings reported by static code analyzers.



Fixed a warning related to incorrect return type and removed an
unnecessary semi colon.

Signed-off-by: default avatarJahnavi Meher <jahnavi.meher@gmail.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 688df7ec
Loading
Loading
Loading
Loading
+7 −5
Original line number Original line Diff line number Diff line
@@ -92,6 +92,7 @@ static u32 rsi_get_num_pkts_dequeue(struct rsi_common *common, u8 q_num)
	struct sk_buff *skb;
	struct sk_buff *skb;
	u32 pkt_cnt = 0;
	u32 pkt_cnt = 0;
	s16 txop = common->tx_qinfo[q_num].txop * 32;
	s16 txop = common->tx_qinfo[q_num].txop * 32;
	__le16 r_txop;
	struct ieee80211_rate rate;
	struct ieee80211_rate rate;


	rate.bitrate = RSI_RATE_MCS0 * 5 * 10; /* Convert to Kbps */
	rate.bitrate = RSI_RATE_MCS0 * 5 * 10; /* Convert to Kbps */
@@ -104,10 +105,11 @@ static u32 rsi_get_num_pkts_dequeue(struct rsi_common *common, u8 q_num)
		return 0;
		return 0;


	do {
	do {
		txop -= ieee80211_generic_frame_duration(adapter->hw,
		r_txop = ieee80211_generic_frame_duration(adapter->hw,
							  adapter->vifs[0],
							  adapter->vifs[0],
							  common->band,
							  common->band,
							  skb->len, &rate);
							  skb->len, &rate);
		txop -= le16_to_cpu(r_txop);
		pkt_cnt += 1;
		pkt_cnt += 1;
		/*checking if pkts are still there*/
		/*checking if pkts are still there*/
		if (skb_queue_len(&common->tx_queue[q_num]) - pkt_cnt)
		if (skb_queue_len(&common->tx_queue[q_num]) - pkt_cnt)
@@ -191,7 +193,7 @@ static u8 rsi_core_determine_hal_queue(struct rsi_common *common)
	if (q_num == VO_Q || q_num == VI_Q) {
	if (q_num == VO_Q || q_num == VI_Q) {
		common->pkt_cnt = rsi_get_num_pkts_dequeue(common, q_num);
		common->pkt_cnt = rsi_get_num_pkts_dequeue(common, q_num);
		common->pkt_cnt -= 1;
		common->pkt_cnt -= 1;
	};
	}


	return q_num;
	return q_num;
}
}