Changeset d7768d11 in mainline for uspace/srv/bd/hr/superblock.c
- Timestamp:
- 2024-12-06T19:46:43Z (10 months ago)
- Children:
- 241c3f6
- Parents:
- 586b39d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/bd/hr/superblock.c
r586b39d rd7768d11 153 153 154 154 metadata->magic = host2uint64_t_le(HR_MAGIC); 155 metadata->version = host2uint32_t_le(~(0U)); /* unused */ 155 156 metadata->extent_no = host2uint32_t_le(vol->extent_no); 157 /* index filled separately for each extent */ 156 158 metadata->level = host2uint32_t_le(vol->level); 159 metadata->layout = host2uint32_t_le(vol->RLQ); 160 metadata->strip_size = host2uint32_t_le(vol->strip_size); 157 161 metadata->nblocks = host2uint64_t_le(vol->nblocks); 158 162 metadata->data_blkno = host2uint64_t_le(vol->data_blkno); 159 metadata->data_offset = host2uint 32_t_le(vol->data_offset);160 metadata-> strip_size = host2uint32_t_le(vol->strip_size);161 163 metadata->data_offset = host2uint64_t_le(vol->data_offset); 164 metadata->counter = host2uint64_t_le(~(0UL)); /* unused */ 165 /* UUID generated separately for each extent */ 162 166 str_cpy(metadata->devname, HR_DEVNAME_LEN, vol->devname); 163 167 … … 231 235 } 232 236 237 /* TODO: handle version */ 233 238 vol->level = uint32_t_le2host(metadata->level); 239 vol->RLQ = (uint8_t)uint32_t_le2host(metadata->layout); 240 vol->strip_size = uint32_t_le2host(metadata->strip_size); 234 241 vol->nblocks = uint64_t_le2host(metadata->nblocks); 235 242 vol->data_blkno = uint64_t_le2host(metadata->data_blkno); 236 vol->data_offset = uint 32_t_le2host(metadata->data_offset);237 vol-> strip_size = uint32_t_le2host(metadata->strip_size);243 vol->data_offset = uint64_t_le2host(metadata->data_offset); 244 vol->counter = uint64_t_le2host(0x00); /* unused */ 238 245 239 246 if (str_cmp(metadata->devname, vol->devname) != 0) {
Note:
See TracChangeset
for help on using the changeset viewer.