satyr 0.43
Loading...
Searching...
No Matches
koops/stacktrace.h
Go to the documentation of this file.
1/*
2 koops_stacktrace.h
3
4 Copyright (C) 2012 ABRT Team
5 Copyright (C) 2012 Red Hat, Inc.
6
7 This program is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License along
18 with this program; if not, write to the Free Software Foundation, Inc.,
19 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
20*/
21#ifndef SATYR_KOOPS_STACKTRACE_H
22#define SATYR_KOOPS_STACKTRACE_H
23
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
33#include "../report_type.h"
34#include <stdbool.h>
35#include <inttypes.h>
36#include <json.h>
37#include <stddef.h>
38
39struct sr_location;
40
42{
43 enum sr_report_type type;
44
48 char *version;
49
53
55 bool taint_module_out_of_tree;
56 bool taint_forced_module;
57 bool taint_forced_removal;
58 bool taint_smp_unsafe;
63 bool taint_userspace;
64 bool taint_died_recently;
65 bool taint_acpi_overridden;
66 bool taint_warning;
67 bool taint_staging_driver;
68 bool taint_firmware_workaround;
69 bool taint_unsigned_module;
70 bool taint_soft_lockup;
71 bool taint_live_patched;
72
79 char **modules;
80
84 char *raw_oops;
85
90
94 char *reason;
95};
96
103struct sr_koops_stacktrace *
105
112void
114
120void
122
131struct sr_koops_stacktrace *
133
140bool
142 struct sr_koops_frame *frame);
143
153struct sr_koops_stacktrace *
154sr_koops_stacktrace_parse(const char **input,
155 struct sr_location *location);
156
157char **
158sr_koops_stacktrace_parse_modules(const char **input);
159
163char *
165
173char *
175
185struct sr_koops_stacktrace *
186sr_koops_stacktrace_from_json(json_object *root, char **error_message);
187
188void
189sr_normalize_koops_stacktrace(struct sr_koops_stacktrace *stacktrace);
190
191
192#ifdef __cplusplus
193}
194#endif
195
196#endif
void sr_koops_stacktrace_init(struct sr_koops_stacktrace *stacktrace)
struct sr_koops_stacktrace * sr_koops_stacktrace_parse(const char **input, struct sr_location *location)
struct sr_koops_stacktrace * sr_koops_stacktrace_new(void)
void sr_koops_stacktrace_free(struct sr_koops_stacktrace *stacktrace)
struct sr_koops_stacktrace * sr_koops_stacktrace_dup(struct sr_koops_stacktrace *stacktrace)
struct sr_koops_stacktrace * sr_koops_stacktrace_from_json(json_object *root, char **error_message)
char * sr_koops_stacktrace_get_reason(struct sr_koops_stacktrace *stacktrace)
char * sr_koops_stacktrace_to_json(struct sr_koops_stacktrace *stacktrace)
bool sr_koops_stacktrace_remove_frame(struct sr_koops_stacktrace *stacktrace, struct sr_koops_frame *frame)
Report type.
Kernel oops stack frame.
Definition koops/frame.h:44
char * version
Version of the kernel.
char * raw_oops
Raw kerneloops text.
char * reason
Reason message extracted by ABRT.
char ** modules
List of loaded modules.
struct sr_koops_frame * frames
Call trace. It might be NULL as it is not mandatory.
A location of a parser in the input stream.
Definition location.h:43