]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
x86: sysreset: Move priv/plat structs to headers
authorSimon Glass <sjg@chromium.org>
Sat, 19 Dec 2020 17:40:04 +0000 (10:40 -0700)
committerSimon Glass <sjg@chromium.org>
Tue, 5 Jan 2021 19:24:41 +0000 (12:24 -0700)
With the new of-platdata, these need to be available to dt_platdata.c
so must be in header files. Move them and add the dtd struct too.

Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
arch/x86/include/asm/sysreset.h [new file with mode: 0644]
drivers/sysreset/sysreset_x86.c

diff --git a/arch/x86/include/asm/sysreset.h b/arch/x86/include/asm/sysreset.h
new file mode 100644 (file)
index 0000000..5e586f5
--- /dev/null
@@ -0,0 +1,18 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2020 Google LLC
+ */
+#ifndef _X86_ASM_SYSRESET_H_
+#define _X86_ASM_SYSRESET_H_
+
+#include <dt-structs.h>
+
+struct x86_sysreset_plat {
+#if CONFIG_IS_ENABLED(OF_PLATDATA)
+       struct dtd_x86_reset dtplat;
+#endif
+
+       struct udevice *pch;
+};
+
+#endif /* _X86_ASM_SYSRESET_H_ */
index 8f9970301e50cbc403d353a5737b8d7c6526ecf3..8042f3994fe2e0f1be9048f3400504b97b653b19 100644 (file)
 #include <acpi/acpi_s3.h>
 #include <asm/io.h>
 #include <asm/processor.h>
-
-struct x86_sysreset_plat {
-       struct udevice *pch;
-};
+#include <asm/sysreset.h>
 
 /*
  * Power down the machine by using the power management sleep control