Lines Matching refs:i
112 unsigned int i; in test_rht_lookup() local
114 for (i = 0; i < entries * 2; i++) { in test_rht_lookup()
116 bool expected = !(i % 2); in test_rht_lookup()
118 .id = i, in test_rht_lookup()
121 if (array[i / 2].value.id == TEST_INSERT_FAIL) in test_rht_lookup()
134 if (obj->value.id != i) { in test_rht_lookup()
136 obj->value.id, i); in test_rht_lookup()
193 unsigned int i, insert_retries = 0; in test_rhashtable() local
202 for (i = 0; i < entries; i++) { in test_rhashtable()
203 struct test_obj *obj = &array[i]; in test_rhashtable()
205 obj->value.id = i * 2; in test_rhashtable()
225 for (i = 0; i < entries; i++) { in test_rhashtable()
227 .id = i * 2, in test_rhashtable()
230 if (array[i].value.id != TEST_INSERT_FAIL) { in test_rhashtable()
250 int i, err = 0; in thread_lookup_test() local
252 for (i = 0; i < entries; i++) { in thread_lookup_test()
255 .id = i, in thread_lookup_test()
260 if (obj && (tdata->objs[i].value.id == TEST_INSERT_FAIL)) { in thread_lookup_test()
263 } else if (!obj && (tdata->objs[i].value.id != TEST_INSERT_FAIL)) { in thread_lookup_test()
279 int i, step, err = 0, insert_retries = 0; in threadfunc() local
286 for (i = 0; i < entries; i++) { in threadfunc()
287 tdata->objs[i].value.id = i; in threadfunc()
288 tdata->objs[i].value.tid = tdata->id; in threadfunc()
289 err = insert_retry(&ht, &tdata->objs[i].node, test_rht_params); in threadfunc()
310 for (i = 0; i < entries; i += step) { in threadfunc()
311 if (tdata->objs[i].value.id == TEST_INSERT_FAIL) in threadfunc()
313 err = rhashtable_remove_fast(&ht, &tdata->objs[i].node, in threadfunc()
320 tdata->objs[i].value.id = TEST_INSERT_FAIL; in threadfunc()
341 int i, err, started_threads = 0, failed_threads = 0; in test_rht_init() local
355 for (i = 0; i < runs; i++) { in test_rht_init()
358 pr_info("Test %02d:\n", i); in test_rht_init()
405 for (i = 0; i < tcount; i++) { in test_rht_init()
406 tdata[i].id = i; in test_rht_init()
407 tdata[i].objs = objs + i * entries; in test_rht_init()
408 tdata[i].task = kthread_run(threadfunc, &tdata[i], in test_rht_init()
409 "rhashtable_thrad[%d]", i); in test_rht_init()
410 if (IS_ERR(tdata[i].task)) in test_rht_init()
411 pr_err(" kthread_run failed for thread %d\n", i); in test_rht_init()
417 for (i = 0; i < tcount; i++) in test_rht_init()
419 for (i = 0; i < tcount; i++) { in test_rht_init()
420 if (IS_ERR(tdata[i].task)) in test_rht_init()
422 if ((err = kthread_stop(tdata[i].task))) { in test_rht_init()
424 i, err); in test_rht_init()