Lines Matching refs:vid_hdr
299 struct ubi_vid_hdr *vid_hdr; local
304 vid_hdr = ubi_zalloc_vid_hdr(ubi, GFP_KERNEL);
305 if (!vid_hdr)
315 vid_hdr->vol_type = UBI_LAYOUT_VOLUME_TYPE;
316 vid_hdr->vol_id = cpu_to_be32(UBI_LAYOUT_VOLUME_ID);
317 vid_hdr->compat = UBI_LAYOUT_VOLUME_COMPAT;
318 vid_hdr->data_size = vid_hdr->used_ebs =
319 vid_hdr->data_pad = cpu_to_be32(0);
320 vid_hdr->lnum = cpu_to_be32(copy);
321 vid_hdr->sqnum = cpu_to_be64(++ai->max_sqnum);
324 err = ubi_io_write_vid_hdr(ubi, new_aeb->pnum, vid_hdr);
337 err = ubi_add_to_av(ubi, ai, new_aeb->pnum, new_aeb->ec, vid_hdr, 0);
339 ubi_free_vid_hdr(ubi, vid_hdr);
353 ubi_free_vid_hdr(ubi, vid_hdr);