From 7c902ec9688fc2a7612411f6c9db7b08d90f7c5b Mon Sep 17 00:00:00 2001 From: Larry Finger Date: Wed, 12 Nov 2014 11:18:04 -0600 Subject: [PATCH] rtl8188eu: Improve firmware loading diagnostics Signed-off-by: Larry Finger --- hal/rtl8188e_hal_init.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hal/rtl8188e_hal_init.c b/hal/rtl8188e_hal_init.c index b5324e0..f4ba1ce 100644 --- a/hal/rtl8188e_hal_init.c +++ b/hal/rtl8188e_hal_init.c @@ -588,7 +588,10 @@ static int load_firmware(struct rt_firmware *pFirmware, struct device *device) s32 rtStatus = _SUCCESS; const struct firmware *fw; const char *fw_name = "rtlwifi/rtl8188eufw.bin"; - if (request_firmware(&fw, fw_name, device)) { + int err = request_firmware(&fw, fw_name, device); + + if (err) { + pr_err("Request firmware failed with error 0x%x\n", err); rtStatus = _FAIL; goto Exit; } @@ -605,6 +608,7 @@ static int load_firmware(struct rt_firmware *pFirmware, struct device *device) pFirmware->szFwBuffer = kzalloc(FW_8188E_SIZE, GFP_KERNEL); if (!pFirmware->szFwBuffer) { + pr_err("Failed to allocate pFirmware->szFwBuffer\n"); rtStatus = _FAIL; goto Exit; }