Lines Matching defs:out_fd
801 int format_sec_ext(char *filename, FILE *out_fd)
961 written = fwrite(&header, sizeof(ext_header_t), 1, out_fd);
968 written = fwrite(&sec_ext, sizeof(sec_entry_t), 1, out_fd);
1360 int format_bin_ext(char *filename, FILE *out_fd)
1391 written = fwrite(&header, sizeof(ext_header_t), 1, out_fd);
1400 fputc(c, out_fd);
1404 fputc(0, out_fd);
1420 FILE *out_fd;
1423 out_fd = fopen(ext_filename, "wb");
1424 if (out_fd == NULL) {
1431 if (format_bin_ext(opts.bin_ext_file, out_fd)) {
1438 if (format_sec_ext(opts.sec_cfg_file, out_fd)) {
1446 fflush(out_fd);
1447 fclose(out_fd);
1471 uint8_t *image_buf, int image_size, FILE *out_fd)
1545 written = fwrite(buf, prolog_size, 1, out_fd);
1559 int write_boot_image(uint8_t *buf, uint32_t image_size, FILE *out_fd)
1563 written = fwrite(buf, image_size, 1, out_fd);
1580 FILE *out_fd = NULL;
1717 out_fd = fopen(out_file, "wb");
1718 if (out_fd == NULL) {
1724 ret = write_prolog(ext_cnt, ext_file, image_buf, image_size, out_fd);
1732 opts.sec_opts->enc_image_sz, out_fd);
1735 ret = write_boot_image(image_buf, image_size, out_fd);
1743 if (out_fd)
1744 fclose(out_fd);