Lines Matching refs:leafno

66 static void dbSplit(dmtree_t * tp, int leafno, int splitsz, int newval);
67 static int dbBackSplit(dmtree_t * tp, int leafno);
68 static int dbJoin(dmtree_t * tp, int leafno, int newval);
69 static void dbAdjTree(dmtree_t * tp, int leafno, int newval);
2457 int rc, leafno, ti; in dbAdjCtl() local
2477 leafno = BLKTOCTLLEAF(blkno, dcp->budmin); in dbAdjCtl()
2478 ti = leafno + le32_to_cpu(dcp->leafidx); in dbAdjCtl()
2506 rc = dbBackSplit((dmtree_t *) dcp, leafno); in dbAdjCtl()
2513 dbSplit((dmtree_t *) dcp, leafno, dcp->budmin, newval); in dbAdjCtl()
2515 rc = dbJoin((dmtree_t *) dcp, leafno, newval); in dbAdjCtl()
2545 dbJoin((dmtree_t *) dcp, leafno, in dbAdjCtl()
2556 dcp, leafno); in dbAdjCtl()
2557 dbSplit((dmtree_t *) dcp, leafno, in dbAdjCtl()
2606 static void dbSplit(dmtree_t * tp, int leafno, int splitsz, int newval) in dbSplit() argument
2614 if (leaf[leafno] > tp->dmt_budmin) { in dbSplit()
2620 cursz = leaf[leafno] - 1; in dbSplit()
2628 dbAdjTree(tp, leafno ^ budsz, cursz); in dbSplit()
2640 dbAdjTree(tp, leafno, newval); in dbSplit()
2671 static int dbBackSplit(dmtree_t * tp, int leafno) in dbBackSplit() argument
2680 assert(leaf[leafno] == NOFREE); in dbBackSplit()
2690 LITOL2BSZ(leafno, le32_to_cpu(tp->dmt_l2nleafs), in dbBackSplit()
2701 while (leaf[leafno] == NOFREE) { in dbBackSplit()
2704 for (w = leafno, bsz = budsz;; bsz <<= 1, in dbBackSplit()
2728 if (leaf[leafno] != size) { in dbBackSplit()
2750 static int dbJoin(dmtree_t * tp, int leafno, int newval) in dbJoin() argument
2782 buddy = leafno ^ budsz; in dbJoin()
2802 if (leafno < buddy) { in dbJoin()
2810 dbAdjTree(tp, leafno, NOFREE); in dbJoin()
2811 leafno = buddy; in dbJoin()
2823 dbAdjTree(tp, leafno, newval); in dbJoin()
2844 static void dbAdjTree(dmtree_t * tp, int leafno, int newval) in dbAdjTree() argument
2851 lp = leafno + le32_to_cpu(tp->dmt_leafidx); in dbAdjTree()