blob: 16db419f9e9067841a9fd2f4936f15ea23e3f168 [file] [log] [blame]
Shannon Zhaobe1aaf42016-04-07 20:03:32 +08001/*
2 * Copyright (c) 2015, Linaro Limited, Shannon Zhao
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along
15 * with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17
18#include <linux/efi.h>
19#include <xen/xen-ops.h>
20#include <asm/xen/xen-ops.h>
21
22/* Set XEN EFI runtime services function pointers. Other fields of struct efi,
23 * e.g. efi.systab, will be set like normal EFI.
24 */
25void __init xen_efi_runtime_setup(void)
26{
27 efi.get_time = xen_efi_get_time;
28 efi.set_time = xen_efi_set_time;
29 efi.get_wakeup_time = xen_efi_get_wakeup_time;
30 efi.set_wakeup_time = xen_efi_set_wakeup_time;
31 efi.get_variable = xen_efi_get_variable;
32 efi.get_next_variable = xen_efi_get_next_variable;
33 efi.set_variable = xen_efi_set_variable;
34 efi.query_variable_info = xen_efi_query_variable_info;
35 efi.update_capsule = xen_efi_update_capsule;
36 efi.query_capsule_caps = xen_efi_query_capsule_caps;
37 efi.get_next_high_mono_count = xen_efi_get_next_high_mono_count;
38 efi.reset_system = NULL; /* Functionality provided by Xen. */
39}
40EXPORT_SYMBOL_GPL(xen_efi_runtime_setup);