[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20180321223430.21388-4-mcgrof@kernel.org>
Date: Wed, 21 Mar 2018 15:34:30 -0700
From: "Luis R. Rodriguez" <mcgrof@...nel.org>
To: gregkh@...uxfoundation.org
Cc: akpm@...ux-foundation.org, cantabile.desu@...il.com,
kubakici@...pl, linux-wireless@...r.kernel.org,
keescook@...omium.org, shuah@...nel.org, mfuzzey@...keon.com,
zohar@...ux.vnet.ibm.com, dhowells@...hat.com,
pali.rohar@...il.com, tiwai@...e.de, arend.vanspriel@...adcom.com,
zajec5@...il.com, nbroeking@...com, markivx@...eaurora.org,
broonie@...nel.org, dmitry.torokhov@...il.com, dwmw2@...radead.org,
torvalds@...ux-foundation.org, Abhay_Salunke@...l.com,
bjorn.andersson@...aro.org, jewalt@...innovations.com,
oneukum@...e.com, ast@...com, andresx7@...il.com,
linux-kernel@...r.kernel.org, linux-fsdevel@...r.kernel.org,
"Luis R. Rodriguez" <mcgrof@...nel.org>
Subject: [PATCH v4 3/3] mt7601u: use firmware_request_cache() to address cache on reboot
request_firmware_cache() will ensure the firmware is available on resume
from suspend if on reboot the device retains the firmware.
This optimization is in place given otherwise on reboot we have to
reload the firmware, the opmization saves us about max 1s, minimum 10ms.
Cantabile has reported back this fixes his woes with both suspend and
hibernation.
Reported-by: Cantabile <cantabile.desu@...il.com>
Tested-by: Cantabile <cantabile.desu@...il.com>
Signed-off-by: Luis R. Rodriguez <mcgrof@...nel.org>
---
drivers/net/wireless/mediatek/mt7601u/mcu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/mediatek/mt7601u/mcu.c b/drivers/net/wireless/mediatek/mt7601u/mcu.c
index d9d6fd7eff5e..61705f679856 100644
--- a/drivers/net/wireless/mediatek/mt7601u/mcu.c
+++ b/drivers/net/wireless/mediatek/mt7601u/mcu.c
@@ -420,7 +420,7 @@ static int mt7601u_load_firmware(struct mt7601u_dev *dev)
MT_USB_DMA_CFG_TX_BULK_EN));
if (firmware_running(dev))
- return 0;
+ return firmware_request_cache(dev->dev, MT7601U_FIRMWARE);
ret = request_firmware(&fw, MT7601U_FIRMWARE, dev->dev);
if (ret)
--
2.16.2
Powered by blists - more mailing lists