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

Commit 16763478 authored by Ivo van Doorn's avatar Ivo van Doorn Committed by John W. Linville
Browse files

rt2x00: Reduce tx status reading timeout



When no TX status was available, the default timeout
of 20ms is a bit high. The frame is highly likely already
send out, so the TX status should be available within
only a few milliseconds.

Signed-off-by: default avatarIvo van Doorn <IvDoorn@gmail.com>
Acked-by: default avatarGertjan van Wingerde <gwingerde@gmail.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent 816c04fe
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -134,7 +134,7 @@ static void rt2800usb_tx_sta_fifo_read_completed(struct rt2x00_dev *rt2x00dev,
	} else if (!kfifo_is_empty(&rt2x00dev->txstatus_fifo)) {
		queue_work(rt2x00dev->workqueue, &rt2x00dev->txdone_work);
	} else if (rt2800usb_txstatus_pending(rt2x00dev)) {
		mod_timer(&rt2x00dev->txstatus_timer, jiffies + msecs_to_jiffies(20));
		mod_timer(&rt2x00dev->txstatus_timer, jiffies + msecs_to_jiffies(2));
	}
}

@@ -493,7 +493,7 @@ static void rt2800usb_work_txdone(struct work_struct *work)
	 * also delayed -> use a timer to retrieve it.
	 */
	if (rt2800usb_txstatus_pending(rt2x00dev))
		mod_timer(&rt2x00dev->txstatus_timer, jiffies + msecs_to_jiffies(20));
		mod_timer(&rt2x00dev->txstatus_timer, jiffies + msecs_to_jiffies(2));
}

/*