Lines Matching refs:section
417 struct ape_section_hdr_s *section) in ape_section_copy() argument
429 if (SECTION_IS_ZIPPED(section)) { in ape_section_copy()
430 work_buff_size = section->org_data_len + BUFFER_PADDING; in ape_section_copy()
439 SECTION_SRC_OFFSET(section)); in ape_section_copy()
441 section->zip_data_len, in ape_section_copy()
448 if (size < section->org_data_len) { in ape_section_copy()
451 section->org_data_len, size); in ape_section_copy()
456 src = (uintptr_t)bin_hdr + SECTION_SRC_OFFSET(section); in ape_section_copy()
459 size = section->org_data_len; in ape_section_copy()
461 if (section->flags_src_offset & SECTION_FLAGS_IS_CRC) { in ape_section_copy()
468 if (checksum != section->checksum) { in ape_section_copy()
470 section->checksum, checksum); in ape_section_copy()
474 dst = ape_host_view_addr_get(section->dest_addr, size); in ape_section_copy()
477 section->dest_addr); in ape_section_copy()
491 static int ape_section_zero(struct ape_section_hdr_s *section) in ape_section_zero() argument
494 uint32_t size = section->org_data_len; in ape_section_zero()
497 if (section->org_data_len == 0) in ape_section_zero()
501 dst = ape_host_view_addr_get(section->dest_addr, size); in ape_section_zero()
504 section->dest_addr); in ape_section_zero()
521 struct ape_section_hdr_s *section = NULL; in bnxt_load() local
526 section = (struct ape_section_hdr_s *)(img_buffer + in bnxt_load()
532 for (sidx = 0; sidx < bin_hdr->num_total_sections; sidx++, section++) { in bnxt_load()
533 if (!SECTION_IS_LOADABLE(section)) in bnxt_load()
536 if (!ADDR_IS_4BYTE_ALIGNED(section->dest_addr)) { in bnxt_load()
538 section->dest_addr); in bnxt_load()
543 if (!ADDR_IS_4BYTE_ALIGNED(SECTION_SRC_OFFSET(section))) { in bnxt_load()
545 SECTION_SRC_OFFSET(section)); in bnxt_load()
550 if (section->org_data_len % sizeof(uint32_t)) { in bnxt_load()
552 section->org_data_len); in bnxt_load()
557 if (SECTION_IS_TOBE_COPIED(section)) { in bnxt_load()
558 rc = ape_section_copy(bin_hdr, section); in bnxt_load()
561 } else if (SECTION_IS_TOBE_ZEROED(section)) { in bnxt_load()
562 rc = ape_section_zero(section); in bnxt_load()