Lines Matching full:ab
10 static int ath12k_fw_request_firmware_api_n(struct ath12k_base *ab, in ath12k_fw_request_firmware_api_n() argument
19 ab->fw.fw = ath12k_core_firmware_request(ab, name); in ath12k_fw_request_firmware_api_n()
20 if (IS_ERR(ab->fw.fw)) { in ath12k_fw_request_firmware_api_n()
21 ret = PTR_ERR(ab->fw.fw); in ath12k_fw_request_firmware_api_n()
22 ath12k_dbg(ab, ATH12K_DBG_BOOT, "failed to load %s: %d\n", name, ret); in ath12k_fw_request_firmware_api_n()
23 ab->fw.fw = NULL; in ath12k_fw_request_firmware_api_n()
27 data = ab->fw.fw->data; in ath12k_fw_request_firmware_api_n()
28 len = ab->fw.fw->size; in ath12k_fw_request_firmware_api_n()
34 ath12k_err(ab, "firmware image too small to contain magic: %zu\n", in ath12k_fw_request_firmware_api_n()
41 ath12k_err(ab, "Invalid firmware magic\n"); in ath12k_fw_request_firmware_api_n()
51 ath12k_err(ab, "No space for padding after magic\n"); in ath12k_fw_request_firmware_api_n()
70 ath12k_err(ab, "Invalid length for FW IE %d (%zu < %zu)\n", in ath12k_fw_request_firmware_api_n()
83 ath12k_dbg(ab, ATH12K_DBG_BOOT, "found fw timestamp %d\n", in ath12k_fw_request_firmware_api_n()
87 ath12k_dbg(ab, ATH12K_DBG_BOOT, in ath12k_fw_request_firmware_api_n()
99 __set_bit(i, ab->fw.fw_features); in ath12k_fw_request_firmware_api_n()
102 ath12k_dbg_dump(ab, ATH12K_DBG_BOOT, "features", "", in ath12k_fw_request_firmware_api_n()
103 ab->fw.fw_features, in ath12k_fw_request_firmware_api_n()
104 sizeof(ab->fw.fw_features)); in ath12k_fw_request_firmware_api_n()
107 ath12k_dbg(ab, ATH12K_DBG_BOOT, in ath12k_fw_request_firmware_api_n()
111 ab->fw.amss_data = data; in ath12k_fw_request_firmware_api_n()
112 ab->fw.amss_len = ie_len; in ath12k_fw_request_firmware_api_n()
115 ath12k_dbg(ab, ATH12K_DBG_BOOT, in ath12k_fw_request_firmware_api_n()
119 ab->fw.m3_data = data; in ath12k_fw_request_firmware_api_n()
120 ab->fw.m3_len = ie_len; in ath12k_fw_request_firmware_api_n()
123 ath12k_dbg(ab, ATH12K_DBG_BOOT, in ath12k_fw_request_firmware_api_n()
126 ab->fw.amss_dualmac_data = data; in ath12k_fw_request_firmware_api_n()
127 ab->fw.amss_dualmac_len = ie_len; in ath12k_fw_request_firmware_api_n()
130 ath12k_warn(ab, "Unknown FW IE: %u\n", ie_id); in ath12k_fw_request_firmware_api_n()
148 release_firmware(ab->fw.fw); in ath12k_fw_request_firmware_api_n()
149 ab->fw.fw = NULL; in ath12k_fw_request_firmware_api_n()
153 void ath12k_fw_map(struct ath12k_base *ab) in ath12k_fw_map() argument
157 ret = ath12k_fw_request_firmware_api_n(ab, ATH12K_FW_API2_FILE); in ath12k_fw_map()
159 ab->fw.api_version = 2; in ath12k_fw_map()
161 ab->fw.api_version = 1; in ath12k_fw_map()
163 ath12k_dbg(ab, ATH12K_DBG_BOOT, "using fw api %d\n", in ath12k_fw_map()
164 ab->fw.api_version); in ath12k_fw_map()
167 void ath12k_fw_unmap(struct ath12k_base *ab) in ath12k_fw_unmap() argument
169 release_firmware(ab->fw.fw); in ath12k_fw_unmap()
170 memset(&ab->fw, 0, sizeof(ab->fw)); in ath12k_fw_unmap()