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

Commit 66618bad authored by Kenji Kaneshige's avatar Kenji Kaneshige Committed by Jesse Barnes
Browse files

pciehp: change command polling frequency



Change command polling frequency to 100Hz from 10Hz in order to reduce
the delay in the common case of a command completing quickly.

Signed-off-by: default avatarKenji Kaneshige <kaneshige.kenji@jp.fujitsu.com>
Signed-off-by: default avatarJesse Barnes <jbarnes@virtuousgeek.org>
parent 820943b6
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -259,8 +259,8 @@ static inline int pcie_poll_cmd(struct controller *ctrl)
		}
		}
	}
	}
	while (timeout > 1000) {
	while (timeout > 1000) {
		msleep(100);
		msleep(10);
		timeout -= 100;
		timeout -= 10;
		if (!pciehp_readw(ctrl, SLOTSTATUS, &slot_status)) {
		if (!pciehp_readw(ctrl, SLOTSTATUS, &slot_status)) {
			if (slot_status & CMD_COMPLETED) {
			if (slot_status & CMD_COMPLETED) {
				pciehp_writew(ctrl, SLOTSTATUS, CMD_COMPLETED);
				pciehp_writew(ctrl, SLOTSTATUS, CMD_COMPLETED);