Loading arch/loongarch/Kconfig +5 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,7 @@ config LOONGARCH select ARCH_WANTS_NO_INSTR select BUILDTIME_TABLE_SORT select COMMON_CLK select CPU_PM select EFI select GENERIC_CLOCKEVENTS select GENERIC_CMOS_UPDATE Loading Loading @@ -517,6 +518,10 @@ config ARCH_MMAP_RND_BITS_MAX menu "Power management options" config ARCH_SUSPEND_POSSIBLE def_bool y source "kernel/power/Kconfig" source "drivers/acpi/Kconfig" endmenu Loading arch/loongarch/Makefile +3 −0 Original line number Diff line number Diff line Loading @@ -104,6 +104,9 @@ endif libs-y += arch/loongarch/lib/ libs-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a # suspend and hibernation support drivers-$(CONFIG_PM) += arch/loongarch/power/ ifeq ($(KBUILD_EXTMOD),) prepare: vdso_prepare vdso_prepare: prepare0 Loading arch/loongarch/include/asm/acpi.h +10 −0 Original line number Diff line number Diff line Loading @@ -35,4 +35,14 @@ extern struct list_head acpi_wakeup_device_list; #define ACPI_TABLE_UPGRADE_MAX_PHYS ARCH_LOW_ADDRESS_LIMIT extern int loongarch_acpi_suspend(void); extern int (*acpi_suspend_lowlevel)(void); extern void loongarch_suspend_enter(void); static inline unsigned long acpi_get_wakeup_address(void) { extern void loongarch_wakeup_start(void); return (unsigned long)loongarch_wakeup_start; } #endif /* _ASM_LOONGARCH_ACPI_H */ arch/loongarch/include/asm/bootinfo.h +1 −0 Original line number Diff line number Diff line Loading @@ -32,6 +32,7 @@ struct loongson_system_configuration { int cores_per_node; int cores_per_package; unsigned long cores_io_master; unsigned long suspend_addr; const char *cpuname; }; Loading arch/loongarch/include/asm/loongson.h +3 −0 Original line number Diff line number Diff line Loading @@ -136,4 +136,7 @@ typedef enum { #define ls7a_writel(val, addr) *(volatile unsigned int *)TO_UNCACHE(addr) = (val) #define ls7a_writeq(val, addr) *(volatile unsigned long *)TO_UNCACHE(addr) = (val) void enable_gpe_wakeup(void); void enable_pci_wakeup(void); #endif /* __ASM_LOONGSON_H */ Loading
arch/loongarch/Kconfig +5 −0 Original line number Diff line number Diff line Loading @@ -56,6 +56,7 @@ config LOONGARCH select ARCH_WANTS_NO_INSTR select BUILDTIME_TABLE_SORT select COMMON_CLK select CPU_PM select EFI select GENERIC_CLOCKEVENTS select GENERIC_CMOS_UPDATE Loading Loading @@ -517,6 +518,10 @@ config ARCH_MMAP_RND_BITS_MAX menu "Power management options" config ARCH_SUSPEND_POSSIBLE def_bool y source "kernel/power/Kconfig" source "drivers/acpi/Kconfig" endmenu Loading
arch/loongarch/Makefile +3 −0 Original line number Diff line number Diff line Loading @@ -104,6 +104,9 @@ endif libs-y += arch/loongarch/lib/ libs-$(CONFIG_EFI_STUB) += $(objtree)/drivers/firmware/efi/libstub/lib.a # suspend and hibernation support drivers-$(CONFIG_PM) += arch/loongarch/power/ ifeq ($(KBUILD_EXTMOD),) prepare: vdso_prepare vdso_prepare: prepare0 Loading
arch/loongarch/include/asm/acpi.h +10 −0 Original line number Diff line number Diff line Loading @@ -35,4 +35,14 @@ extern struct list_head acpi_wakeup_device_list; #define ACPI_TABLE_UPGRADE_MAX_PHYS ARCH_LOW_ADDRESS_LIMIT extern int loongarch_acpi_suspend(void); extern int (*acpi_suspend_lowlevel)(void); extern void loongarch_suspend_enter(void); static inline unsigned long acpi_get_wakeup_address(void) { extern void loongarch_wakeup_start(void); return (unsigned long)loongarch_wakeup_start; } #endif /* _ASM_LOONGARCH_ACPI_H */
arch/loongarch/include/asm/bootinfo.h +1 −0 Original line number Diff line number Diff line Loading @@ -32,6 +32,7 @@ struct loongson_system_configuration { int cores_per_node; int cores_per_package; unsigned long cores_io_master; unsigned long suspend_addr; const char *cpuname; }; Loading
arch/loongarch/include/asm/loongson.h +3 −0 Original line number Diff line number Diff line Loading @@ -136,4 +136,7 @@ typedef enum { #define ls7a_writel(val, addr) *(volatile unsigned int *)TO_UNCACHE(addr) = (val) #define ls7a_writeq(val, addr) *(volatile unsigned long *)TO_UNCACHE(addr) = (val) void enable_gpe_wakeup(void); void enable_pci_wakeup(void); #endif /* __ASM_LOONGSON_H */