Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff -Nrupad /home/user/android/teamhacksung_sammy-cm7//drivers/acpi/sleep.c ./drivers/acpi/sleep.c
- --- /home/user/android/teamhacksung_sammy-cm7//drivers/acpi/sleep.c 2011-04-19 00:17:08.394072081 +0200
- +++ ./drivers/acpi/sleep.c 2011-04-23 00:11:48.127721983 +0200
- @@ -144,7 +144,8 @@ static int acpi_pm_prepare(void)
- int error = __acpi_pm_prepare();
- if (!error)
- - acpi_pm_freeze();
- +/* acpi_pm_freeze(); - used is: acpi_pm_pre_suspend() */
- + error = acpi_pm_freeze();
- return error;
- }
- @@ -520,8 +521,7 @@ static int acpi_hibernation_begin_old(vo
- static int acpi_hibernation_pre_snapshot_old(void)
- {
- acpi_pm_freeze();
- - suspend_nvs_save();
- - return 0;
- + return suspend_nvs_save();
- }
- /*
- diff -Nrupad /home/user/android/teamhacksung_sammy-cm7//drivers/acpi/sleep.c.rej ./drivers/acpi/sleep.c.rej
- --- /home/user/android/teamhacksung_sammy-cm7//drivers/acpi/sleep.c.rej 1970-01-01 01:00:00.000000000 +0100
- +++ ./drivers/acpi/sleep.c.rej 2011-04-23 00:08:02.639721872 +0200
- @@ -0,0 +1,11 @@
- +--- drivers/acpi/sleep.c
- ++++ drivers/acpi/sleep.c
- +@@ -150,7 +149,7 @@
- + {
- + int error = __acpi_pm_prepare();
- + if (!error)
- +- acpi_pm_pre_suspend(); [acpi_pm_freeze]
- ++ error = acpi_pm_pre_suspend();
- +
- + return error;
- + }
- diff -Nrupad /home/user/android/teamhacksung_sammy-cm7//include/linux/suspend.h ./include/linux/suspend.h
- --- /home/user/android/teamhacksung_sammy-cm7//include/linux/suspend.h 2011-04-19 00:17:10.527072081 +0200
- +++ ./include/linux/suspend.h 2011-04-23 00:06:25.560721834 +0200
- @@ -260,7 +260,7 @@ static inline bool system_entering_hiber
- extern int suspend_nvs_register(unsigned long start, unsigned long size);
- extern int suspend_nvs_alloc(void);
- extern void suspend_nvs_free(void);
- -extern void suspend_nvs_save(void);
- +extern int suspend_nvs_save(void);
- extern void suspend_nvs_restore(void);
- #else /* CONFIG_SUSPEND_NVS */
- static inline int suspend_nvs_register(unsigned long a, unsigned long b)
- @@ -269,7 +269,7 @@ static inline int suspend_nvs_register(u
- }
- static inline int suspend_nvs_alloc(void) { return 0; }
- static inline void suspend_nvs_free(void) {}
- -static inline void suspend_nvs_save(void) {}
- +static inline int suspend_nvs_save(void) {}
- static inline void suspend_nvs_restore(void) {}
- #endif /* CONFIG_SUSPEND_NVS */
- diff -Nrupad /home/user/android/teamhacksung_sammy-cm7//kernel/power/nvs.c ./kernel/power/nvs.c
- --- /home/user/android/teamhacksung_sammy-cm7//kernel/power/nvs.c 2011-04-19 00:17:10.625072081 +0200
- +++ ./kernel/power/nvs.c 2011-04-23 00:06:25.560721834 +0200
- @@ -105,7 +105,7 @@ int suspend_nvs_alloc(void)
- /**
- * suspend_nvs_save - save NVS memory regions
- */
- -void suspend_nvs_save(void)
- +int suspend_nvs_save(void)
- {
- struct nvs_page *entry;
- @@ -114,8 +114,14 @@ void suspend_nvs_save(void)
- list_for_each_entry(entry, &nvs_list, node)
- if (entry->data) {
- entry->kaddr = ioremap(entry->phys_start, entry->size);
- + if (!entry->kaddr) {
- + suspend_nvs_free();
- + return -ENOMEM;
- + }
- memcpy(entry->data, entry->kaddr, entry->size);
- }
- +
- + return 0;
- }
- /**
- diff -Nrupad /home/user/android/teamhacksung_sammy-cm7//kernel/printk.c ./kernel/printk.c
- --- /home/user/android/teamhacksung_sammy-cm7//kernel/printk.c 2011-04-19 00:17:10.627072081 +0200
- +++ ./kernel/printk.c 2011-04-23 00:26:55.076722431 +0200
- @@ -1125,7 +1125,7 @@ int update_console_cmdline(char *name, i
- return -1;
- }
- -int console_suspend_enabled = 1;
- +int console_suspend_enabled = 0;
- EXPORT_SYMBOL(console_suspend_enabled);
- static int __init console_suspend_disable(char *str)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement