• Home
  • Raw
  • Download

Lines Matching refs:hint

108 			      unsigned int hint, bool wrap)  in __sbitmap_get_word()  argument
110 unsigned int orig_hint = hint; in __sbitmap_get_word()
114 nr = find_next_zero_bit(word, depth, hint); in __sbitmap_get_word()
121 if (orig_hint && hint && wrap) { in __sbitmap_get_word()
122 hint = orig_hint = 0; in __sbitmap_get_word()
131 hint = nr + 1; in __sbitmap_get_word()
132 if (hint >= depth - 1) in __sbitmap_get_word()
133 hint = 0; in __sbitmap_get_word()
440 unsigned int hint, depth; in __sbitmap_queue_get() local
443 hint = this_cpu_read(*sbq->alloc_hint); in __sbitmap_queue_get()
445 if (unlikely(hint >= depth)) { in __sbitmap_queue_get()
446 hint = depth ? prandom_u32() % depth : 0; in __sbitmap_queue_get()
447 this_cpu_write(*sbq->alloc_hint, hint); in __sbitmap_queue_get()
449 nr = sbitmap_get(&sbq->sb, hint, sbq->round_robin); in __sbitmap_queue_get()
454 } else if (nr == hint || unlikely(sbq->round_robin)) { in __sbitmap_queue_get()
456 hint = nr + 1; in __sbitmap_queue_get()
457 if (hint >= depth - 1) in __sbitmap_queue_get()
458 hint = 0; in __sbitmap_queue_get()
459 this_cpu_write(*sbq->alloc_hint, hint); in __sbitmap_queue_get()
469 unsigned int hint, depth; in __sbitmap_queue_get_shallow() local
474 hint = this_cpu_read(*sbq->alloc_hint); in __sbitmap_queue_get_shallow()
476 if (unlikely(hint >= depth)) { in __sbitmap_queue_get_shallow()
477 hint = depth ? prandom_u32() % depth : 0; in __sbitmap_queue_get_shallow()
478 this_cpu_write(*sbq->alloc_hint, hint); in __sbitmap_queue_get_shallow()
480 nr = sbitmap_get_shallow(&sbq->sb, hint, shallow_depth); in __sbitmap_queue_get_shallow()
485 } else if (nr == hint || unlikely(sbq->round_robin)) { in __sbitmap_queue_get_shallow()
487 hint = nr + 1; in __sbitmap_queue_get_shallow()
488 if (hint >= depth - 1) in __sbitmap_queue_get_shallow()
489 hint = 0; in __sbitmap_queue_get_shallow()
490 this_cpu_write(*sbq->alloc_hint, hint); in __sbitmap_queue_get_shallow()