Lines Matching full:img

74 #include "fw/img.h"
165 static void iwl_free_fw_img(struct iwl_drv *drv, struct fw_img *img) in iwl_free_fw_img() argument
168 for (i = 0; i < img->num_sec; i++) in iwl_free_fw_img()
169 iwl_free_fw_desc(drv, &img->sec[i]); in iwl_free_fw_img()
170 kfree(img->sec); in iwl_free_fw_img()
187 iwl_free_fw_img(drv, drv->fw.img + i); in iwl_dealloc_ucode()
291 struct fw_img_parsing img[IWL_UCODE_TYPE_MAX]; member
319 return &pieces->img[type].sec[sec]; in get_sec()
326 struct fw_img_parsing *img = &pieces->img[type]; in alloc_sec_data() local
329 size_t alloc_size = sizeof(*img->sec) * size; in alloc_sec_data()
331 if (img->sec && img->sec_counter >= size) in alloc_sec_data()
334 sec_memory = krealloc(img->sec, alloc_size, GFP_KERNEL); in alloc_sec_data()
338 img->sec = sec_memory; in alloc_sec_data()
339 img->sec_counter = size; in alloc_sec_data()
349 pieces->img[type].sec[sec].data = data; in set_sec_data()
359 pieces->img[type].sec[sec].size = size; in set_sec_size()
366 return pieces->img[type].sec[sec].size; in get_sec_size()
376 pieces->img[type].sec[sec].offset = offset; in set_sec_offset()
409 struct fw_img_parsing *img; in iwl_store_ucode_sec() local
419 img = &pieces->img[type]; in iwl_store_ucode_sec()
421 alloc_size = sizeof(*img->sec) * (img->sec_counter + 1); in iwl_store_ucode_sec()
422 sec = krealloc(img->sec, alloc_size, GFP_KERNEL); in iwl_store_ucode_sec()
425 img->sec = sec; in iwl_store_ucode_sec()
427 sec = &img->sec[img->sec_counter]; in iwl_store_ucode_sec()
433 ++img->sec_counter; in iwl_store_ucode_sec()
874 drv->fw.img[IWL_UCODE_REGULAR].is_dual_cpus = in iwl_parse_tlv_firmware()
876 drv->fw.img[IWL_UCODE_INIT].is_dual_cpus = in iwl_parse_tlv_firmware()
878 drv->fw.img[IWL_UCODE_WOWLAN].is_dual_cpus = in iwl_parse_tlv_firmware()
1067 drv->fw.img[IWL_UCODE_REGULAR].paging_mem_size = in iwl_parse_tlv_firmware()
1070 drv->fw.img[usniffer_img].paging_mem_size = in iwl_parse_tlv_firmware()
1237 sec = kcalloc(pieces->img[type].sec_counter, sizeof(*sec), GFP_KERNEL); in iwl_alloc_ucode()
1240 drv->fw.img[type].sec = sec; in iwl_alloc_ucode()
1241 drv->fw.img[type].num_sec = pieces->img[type].sec_counter; in iwl_alloc_ucode()
1243 for (i = 0; i < pieces->img[type].sec_counter; i++) in iwl_alloc_ucode()
1645 for (i = 0; i < ARRAY_SIZE(pieces->img); i++) in iwl_req_fw_callback()
1646 kfree(pieces->img[i].sec); in iwl_req_fw_callback()