Lines Matching refs:dwfl

96   Dwfl *dwfl;
106 inline void failure (Dwfl *dwfl, int errnum, const char *msg)
108 if (dwfl != NULL)
109 dwfl_end (dwfl);
116 inline error_t fail (Dwfl *dwfl, int errnum, const char *msg)
118 failure (dwfl, errnum, msg);
141 Dwfl *dwfl = opt->dwfl;
142 if (dwfl == NULL)
144 dwfl = INTUSE(dwfl_begin) (&offline_callbacks);
145 if (dwfl == NULL)
146 return fail (dwfl, -1, arg);
147 opt->dwfl = dwfl;
151 dwfl->offline_next_address = 0;
153 if (dwfl->callbacks != &offline_callbacks)
167 if (opt->dwfl == NULL)
169 Dwfl *dwfl = INTUSE(dwfl_begin) (&proc_callbacks);
170 int result = INTUSE(dwfl_linux_proc_report) (dwfl, atoi (arg));
172 return fail (dwfl, result, arg);
175 INTUSE(dwfl_linux_proc_attach) (dwfl, atoi (arg), false);
177 opt->dwfl = dwfl;
187 if (opt->dwfl == NULL)
197 Dwfl *dwfl = INTUSE(dwfl_begin) (&proc_callbacks);
198 int result = INTUSE(dwfl_linux_proc_maps_report) (dwfl, f);
201 return fail (dwfl, result, arg);
202 opt->dwfl = dwfl;
212 Dwfl *dwfl = opt->dwfl;
213 if (dwfl == NULL)
214 opt->dwfl = dwfl = INTUSE(dwfl_begin) (&offline_callbacks);
216 else if (dwfl->callbacks != &offline_callbacks)
225 if (opt->dwfl == NULL)
227 Dwfl *dwfl = INTUSE(dwfl_begin) (&kernel_callbacks);
228 int result = INTUSE(dwfl_linux_kernel_report_kernel) (dwfl);
230 return fail (dwfl, result, _("cannot load kernel symbols"));
231 result = INTUSE(dwfl_linux_kernel_report_modules) (dwfl);
234 failure (dwfl, result, _("cannot find kernel modules"));
235 opt->dwfl = dwfl;
245 if (opt->dwfl == NULL)
247 Dwfl *dwfl = INTUSE(dwfl_begin) (&offline_callbacks);
248 int result = INTUSE(dwfl_linux_kernel_report_offline) (dwfl, arg,
251 return fail (dwfl, result, _("cannot find kernel or modules"));
252 opt->dwfl = dwfl;
262 Dwfl *dwfl = opt->dwfl;
264 if (dwfl == NULL)
268 dwfl = INTUSE(dwfl_begin) (&offline_callbacks);
269 if (INTUSE(dwfl_report_offline) (dwfl, "", arg, -1) == NULL)
270 return fail (dwfl, -1, arg);
271 opt->dwfl = dwfl;
295 int result = INTUSE(dwfl_core_file_report) (dwfl, core, opt->e);
300 return fail (dwfl, result, opt->core);
304 INTUSE(dwfl_core_file_attach) (dwfl, core);
307 if (dwfl->user_core == NULL)
309 dwfl->user_core = calloc (1, sizeof (struct Dwfl_User_Core));
310 if (dwfl->user_core == NULL)
317 dwfl->user_core->core = core;
318 dwfl->user_core->fd = fd;
329 if (INTUSE(dwfl_report_offline) (dwfl, "", opt->e, -1) == NULL)
330 return fail (dwfl, -1, opt->e);
337 int result = INTUSE(dwfl_report_end) (dwfl, NULL, NULL);
342 *(Dwfl **) state->input = dwfl;
351 dwfl_end (opt->dwfl);
364 *(Dwfl **) state->input = opt->dwfl;