Lines Matching refs:index

89 	s16 index;  member
159 int index; in xtLookup() local
194 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtLookup()
206 xad = &p->xad[index]; in xtLookup()
257 int index; in xtLookupList() local
297 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtLookupList()
300 if (index == le16_to_cpu(p->header.nextindex)) { in xtLookupList()
314 index = XTENTRYSTART; in xtLookupList()
317 xad = &p->xad[index]; in xtLookupList()
383 if (index == le16_to_cpu(p->header.nextindex) - 1) { in xtLookupList()
390 index++; in xtLookupList()
444 if (index == le16_to_cpu(p->header.nextindex) - 1) { in xtLookupList()
458 index = XTENTRYSTART; in xtLookupList()
459 xad = &p->xad[index]; in xtLookupList()
461 index++; in xtLookupList()
509 int base, index, lim, btindex; in xtSearch() local
551 (index = jfs_ip->btindex) < in xtSearch()
553 xad = &p->xad[index]; in xtSearch()
566 index++; in xtSearch()
567 if (index < in xtSearch()
619 btsp->index = index; in xtSearch()
623 jfs_ip->btindex = index; in xtSearch()
637 index = base + (lim >> 1); in xtSearch()
639 XT_CMP(cmp, xoff, &p->xad[index], t64); in xtSearch()
663 btsp->index = index; in xtSearch()
668 if (index == btindex || in xtSearch()
669 index == btindex + 1) in xtSearch()
673 jfs_ip->btindex = index; in xtSearch()
685 base = index + 1; in xtSearch()
718 btsp->index = base; in xtSearch()
738 index = base ? base - 1 : base; in xtSearch()
751 BT_PUSH(btstack, bn, index); in xtSearch()
754 bn = addressXAD(&p->xad[index]); in xtSearch()
790 int index, nextindex; in xtInsert() local
812 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtInsert()
827 if (index > XTENTRYSTART) { in xtInsert()
828 xad = &p->xad[index - 1]; in xtInsert()
850 split.index = index; in xtInsert()
878 if (index < nextindex) in xtInsert()
879 memmove(&p->xad[index + 1], &p->xad[index], in xtInsert()
880 (nextindex - index) * sizeof(xad_t)); in xtInsert()
883 xad = &p->xad[index]; in xtInsert()
895 (xtlck->lwm.offset) ? min(index, in xtInsert()
896 (int)xtlck->lwm.offset) : index; in xtInsert()
967 skip = split->index; in xtSplitUp()
1083 skip = parent->index + 1; in xtSplitUp()
1095 split->index = skip; /* index at insert */ in xtSplitUp()
1271 skip = split->index; in xtSplitPage()
1512 skip = split->index; in xtSplitRoot()
1591 int index, nextindex, len; in xtExtend() local
1606 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtExtend()
1615 xad = &p->xad[index]; in xtExtend()
1655 split.index = index + 1; in xtExtend()
1697 xad = &p->xad[index + 1]; in xtExtend()
1706 xad = &p->xad[index]; in xtExtend()
1719 (xtlck->lwm.offset) ? min(index, in xtExtend()
1720 (int)xtlck->lwm.offset) : index; in xtExtend()
1755 int index, nextindex, llen, rlen; in xtTailgate() local
1774 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtTailgate()
1784 if (index != nextindex - 1) { in xtTailgate()
1801 xad = &p->xad[index]; in xtTailgate()
1822 split.index = index + 1; in xtTailgate()
1864 xad = &p->xad[index + 1]; in xtTailgate()
1873 xad = &p->xad[index]; in xtTailgate()
1889 pxdlock->index = 1; in xtTailgate()
1904 min(index, (int)xtlck->lwm.offset) : index; in xtTailgate()
1936 int index0, index, newindex, nextindex; in xtUpdate() local
1989 index = index0; in xtUpdate()
1990 newindex = index + 1; in xtUpdate()
2020 if (index == XTENTRYSTART) in xtUpdate()
2024 lxad = &p->xad[index - 1]; in xtUpdate()
2031 index0 = index - 1; in xtUpdate()
2051 if (index < nextindex - 1) in xtUpdate()
2052 memmove(&p->xad[index], &p->xad[index + 1], in xtUpdate()
2053 (nextindex - index - in xtUpdate()
2060 index = index0; in xtUpdate()
2061 newindex = index + 1; in xtUpdate()
2095 rxad = &p->xad[index + 1]; in xtUpdate()
2120 memmove(&p->xad[index], &p->xad[index + 1], in xtUpdate()
2121 (nextindex - index - 1) << L2XTSLOTSIZE); in xtUpdate()
2148 xad = &p->xad[index]; in xtUpdate()
2156 split.index = newindex; in xtUpdate()
2253 index0 = index = newindex; in xtUpdate()
2255 index++; in xtUpdate()
2257 newindex = index + 1; in xtUpdate()
2279 if (index0 != index) { in xtUpdate()
2296 xad = &p->xad[index]; in xtUpdate()
2310 split.index = newindex; in xtUpdate()
2404 int index, nextindex; in xtAppend() local
2432 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtAppend()
2486 split.index = index; in xtAppend()
2522 xad = &p->xad[index]; in xtAppend()
2530 (xtlck->lwm.offset) ? min(index,(int) xtlck->lwm.offset) : index; in xtAppend()
2569 int index, nextindex; in xtDelete() local
2579 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtDelete()
2608 (xtlck->lwm.offset) ? min(index, xtlck->lwm.offset) : index; in xtDelete()
2611 if (index < nextindex - 1) in xtDelete()
2612 memmove(&p->xad[index], &p->xad[index + 1], in xtDelete()
2613 (nextindex - index - 1) * sizeof(xad_t)); in xtDelete()
2639 int index, nextindex; in xtDeleteUp() local
2690 index = parent->index; in xtDeleteUp()
2742 (xtlck->lwm.offset) ? min(index, in xtDeleteUp()
2744 offset) : index; in xtDeleteUp()
2749 if (index < nextindex - 1) in xtDeleteUp()
2750 memmove(&p->xad[index], &p->xad[index + 1], in xtDeleteUp()
2751 (nextindex - index - in xtDeleteUp()
2758 (ulong) parent->bn, index); in xtDeleteUp()
2804 int index; in xtRelocate() local
2833 XT_GETSEARCH(ip, btstack.top, bn, pmp, pp, index); in xtRelocate()
2841 xad = &pp->xad[index]; in xtRelocate()
2854 XT_GETSEARCH(ip, btstack.top, bn, pmp, pp, index); in xtRelocate()
2863 xad = &pp->xad[index]; in xtRelocate()
2937 XT_GETSEARCH(ip, btstack.top, bn, pmp, pp, index); in xtRelocate()
3070 pxdlock->index = 1; in xtRelocate()
3085 xad = &pp->xad[index]; in xtRelocate()
3089 xtlck->lwm.offset = min(index, xtlck->lwm.offset); in xtRelocate()
3128 int base, index, lim; in xtSearchNode() local
3170 index = base + (lim >> 1); in xtSearchNode()
3172 XT_CMP(cmp, xoff, &p->xad[index], t64); in xtSearchNode()
3179 if (xaddr == addressXAD(&p->xad[index]) && in xtSearchNode()
3180 xoff == offsetXAD(&p->xad[index])) { in xtSearchNode()
3186 btsp->index = index; in xtSearchNode()
3197 base = index + 1; in xtSearchNode()
3210 index = base ? base - 1 : base; in xtSearchNode()
3217 bn = addressXAD(&p->xad[index]); in xtSearchNode()
3396 int index, nextindex; in xtTruncate() local
3427 xadlock.index = 1; in xtTruncate()
3477 index = le16_to_cpu(p->header.nextindex) - 1; in xtTruncate()
3505 xad = &p->xad[index]; in xtTruncate()
3534 for (; index >= XTENTRYSTART; index--) { in xtTruncate()
3535 xad = &p->xad[index]; in xtTruncate()
3573 if (index == XTENTRYSTART) in xtTruncate()
3576 nextindex = index; in xtTruncate()
3594 min(index, (int)xtlck->lwm.offset) : index; in xtTruncate()
3595 xtlck->lwm.length = index + 1 - in xtTruncate()
3597 xtlck->twm.offset = index; in xtTruncate()
3617 nextindex = index + 1; in xtTruncate()
3629 nextindex = index + 1; in xtTruncate()
3714 index = parent->index; in xtTruncate()
3721 if (index < le16_to_cpu(p->header.nextindex) - 1) { in xtTruncate()
3739 xadlock.xdlist = &p->xad[index + 1]; in xtTruncate()
3742 index - 1; in xtTruncate()
3748 p->header.nextindex = cpu_to_le16(index + 1); in xtTruncate()
3757 nfreed += lengthXAD(&p->xad[index]); in xtTruncate()
3797 if (index == XTENTRYSTART) { in xtTruncate()
3865 index--; in xtTruncate()
3878 BT_PUSH(&btstack, bn, index); in xtTruncate()
3881 xad = &p->xad[index]; in xtTruncate()
3945 int index; in xtTruncate_pmap() local
3971 XT_GETSEARCH(ip, btstack.top, bn, mp, p, index); in xtTruncate_pmap()
3996 index = le16_to_cpu(p->header.nextindex) - 1; in xtTruncate_pmap()
4011 xad = &p->xad[index]; in xtTruncate_pmap()
4020 xtlck->hwm.offset = index; in xtTruncate_pmap()
4040 index = parent->index; in xtTruncate_pmap()
4045 if (index == XTENTRYSTART) { in xtTruncate_pmap()
4069 index--; in xtTruncate_pmap()
4075 BT_PUSH(&btstack, bn, index); in xtTruncate_pmap()
4078 xad = &p->xad[index]; in xtTruncate_pmap()
4108 int index, lastindex, v, h; in xtDisplayTree() local
4136 index = XTENTRYSTART; in xtDisplayTree()
4168 if ((index = parent->index) == (lastindex = parent->lastindex)) { in xtDisplayTree()
4184 index++; in xtDisplayTree()
4192 btsp->index = index; in xtDisplayTree()
4199 xad = &p->xad[index]; in xtDisplayTree()
4208 printk("traverse down 0x%lx[%d]->0x%lx\n", (ulong) pbn, index, in xtDisplayTree()
4211 h = index; in xtDisplayTree()
4275 int index; in xtGather() local
4304 index = le16_to_cpu(p->header.nextindex) - 1; in xtGather()
4311 for (; index >= XTENTRYSTART; index--) { in xtGather()
4312 e = &p->xad[index]; in xtGather()
4342 if ((index = parent->index) == XTENTRYSTART) { in xtGather()
4370 index--; in xtGather()
4383 BT_PUSH(&btstack, bn, index); in xtGather()
4386 e = &p->xad[index]; in xtGather()