Lines Matching defs:ex
311 efs_extent_lookup(struct efs_mount *emp, struct efs_extent *ex,
322 for (i = 0; i < ex->ex_length; i++) {
323 err = efs_bread(emp, ex->ex_bn + i, NULL, &bp);
350 struct efs_extent ex;
361 while ((ret = efs_extent_iterator_next(&exi, &ex)) == 0) {
362 if (efs_extent_lookup(emp, &ex, cn, ino) == 0) {
374 efs_dextent_to_extent(struct efs_dextent *dex, struct efs_extent *ex)
377 KASSERT(dex != NULL && ex != NULL);
379 ex->ex_magic = dex->ex_bytes[0];
380 ex->ex_bn = be32toh(dex->ex_words[0]) & 0x00ffffff;
381 ex->ex_length = dex->ex_bytes[4];
382 ex->ex_offset = be32toh(dex->ex_words[1]) & 0x00ffffff;
389 efs_extent_to_dextent(struct efs_extent *ex, struct efs_dextent *dex)
392 KASSERT(ex != NULL && dex != NULL);
393 KASSERT(ex->ex_magic == EFS_EXTENT_MAGIC);
394 KASSERT((ex->ex_bn & ~EFS_EXTENT_BN_MASK) == 0);
395 KASSERT((ex->ex_offset & ~EFS_EXTENT_OFFSET_MASK) == 0);
397 dex->ex_words[0] = htobe32(ex->ex_bn);
398 dex->ex_bytes[0] = ex->ex_magic;
399 dex->ex_words[1] = htobe32(ex->ex_offset);
400 dex->ex_bytes[4] = ex->ex_length;
415 struct efs_extent ex, ex2;
448 efs_dextent_to_extent(&eip->ei_di.di_extents[i], &ex);
450 offset = ex.ex_offset * EFS_BB_SIZE;
451 length = ex.ex_length * EFS_BB_SIZE;
471 efs_dextent_to_extent(&eip->ei_di.di_extents[0], &ex);
473 numinextents = ex.ex_offset;
475 EFS_DPRINTF(("efs_extent_iterator_init: bad ex.ex_offset\n"));
483 efs_dextent_to_extent(&eip->ei_di.di_extents[i], &ex);
485 err = efs_bread(emp, ex.ex_bn, NULL, &bp);
504 numextents = ex.ex_length * EFS_EXTENTS_PER_BB;
520 efs_dextent_to_extent(&eip->ei_di.di_extents[indir], &ex);
530 err = efs_bread(emp, ex.ex_bn + bboff, NULL, &bp);
579 struct efs_extent ex;
596 &eip->ei_di.di_extents[exi->exi_dnext], &ex);
602 ex.ex_bn + bboff, NULL, &bp);
616 if (bboff >= ex.ex_length) {