Changeset 1b20da0 in mainline for kernel/test/cht
- Timestamp:
- 2018-02-28T17:52:03Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 3061bc1
- Parents:
- df6ded8
- git-author:
- Jiří Zárevúcky <zarevucky.jiri@…> (2018-02-28 17:26:03)
- git-committer:
- Jiří Zárevúcky <zarevucky.jiri@…> (2018-02-28 17:52:03)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
kernel/test/cht/cht1.c
rdf6ded8 r1b20da0 180 180 if (val->unique_id != v[0]->unique_id) 181 181 return "Found item with a different key."; 182 if (val->mark) 182 if (val->mark) 183 183 return "Found twice the same node."; 184 184 val->mark = true; … … 186 186 187 187 for (int i = 0; i < 3; ++i) { 188 if (!v[i]->mark) 188 if (!v[i]->mark) 189 189 return "Did not find all duplicates"; 190 190 … … 306 306 .equal = stress_equal, 307 307 .key_equal = stress_key_equal, 308 .remove_callback = stress_rm_callback 308 .remove_callback = stress_rm_callback 309 309 }; 310 310 … … 319 319 if (!s) { 320 320 TPRINTF("[out-of-mem]\n"); 321 goto out_of_mem; 321 goto out_of_mem; 322 322 } 323 323 … … 405 405 rcu_read_lock(); 406 406 cht_link_t *dup; 407 if (!cht_insert_unique(work->h, &work->elem[elem_idx].link, 407 if (!cht_insert_unique(work->h, &work->elem[elem_idx].link, 408 408 &dup)) { 409 409 TPRINTF("Err: already inserted\n"); … … 419 419 } else { 420 420 rcu_read_lock(); 421 cht_link_t *item = 421 cht_link_t *item = 422 422 cht_find(work->h, (void*)work->elem[elem_idx].key); 423 423 rcu_read_unlock(); … … 525 525 if (i < op_thread_cnt) 526 526 thr[i] = thread_create(op_stresser, &pwork[i], TASK, 0, "cht-op-stress"); 527 else 527 else 528 528 thr[i] = thread_create(resize_stresser, &pwork[i], TASK, 0, "cht-resize"); 529 529 … … 567 567 printf("Basic sanity test: ok.\n"); 568 568 569 if (!do_stress()) 569 if (!do_stress()) 570 570 return "CHT stress test failed."; 571 571 else
Note:
See TracChangeset
for help on using the changeset viewer.