Lines Matching defs:bufpos
327 static int next_zero(struct ALLOC_CONTEXT *alctx, s32 bufpos, s32 count)
333 while ((index < 0) && (bufpos < count)) {
334 q = alctx->buf[bufpos >> 3];
336 bufpos = (bufpos | 7) + 1;
338 b = bufpos & 7;
343 index = (bufpos & -8) | b;
345 bufpos = (bufpos | 7) + 1;
359 static int next_one(struct ALLOC_CONTEXT *alctx, s32 bufpos, s32 count)
365 while ((index < 0) && (bufpos < count)) {
366 q = alctx->buf[bufpos >> 3];
368 bufpos = (bufpos | 7) + 1;
370 b = bufpos & 7;
375 index = (bufpos & -8) | b;
377 bufpos = (bufpos | 7) + 1;
514 s32 bufpos; /* bit index in buf */
517 bufpos = pos & ((alctx->vol->cluster_size << 3) - 1);
518 offbuf = pos - bufpos;
519 while (bufpos < (br << 3)) {
522 index = next_zero(alctx, bufpos, br << 3);
526 bufpos = index;
528 bufpos = br << 3;
532 index = next_one(alctx, bufpos, br << 3);
536 bufpos = index;
539 bufpos = br << 3;
542 bufpos = br << 3;