Lines Matching refs:length
188 sgc->length, in build_flash_msg()
199 sgc->length); in build_flash_msg()
208 fc->curr_len = fc->sgc.length; in build_flash_msg()
219 fc->sgc.length = 0; in build_flash_msg()
272 esas2r_calc_byte_cksum((u8 *)pi, ch->length, 0); in fix_bios()
278 u32 len = ch->length; in fix_efi()
349 + ch->length /* end of the current image */ in fw_download_proc()
364 fc->sgc.length = FM_BUF_SZ; in fw_download_proc()
366 fc->sgc.length = fc->cmp_len; in fw_download_proc()
378 while (fc->sgc.length == 0) { in fw_download_proc()
385 if (ch->length == 0) in fw_download_proc()
392 fc->sgc.length = ch->length; in fw_download_proc()
405 fc->cmp_len = ch->length; in fw_download_proc()
406 fc->sgc.length = FM_BUF_SZ; in fw_download_proc()
422 if (ch->length == 0) in fw_download_proc()
429 + fi->cmp_hdr[CH_IT_BIOS].length; in fw_download_proc()
430 fc->sgc.length = ch->length; in fw_download_proc()
439 fc->flsh_addr -= ch->length; in fw_download_proc()
440 fc->cmp_len = ch->length; in fw_download_proc()
441 fc->sgc.length = FM_BUF_SZ; in fw_download_proc()
457 if (ch->length == 0) in fw_download_proc()
464 + fi->cmp_hdr[CH_IT_BIOS].length in fw_download_proc()
465 + fi->cmp_hdr[CH_IT_MAC].length; in fw_download_proc()
466 fc->sgc.length = ch->length; in fw_download_proc()
475 fc->flsh_addr -= ch->length; in fw_download_proc()
476 fc->cmp_len = ch->length; in fw_download_proc()
477 fc->sgc.length = FM_BUF_SZ; in fw_download_proc()
494 if (ch->length == 0) in fw_download_proc()
499 fc->flsh_addr = FLS_OFFSET_CPYR - ch->length; in fw_download_proc()
500 fc->sgc.length = ch->length; in fw_download_proc()
509 fc->flsh_addr = FLS_OFFSET_CPYR - ch->length; in fw_download_proc()
510 fc->cmp_len = ch->length; in fw_download_proc()
511 fc->sgc.length = FM_BUF_SZ; in fw_download_proc()
544 && fc->sgc.length > fc->cmp_len) in fw_download_proc()
545 fc->sgc.length = fc->cmp_len; in fw_download_proc()
587 static u32 chk_cfg(u8 *cfg, u32 length, u32 *flash_ver) in chk_cfg() argument
591 u32 len = length; in chk_cfg()
623 if (length && sz != length) in chk_cfg()
630 static u8 chk_boot(u8 *boot_img, u32 length) in chk_boot() argument
641 || ((u32)hdroffset + sizeof(struct esas2r_boot_header) > length)) in chk_boot()
671 for (len = (fi->length - fc->fi_hdr_len) / 2, in calc_fi_checksum()
703 len = fi->length; in verify_fi()
762 if (ch->length & 0x1ff) in verify_fi()
766 if (ch->length == 0) in verify_fi()
770 if (chk_boot((u8 *)fi + ch->image_offset, ch->length) in verify_fi()
779 if (ch->length == 0) { in verify_fi()
785 if (!chk_cfg((u8 *)fi + ch->image_offset + ch->length, in verify_fi()
786 ch->length, NULL)) in verify_fi()
802 len += ch->length; in verify_fi()
812 if (len != fi->length - fc->fi_hdr_len) { in verify_fi()
900 datalen = le32_to_cpu(fsc->length); in esas2r_process_fs_ioctl()
916 sgc->length = datalen; in esas2r_process_fs_ioctl()
1311 vrq->data.sge[0].length = in esas2r_nvram_write()
1432 if (ch->length) in esas2r_fm_api()
1438 if (ch->length) in esas2r_fm_api()
1456 fc->sgc.length = FLS_LENGTH_BOOT; in esas2r_fm_api()
1467 fi->length = fc->fi_hdr_len; in esas2r_fm_api()
1479 ch->length = 0; in esas2r_fm_api()