Lines Matching refs:vtbl
76 err = ubi_eba_atomic_leb_change(ubi, layout_vol, i, ubi->vtbl, in ubi_update_layout_vol()
111 memcpy(&ubi->vtbl[idx], vtbl_rec, sizeof(struct ubi_vtbl_record)); in ubi_change_vtbl_record()
135 struct ubi_vtbl_record *vtbl_rec = &ubi->vtbl[vol->vol_id]; in ubi_vtbl_rename_volumes()
164 const struct ubi_vtbl_record *vtbl) argument
174 reserved_pebs = be32_to_cpu(vtbl[i].reserved_pebs);
175 alignment = be32_to_cpu(vtbl[i].alignment);
176 data_pad = be32_to_cpu(vtbl[i].data_pad);
177 upd_marker = vtbl[i].upd_marker;
178 vol_type = vtbl[i].vol_type;
179 name_len = be16_to_cpu(vtbl[i].name_len);
180 name = &vtbl[i].name[0];
182 crc = crc32(UBI_CRC32_INIT, &vtbl[i], UBI_VTBL_RECORD_SIZE_CRC);
183 if (be32_to_cpu(vtbl[i].crc) != crc) {
185 i, crc, be32_to_cpu(vtbl[i].crc));
186 ubi_dump_vtbl_record(&vtbl[i], i);
191 if (memcmp(&vtbl[i], &empty_vtbl_record,
259 int len1 = be16_to_cpu(vtbl[i].name_len);
260 int len2 = be16_to_cpu(vtbl[n].name_len);
264 !strncmp(vtbl[i].name, vtbl[n].name, len1)) {
266 !strncmp((char *)vtbl[i].name, vtbl[n].name, len1)) {
269 i, n, vtbl[i].name);
270 ubi_dump_vtbl_record(&vtbl[i], i);
271 ubi_dump_vtbl_record(&vtbl[n], n);
281 ubi_dump_vtbl_record(&vtbl[i], i);
296 int copy, void *vtbl) argument
329 err = ubi_io_write_data(ubi, vtbl, new_aeb->pnum, 0, ubi->vtbl_size);
495 struct ubi_vtbl_record *vtbl; local
497 vtbl = vzalloc(ubi->vtbl_size);
498 if (!vtbl)
502 memcpy(&vtbl[i], &empty_vtbl_record, UBI_VTBL_RECORD_SIZE);
507 err = create_vtbl(ubi, ai, i, vtbl);
509 vfree(vtbl);
514 return vtbl;
529 const struct ubi_vtbl_record *vtbl) argument
538 if (be32_to_cpu(vtbl[i].reserved_pebs) == 0)
545 vol->reserved_pebs = be32_to_cpu(vtbl[i].reserved_pebs);
546 vol->alignment = be32_to_cpu(vtbl[i].alignment);
547 vol->data_pad = be32_to_cpu(vtbl[i].data_pad);
548 vol->upd_marker = vtbl[i].upd_marker;
549 vol->vol_type = vtbl[i].vol_type == UBI_VID_DYNAMIC ?
551 vol->name_len = be16_to_cpu(vtbl[i].name_len);
553 memcpy(vol->name, vtbl[i].name, vol->name_len);
557 if (vtbl[i].flags & UBI_VTBL_AUTORESIZE_FLG) {
802 ubi->vtbl = create_empty_lvol(ubi, ai);
803 if (IS_ERR(ubi->vtbl))
804 return PTR_ERR(ubi->vtbl);
817 ubi->vtbl = process_lvol(ubi, ai, av);
818 if (IS_ERR(ubi->vtbl))
819 return PTR_ERR(ubi->vtbl);
828 err = init_volumes(ubi, ai, ubi->vtbl);
843 vfree(ubi->vtbl);
860 if (vtbl_check(ubi, ubi->vtbl)) {