Lines Matching refs:old
74 static inline void release_probes(struct tracepoint_func *old) in release_probes() argument
76 if (old) { in release_probes()
77 struct tp_probes *tp_probes = container_of(old, in release_probes()
98 struct tracepoint_func *old, *new; in func_add() local
104 old = *funcs; in func_add()
105 if (old) { in func_add()
107 for (nr_probes = 0; old[nr_probes].func; nr_probes++) in func_add()
108 if (old[nr_probes].func == tp_func->func && in func_add()
109 old[nr_probes].data == tp_func->data) in func_add()
116 if (old) in func_add()
117 memcpy(new, old, nr_probes * sizeof(struct tracepoint_func)); in func_add()
122 return old; in func_add()
129 struct tracepoint_func *old, *new; in func_remove() local
131 old = *funcs; in func_remove()
133 if (!old) in func_remove()
139 for (nr_probes = 0; old[nr_probes].func; nr_probes++) { in func_remove()
140 if (old[nr_probes].func == tp_func->func && in func_remove()
141 old[nr_probes].data == tp_func->data) in func_remove()
154 return old; in func_remove()
162 for (i = 0; old[i].func; i++) in func_remove()
163 if (old[i].func != tp_func->func in func_remove()
164 || old[i].data != tp_func->data) in func_remove()
165 new[j++] = old[i]; in func_remove()
170 return old; in func_remove()
179 struct tracepoint_func *old, *tp_funcs; in tracepoint_add_func() local
186 old = func_add(&tp_funcs, func); in tracepoint_add_func()
187 if (IS_ERR(old)) { in tracepoint_add_func()
189 return PTR_ERR(old); in tracepoint_add_func()
202 release_probes(old); in tracepoint_add_func()
215 struct tracepoint_func *old, *tp_funcs; in tracepoint_remove_func() local
219 old = func_remove(&tp_funcs, func); in tracepoint_remove_func()
220 if (IS_ERR(old)) { in tracepoint_remove_func()
222 return PTR_ERR(old); in tracepoint_remove_func()
234 release_probes(old); in tracepoint_remove_func()