Greg Kroah-Hartman | b244131 | 2017-11-01 15:07:57 +0100 | [diff] [blame] | 1 | // SPDX-License-Identifier: GPL-2.0 |
Jeremy Fitzhardinge | f04e2ee | 2010-12-16 14:15:23 -0800 | [diff] [blame] | 2 | #include <linux/ftrace.h> |
Konrad Rzeszutek Wilk | c00c8aa | 2011-08-04 18:42:10 -0400 | [diff] [blame] | 3 | #include <xen/interface/xen.h> |
Juergen Gross | fc903f8 | 2015-01-21 08:49:24 +0100 | [diff] [blame] | 4 | #include <xen/interface/xen-mca.h> |
Jeremy Fitzhardinge | f04e2ee | 2010-12-16 14:15:23 -0800 | [diff] [blame] | 5 | |
Juergen Gross | fc903f8 | 2015-01-21 08:49:24 +0100 | [diff] [blame] | 6 | #define HYPERCALL(x) [__HYPERVISOR_##x] = "("#x")", |
Jeremy Fitzhardinge | c796f21 | 2010-12-16 14:33:27 -0800 | [diff] [blame] | 7 | static const char *xen_hypercall_names[] = { |
Juergen Gross | fc903f8 | 2015-01-21 08:49:24 +0100 | [diff] [blame] | 8 | #include <asm/xen-hypercalls.h> |
Jeremy Fitzhardinge | c796f21 | 2010-12-16 14:33:27 -0800 | [diff] [blame] | 9 | }; |
Juergen Gross | fc903f8 | 2015-01-21 08:49:24 +0100 | [diff] [blame] | 10 | #undef HYPERCALL |
Jeremy Fitzhardinge | c796f21 | 2010-12-16 14:33:27 -0800 | [diff] [blame] | 11 | |
| 12 | static const char *xen_hypercall_name(unsigned op) |
| 13 | { |
| 14 | if (op < ARRAY_SIZE(xen_hypercall_names) && xen_hypercall_names[op] != NULL) |
| 15 | return xen_hypercall_names[op]; |
| 16 | |
| 17 | return ""; |
| 18 | } |
| 19 | |
Jeremy Fitzhardinge | f04e2ee | 2010-12-16 14:15:23 -0800 | [diff] [blame] | 20 | #define CREATE_TRACE_POINTS |
| 21 | #include <trace/events/xen.h> |