Lines Matching refs:cpr
36 struct call_path_root *cpr; in call_path_root__new() local
38 cpr = zalloc(sizeof(struct call_path_root)); in call_path_root__new()
39 if (!cpr) in call_path_root__new()
41 call_path__init(&cpr->call_path, NULL, NULL, 0, false); in call_path_root__new()
42 INIT_LIST_HEAD(&cpr->blocks); in call_path_root__new()
43 return cpr; in call_path_root__new()
46 void call_path_root__free(struct call_path_root *cpr) in call_path_root__free() argument
50 list_for_each_entry_safe(pos, n, &cpr->blocks, node) { in call_path_root__free()
54 free(cpr); in call_path_root__free()
57 static struct call_path *call_path__new(struct call_path_root *cpr, in call_path__new() argument
66 if (cpr->next < cpr->sz) { in call_path__new()
67 cpb = list_last_entry(&cpr->blocks, struct call_path_block, in call_path__new()
73 list_add_tail(&cpb->node, &cpr->blocks); in call_path__new()
74 cpr->sz += CALL_PATH_BLOCK_SIZE; in call_path__new()
77 n = cpr->next++ & CALL_PATH_BLOCK_MASK; in call_path__new()
85 struct call_path *call_path__findnew(struct call_path_root *cpr, in call_path__findnew() argument
98 return call_path__new(cpr, parent, sym, ip, in_kernel); in call_path__findnew()
114 cp = call_path__new(cpr, parent, sym, ip, in_kernel); in call_path__findnew()