Lines Matching refs:img
70 struct boot_img img; in main() local
77 if ((sizeof(img.header) % 32) != 0) { in main()
116 memset(&img, 0, sizeof(img)); in main()
134 count = read(fd_in, img.code, file_size); in main()
141 img.header.b_instruction = /* b instruction */ in main()
145 memcpy(img.header.magic, BOOT0_MAGIC, 8); /* no '0' termination */ in main()
146 img.header.length = in main()
148 img.header.b_instruction = cpu_to_le32(img.header.b_instruction); in main()
149 img.header.length = cpu_to_le32(img.header.length); in main()
151 memcpy(img.header.spl_signature, SPL_SIGNATURE, 3); /* "sunxi" marker */ in main()
152 img.header.spl_signature[3] = SPL_HEADER_VERSION; in main()
155 if (strlen(default_dt) + 1 <= sizeof(img.header.string_pool)) { in main()
156 strcpy((char *)img.header.string_pool, default_dt); in main()
157 img.header.dt_name_offset = in main()
166 gen_check_sum(&img.header); in main()
168 count = write(fd_out, &img, le32_to_cpu(img.header.length)); in main()
169 if (count != le32_to_cpu(img.header.length)) { in main()