Changeset 205832b in mainline for kernel/test/synch/rcu1.c


Ignore:
Timestamp:
2012-11-05T15:37:39Z (13 years ago)
Author:
Adam Hraska <adam.hraska+hos@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
f048658
Parents:
6b99156
Message:

Replaced 0 with NULL where appropriate (in rcu, cht, uspace hashtable, smp_call, workqueue).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/test/synch/rcu1.c

    r6b99156 r205832b  
    4343
    4444static int one_idx = 0;
    45 static thread_t *thread[MAX_THREADS] = {0};
     45static thread_t *thread[MAX_THREADS] = { NULL };
    4646
    4747typedef struct {
     
    100100       
    101101        for (size_t i = 0; i < thread_cnt; ++i) {
    102                 run_thread(i, func, 0);
     102                run_thread(i, func, NULL);
    103103        }
    104104}
     
    123123                       
    124124                        thread_detach(thread[i]);
    125                         thread[i] = 0;
     125                        thread[i] = NULL;
    126126                }
    127127        }
     
    145145                thread_join(thread[one_idx]);
    146146                thread_detach(thread[one_idx]);
    147                 thread[one_idx] = 0;
     147                thread[one_idx] = NULL;
    148148        }
    149149}
     
    337337       
    338338        TPRINTF("\nRun a single reader that posts one callback.\n");
    339         run_one(one_cb_reader, 0);
     339        run_one(one_cb_reader, NULL);
    340340        join_one();
    341341       
     
    10151015                { 0, do_expedite, "do_expedite" },
    10161016                { 1, do_stress, "do_stress" },
    1017                 { 0, 0, 0 }
     1017                { 0, NULL, NULL }
    10181018        };
    10191019       
     
    10231023        uint64_t delta_gps = 0;
    10241024       
    1025         for (int i = 0; test_func[i].func != 0; ++i) {
     1025        for (int i = 0; test_func[i].func; ++i) {
    10261026                if (!test_func[i].include) {
    10271027                        TPRINTF("\nSubtest %s() skipped.\n", test_func[i].desc);
     
    10471047
    10481048        if (success)
    1049                 return 0;
     1049                return NULL;
    10501050        else
    10511051                return "One of the tests failed.";
Note: See TracChangeset for help on using the changeset viewer.