diff options
Diffstat (limited to 'arch')
63 files changed, 305 insertions, 189 deletions
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig index a0f642b6a4b9..6110197757a3 100644 --- a/arch/alpha/Kconfig +++ b/arch/alpha/Kconfig | |||
@@ -70,6 +70,7 @@ config AUTO_IRQ_AFFINITY | |||
70 | default y | 70 | default y |
71 | 71 | ||
72 | source "init/Kconfig" | 72 | source "init/Kconfig" |
73 | source "kernel/Kconfig.freezer" | ||
73 | 74 | ||
74 | 75 | ||
75 | menu "System setup" | 76 | menu "System setup" |
diff --git a/arch/alpha/include/asm/thread_info.h b/arch/alpha/include/asm/thread_info.h index 15fda4344424..d069526bd767 100644 --- a/arch/alpha/include/asm/thread_info.h +++ b/arch/alpha/include/asm/thread_info.h | |||
@@ -74,12 +74,14 @@ register struct thread_info *__current_thread_info __asm__("$8"); | |||
74 | #define TIF_UAC_SIGBUS 7 | 74 | #define TIF_UAC_SIGBUS 7 |
75 | #define TIF_MEMDIE 8 | 75 | #define TIF_MEMDIE 8 |
76 | #define TIF_RESTORE_SIGMASK 9 /* restore signal mask in do_signal */ | 76 | #define TIF_RESTORE_SIGMASK 9 /* restore signal mask in do_signal */ |
77 | #define TIF_FREEZE 16 /* is freezing for suspend */ | ||
77 | 78 | ||
78 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 79 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
79 | #define _TIF_SIGPENDING (1<<TIF_SIGPENDING) | 80 | #define _TIF_SIGPENDING (1<<TIF_SIGPENDING) |
80 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) | 81 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) |
81 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 82 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
82 | #define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) | 83 | #define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) |
84 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
83 | 85 | ||
84 | /* Work to do on interrupt/exception return. */ | 86 | /* Work to do on interrupt/exception return. */ |
85 | #define _TIF_WORK_MASK (_TIF_SIGPENDING | _TIF_NEED_RESCHED) | 87 | #define _TIF_WORK_MASK (_TIF_SIGPENDING | _TIF_NEED_RESCHED) |
diff --git a/arch/alpha/kernel/core_marvel.c b/arch/alpha/kernel/core_marvel.c index 04dcc5e5d4c1..9cd8dca742a7 100644 --- a/arch/alpha/kernel/core_marvel.c +++ b/arch/alpha/kernel/core_marvel.c | |||
@@ -655,7 +655,7 @@ __marvel_rtc_io(u8 b, unsigned long addr, int write) | |||
655 | 655 | ||
656 | case 0x71: /* RTC_PORT(1) */ | 656 | case 0x71: /* RTC_PORT(1) */ |
657 | rtc_access.index = index; | 657 | rtc_access.index = index; |
658 | rtc_access.data = BCD_TO_BIN(b); | 658 | rtc_access.data = bcd2bin(b); |
659 | rtc_access.function = 0x48 + !write; /* GET/PUT_TOY */ | 659 | rtc_access.function = 0x48 + !write; /* GET/PUT_TOY */ |
660 | 660 | ||
661 | #ifdef CONFIG_SMP | 661 | #ifdef CONFIG_SMP |
@@ -668,7 +668,7 @@ __marvel_rtc_io(u8 b, unsigned long addr, int write) | |||
668 | #else | 668 | #else |
669 | __marvel_access_rtc(&rtc_access); | 669 | __marvel_access_rtc(&rtc_access); |
670 | #endif | 670 | #endif |
671 | ret = BIN_TO_BCD(rtc_access.data); | 671 | ret = bin2bcd(rtc_access.data); |
672 | break; | 672 | break; |
673 | 673 | ||
674 | default: | 674 | default: |
diff --git a/arch/alpha/kernel/time.c b/arch/alpha/kernel/time.c index 75480cab0893..e6a231435cba 100644 --- a/arch/alpha/kernel/time.c +++ b/arch/alpha/kernel/time.c | |||
@@ -346,12 +346,12 @@ time_init(void) | |||
346 | year = CMOS_READ(RTC_YEAR); | 346 | year = CMOS_READ(RTC_YEAR); |
347 | 347 | ||
348 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 348 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
349 | BCD_TO_BIN(sec); | 349 | sec = bcd2bin(sec); |
350 | BCD_TO_BIN(min); | 350 | min = bcd2bin(min); |
351 | BCD_TO_BIN(hour); | 351 | hour = bcd2bin(hour); |
352 | BCD_TO_BIN(day); | 352 | day = bcd2bin(day); |
353 | BCD_TO_BIN(mon); | 353 | mon = bcd2bin(mon); |
354 | BCD_TO_BIN(year); | 354 | year = bcd2bin(year); |
355 | } | 355 | } |
356 | 356 | ||
357 | /* PC-like is standard; used for year >= 70 */ | 357 | /* PC-like is standard; used for year >= 70 */ |
@@ -525,7 +525,7 @@ set_rtc_mmss(unsigned long nowtime) | |||
525 | 525 | ||
526 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 526 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
527 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 527 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) |
528 | BCD_TO_BIN(cmos_minutes); | 528 | cmos_minutes = bcd2bin(cmos_minutes); |
529 | 529 | ||
530 | /* | 530 | /* |
531 | * since we're only adjusting minutes and seconds, | 531 | * since we're only adjusting minutes and seconds, |
@@ -543,8 +543,8 @@ set_rtc_mmss(unsigned long nowtime) | |||
543 | 543 | ||
544 | if (abs(real_minutes - cmos_minutes) < 30) { | 544 | if (abs(real_minutes - cmos_minutes) < 30) { |
545 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 545 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
546 | BIN_TO_BCD(real_seconds); | 546 | real_seconds = bin2bcd(real_seconds); |
547 | BIN_TO_BCD(real_minutes); | 547 | real_minutes = bin2bcd(real_minutes); |
548 | } | 548 | } |
549 | CMOS_WRITE(real_seconds,RTC_SECONDS); | 549 | CMOS_WRITE(real_seconds,RTC_SECONDS); |
550 | CMOS_WRITE(real_minutes,RTC_MINUTES); | 550 | CMOS_WRITE(real_minutes,RTC_MINUTES); |
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 4853f9df37bd..df39d20f7425 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
@@ -192,6 +192,8 @@ config VECTORS_BASE | |||
192 | 192 | ||
193 | source "init/Kconfig" | 193 | source "init/Kconfig" |
194 | 194 | ||
195 | source "kernel/Kconfig.freezer" | ||
196 | |||
195 | menu "System Type" | 197 | menu "System Type" |
196 | 198 | ||
197 | choice | 199 | choice |
diff --git a/arch/arm/mach-pxa/include/mach/pxa3xx_nand.h b/arch/arm/mach-pxa/include/mach/pxa3xx_nand.h index eb4b190b6657..eb35fca9aea5 100644 --- a/arch/arm/mach-pxa/include/mach/pxa3xx_nand.h +++ b/arch/arm/mach-pxa/include/mach/pxa3xx_nand.h | |||
@@ -4,6 +4,43 @@ | |||
4 | #include <linux/mtd/mtd.h> | 4 | #include <linux/mtd/mtd.h> |
5 | #include <linux/mtd/partitions.h> | 5 | #include <linux/mtd/partitions.h> |
6 | 6 | ||
7 | struct pxa3xx_nand_timing { | ||
8 | unsigned int tCH; /* Enable signal hold time */ | ||
9 | unsigned int tCS; /* Enable signal setup time */ | ||
10 | unsigned int tWH; /* ND_nWE high duration */ | ||
11 | unsigned int tWP; /* ND_nWE pulse time */ | ||
12 | unsigned int tRH; /* ND_nRE high duration */ | ||
13 | unsigned int tRP; /* ND_nRE pulse width */ | ||
14 | unsigned int tR; /* ND_nWE high to ND_nRE low for read */ | ||
15 | unsigned int tWHR; /* ND_nWE high to ND_nRE low for status read */ | ||
16 | unsigned int tAR; /* ND_ALE low to ND_nRE low delay */ | ||
17 | }; | ||
18 | |||
19 | struct pxa3xx_nand_cmdset { | ||
20 | uint16_t read1; | ||
21 | uint16_t read2; | ||
22 | uint16_t program; | ||
23 | uint16_t read_status; | ||
24 | uint16_t read_id; | ||
25 | uint16_t erase; | ||
26 | uint16_t reset; | ||
27 | uint16_t lock; | ||
28 | uint16_t unlock; | ||
29 | uint16_t lock_status; | ||
30 | }; | ||
31 | |||
32 | struct pxa3xx_nand_flash { | ||
33 | const struct pxa3xx_nand_timing *timing; /* NAND Flash timing */ | ||
34 | const struct pxa3xx_nand_cmdset *cmdset; | ||
35 | |||
36 | uint32_t page_per_block;/* Pages per block (PG_PER_BLK) */ | ||
37 | uint32_t page_size; /* Page size in bytes (PAGE_SZ) */ | ||
38 | uint32_t flash_width; /* Width of Flash memory (DWIDTH_M) */ | ||
39 | uint32_t dfc_width; /* Width of flash controller(DWIDTH_C) */ | ||
40 | uint32_t num_blocks; /* Number of physical blocks in Flash */ | ||
41 | uint32_t chip_id; | ||
42 | }; | ||
43 | |||
7 | struct pxa3xx_nand_platform_data { | 44 | struct pxa3xx_nand_platform_data { |
8 | 45 | ||
9 | /* the data flash bus is shared between the Static Memory | 46 | /* the data flash bus is shared between the Static Memory |
@@ -12,8 +49,11 @@ struct pxa3xx_nand_platform_data { | |||
12 | */ | 49 | */ |
13 | int enable_arbiter; | 50 | int enable_arbiter; |
14 | 51 | ||
15 | struct mtd_partition *parts; | 52 | const struct mtd_partition *parts; |
16 | unsigned int nr_parts; | 53 | unsigned int nr_parts; |
54 | |||
55 | const struct pxa3xx_nand_flash * flash; | ||
56 | size_t num_flash; | ||
17 | }; | 57 | }; |
18 | 58 | ||
19 | extern void pxa3xx_set_nand_info(struct pxa3xx_nand_platform_data *info); | 59 | extern void pxa3xx_set_nand_info(struct pxa3xx_nand_platform_data *info); |
diff --git a/arch/arm/plat-mxc/include/mach/mxc_nand.h b/arch/arm/plat-mxc/include/mach/mxc_nand.h new file mode 100644 index 000000000000..2b972df22d12 --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/mxc_nand.h | |||
@@ -0,0 +1,27 @@ | |||
1 | /* | ||
2 | * Copyright 2004-2007 Freescale Semiconductor, Inc. All Rights Reserved. | ||
3 | * Copyright 2008 Sascha Hauer, kernel@pengutronix.de | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or | ||
6 | * modify it under the terms of the GNU General Public License | ||
7 | * as published by the Free Software Foundation; either version 2 | ||
8 | * of the License, or (at your option) any later version. | ||
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 | ||
15 | * along with this program; if not, write to the Free Software | ||
16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
17 | * MA 02110-1301, USA. | ||
18 | */ | ||
19 | |||
20 | #ifndef __ASM_ARCH_NAND_H | ||
21 | #define __ASM_ARCH_NAND_H | ||
22 | |||
23 | struct mxc_nand_platform_data { | ||
24 | int width; /* data bus width in bytes */ | ||
25 | int hw_ecc; /* 0 if supress hardware ECC */ | ||
26 | }; | ||
27 | #endif /* __ASM_ARCH_NAND_H */ | ||
diff --git a/arch/arm/plat-omap/include/mach/onenand.h b/arch/arm/plat-omap/include/mach/onenand.h index d57f20226b28..4649d302c263 100644 --- a/arch/arm/plat-omap/include/mach/onenand.h +++ b/arch/arm/plat-omap/include/mach/onenand.h | |||
@@ -16,6 +16,10 @@ struct omap_onenand_platform_data { | |||
16 | int gpio_irq; | 16 | int gpio_irq; |
17 | struct mtd_partition *parts; | 17 | struct mtd_partition *parts; |
18 | int nr_parts; | 18 | int nr_parts; |
19 | int (*onenand_setup)(void __iomem *); | 19 | int (*onenand_setup)(void __iomem *, int freq); |
20 | int dma_channel; | 20 | int dma_channel; |
21 | }; | 21 | }; |
22 | |||
23 | int omap2_onenand_rephase(void); | ||
24 | |||
25 | #define ONENAND_MAX_PARTITIONS 8 | ||
diff --git a/arch/avr32/Kconfig b/arch/avr32/Kconfig index 7c239a916275..33a5b2969eb4 100644 --- a/arch/avr32/Kconfig +++ b/arch/avr32/Kconfig | |||
@@ -72,6 +72,8 @@ config GENERIC_BUG | |||
72 | 72 | ||
73 | source "init/Kconfig" | 73 | source "init/Kconfig" |
74 | 74 | ||
75 | source "kernel/Kconfig.freezer" | ||
76 | |||
75 | menu "System Type and features" | 77 | menu "System Type and features" |
76 | 78 | ||
77 | source "kernel/time/Kconfig" | 79 | source "kernel/time/Kconfig" |
diff --git a/arch/avr32/include/asm/thread_info.h b/arch/avr32/include/asm/thread_info.h index 294b25f9323d..4442f8d2d423 100644 --- a/arch/avr32/include/asm/thread_info.h +++ b/arch/avr32/include/asm/thread_info.h | |||
@@ -96,6 +96,7 @@ static inline struct thread_info *current_thread_info(void) | |||
96 | #define _TIF_MEMDIE (1 << TIF_MEMDIE) | 96 | #define _TIF_MEMDIE (1 << TIF_MEMDIE) |
97 | #define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK) | 97 | #define _TIF_RESTORE_SIGMASK (1 << TIF_RESTORE_SIGMASK) |
98 | #define _TIF_CPU_GOING_TO_SLEEP (1 << TIF_CPU_GOING_TO_SLEEP) | 98 | #define _TIF_CPU_GOING_TO_SLEEP (1 << TIF_CPU_GOING_TO_SLEEP) |
99 | #define _TIF_FREEZE (1 << TIF_FREEZE) | ||
99 | 100 | ||
100 | /* Note: The masks below must never span more than 16 bits! */ | 101 | /* Note: The masks below must never span more than 16 bits! */ |
101 | 102 | ||
diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig index 8102c79aaa94..29e71ed6b8a7 100644 --- a/arch/blackfin/Kconfig +++ b/arch/blackfin/Kconfig | |||
@@ -64,8 +64,11 @@ config HARDWARE_PM | |||
64 | depends on OPROFILE | 64 | depends on OPROFILE |
65 | 65 | ||
66 | source "init/Kconfig" | 66 | source "init/Kconfig" |
67 | |||
67 | source "kernel/Kconfig.preempt" | 68 | source "kernel/Kconfig.preempt" |
68 | 69 | ||
70 | source "kernel/Kconfig.freezer" | ||
71 | |||
69 | menu "Blackfin Processor Options" | 72 | menu "Blackfin Processor Options" |
70 | 73 | ||
71 | comment "Processor and Board Settings" | 74 | comment "Processor and Board Settings" |
diff --git a/arch/cris/Kconfig b/arch/cris/Kconfig index 9389d38f222f..07335e719bf8 100644 --- a/arch/cris/Kconfig +++ b/arch/cris/Kconfig | |||
@@ -62,6 +62,8 @@ config HZ | |||
62 | 62 | ||
63 | source "init/Kconfig" | 63 | source "init/Kconfig" |
64 | 64 | ||
65 | source "kernel/Kconfig.freezer" | ||
66 | |||
65 | menu "General setup" | 67 | menu "General setup" |
66 | 68 | ||
67 | source "fs/Kconfig.binfmt" | 69 | source "fs/Kconfig.binfmt" |
diff --git a/arch/cris/arch-v10/drivers/ds1302.c b/arch/cris/arch-v10/drivers/ds1302.c index c9aa3904be05..3bdfaf43390c 100644 --- a/arch/cris/arch-v10/drivers/ds1302.c +++ b/arch/cris/arch-v10/drivers/ds1302.c | |||
@@ -215,12 +215,12 @@ get_rtc_time(struct rtc_time *rtc_tm) | |||
215 | 215 | ||
216 | local_irq_restore(flags); | 216 | local_irq_restore(flags); |
217 | 217 | ||
218 | BCD_TO_BIN(rtc_tm->tm_sec); | 218 | rtc_tm->tm_sec = bcd2bin(rtc_tm->tm_sec); |
219 | BCD_TO_BIN(rtc_tm->tm_min); | 219 | rtc_tm->tm_min = bcd2bin(rtc_tm->tm_min); |
220 | BCD_TO_BIN(rtc_tm->tm_hour); | 220 | rtc_tm->tm_hour = bcd2bin(rtc_tm->tm_hour); |
221 | BCD_TO_BIN(rtc_tm->tm_mday); | 221 | rtc_tm->tm_mday = bcd2bin(rtc_tm->tm_mday); |
222 | BCD_TO_BIN(rtc_tm->tm_mon); | 222 | rtc_tm->tm_mon = bcd2bin(rtc_tm->tm_mon); |
223 | BCD_TO_BIN(rtc_tm->tm_year); | 223 | rtc_tm->tm_year = bcd2bin(rtc_tm->tm_year); |
224 | 224 | ||
225 | /* | 225 | /* |
226 | * Account for differences between how the RTC uses the values | 226 | * Account for differences between how the RTC uses the values |
@@ -295,12 +295,12 @@ rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd, | |||
295 | else | 295 | else |
296 | yrs -= 1900; /* RTC (70, 71, ... 99) */ | 296 | yrs -= 1900; /* RTC (70, 71, ... 99) */ |
297 | 297 | ||
298 | BIN_TO_BCD(sec); | 298 | sec = bin2bcd(sec); |
299 | BIN_TO_BCD(min); | 299 | min = bin2bcd(min); |
300 | BIN_TO_BCD(hrs); | 300 | hrs = bin2bcd(hrs); |
301 | BIN_TO_BCD(day); | 301 | day = bin2bcd(day); |
302 | BIN_TO_BCD(mon); | 302 | mon = bin2bcd(mon); |
303 | BIN_TO_BCD(yrs); | 303 | yrs = bin2bcd(yrs); |
304 | 304 | ||
305 | local_irq_save(flags); | 305 | local_irq_save(flags); |
306 | CMOS_WRITE(yrs, RTC_YEAR); | 306 | CMOS_WRITE(yrs, RTC_YEAR); |
diff --git a/arch/cris/arch-v10/drivers/pcf8563.c b/arch/cris/arch-v10/drivers/pcf8563.c index 8769dc914073..1e90c1a9c849 100644 --- a/arch/cris/arch-v10/drivers/pcf8563.c +++ b/arch/cris/arch-v10/drivers/pcf8563.c | |||
@@ -122,7 +122,7 @@ get_rtc_time(struct rtc_time *tm) | |||
122 | "information is no longer guaranteed!\n", PCF8563_NAME); | 122 | "information is no longer guaranteed!\n", PCF8563_NAME); |
123 | } | 123 | } |
124 | 124 | ||
125 | tm->tm_year = BCD_TO_BIN(tm->tm_year) + | 125 | tm->tm_year = bcd2bin(tm->tm_year) + |
126 | ((tm->tm_mon & 0x80) ? 100 : 0); | 126 | ((tm->tm_mon & 0x80) ? 100 : 0); |
127 | tm->tm_sec &= 0x7F; | 127 | tm->tm_sec &= 0x7F; |
128 | tm->tm_min &= 0x7F; | 128 | tm->tm_min &= 0x7F; |
@@ -131,11 +131,11 @@ get_rtc_time(struct rtc_time *tm) | |||
131 | tm->tm_wday &= 0x07; /* Not coded in BCD. */ | 131 | tm->tm_wday &= 0x07; /* Not coded in BCD. */ |
132 | tm->tm_mon &= 0x1F; | 132 | tm->tm_mon &= 0x1F; |
133 | 133 | ||
134 | BCD_TO_BIN(tm->tm_sec); | 134 | tm->tm_sec = bcd2bin(tm->tm_sec); |
135 | BCD_TO_BIN(tm->tm_min); | 135 | tm->tm_min = bcd2bin(tm->tm_min); |
136 | BCD_TO_BIN(tm->tm_hour); | 136 | tm->tm_hour = bcd2bin(tm->tm_hour); |
137 | BCD_TO_BIN(tm->tm_mday); | 137 | tm->tm_mday = bcd2bin(tm->tm_mday); |
138 | BCD_TO_BIN(tm->tm_mon); | 138 | tm->tm_mon = bcd2bin(tm->tm_mon); |
139 | tm->tm_mon--; /* Month is 1..12 in RTC but 0..11 in linux */ | 139 | tm->tm_mon--; /* Month is 1..12 in RTC but 0..11 in linux */ |
140 | } | 140 | } |
141 | 141 | ||
@@ -282,12 +282,12 @@ int pcf8563_ioctl(struct inode *inode, struct file *filp, unsigned int cmd, | |||
282 | century = (tm.tm_year >= 2000) ? 0x80 : 0; | 282 | century = (tm.tm_year >= 2000) ? 0x80 : 0; |
283 | tm.tm_year = tm.tm_year % 100; | 283 | tm.tm_year = tm.tm_year % 100; |
284 | 284 | ||
285 | BIN_TO_BCD(tm.tm_year); | 285 | tm.tm_year = bin2bcd(tm.tm_year); |
286 | BIN_TO_BCD(tm.tm_mon); | 286 | tm.tm_mon = bin2bcd(tm.tm_mon); |
287 | BIN_TO_BCD(tm.tm_mday); | 287 | tm.tm_mday = bin2bcd(tm.tm_mday); |
288 | BIN_TO_BCD(tm.tm_hour); | 288 | tm.tm_hour = bin2bcd(tm.tm_hour); |
289 | BIN_TO_BCD(tm.tm_min); | 289 | tm.tm_min = bin2bcd(tm.tm_min); |
290 | BIN_TO_BCD(tm.tm_sec); | 290 | tm.tm_sec = bin2bcd(tm.tm_sec); |
291 | tm.tm_mon |= century; | 291 | tm.tm_mon |= century; |
292 | 292 | ||
293 | mutex_lock(&rtc_lock); | 293 | mutex_lock(&rtc_lock); |
diff --git a/arch/cris/arch-v32/drivers/pcf8563.c b/arch/cris/arch-v32/drivers/pcf8563.c index f263ab571221..f4478506e52c 100644 --- a/arch/cris/arch-v32/drivers/pcf8563.c +++ b/arch/cris/arch-v32/drivers/pcf8563.c | |||
@@ -118,7 +118,7 @@ get_rtc_time(struct rtc_time *tm) | |||
118 | "information is no longer guaranteed!\n", PCF8563_NAME); | 118 | "information is no longer guaranteed!\n", PCF8563_NAME); |
119 | } | 119 | } |
120 | 120 | ||
121 | tm->tm_year = BCD_TO_BIN(tm->tm_year) + | 121 | tm->tm_year = bcd2bin(tm->tm_year) + |
122 | ((tm->tm_mon & 0x80) ? 100 : 0); | 122 | ((tm->tm_mon & 0x80) ? 100 : 0); |
123 | tm->tm_sec &= 0x7F; | 123 | tm->tm_sec &= 0x7F; |
124 | tm->tm_min &= 0x7F; | 124 | tm->tm_min &= 0x7F; |
@@ -127,11 +127,11 @@ get_rtc_time(struct rtc_time *tm) | |||
127 | tm->tm_wday &= 0x07; /* Not coded in BCD. */ | 127 | tm->tm_wday &= 0x07; /* Not coded in BCD. */ |
128 | tm->tm_mon &= 0x1F; | 128 | tm->tm_mon &= 0x1F; |
129 | 129 | ||
130 | BCD_TO_BIN(tm->tm_sec); | 130 | tm->tm_sec = bcd2bin(tm->tm_sec); |
131 | BCD_TO_BIN(tm->tm_min); | 131 | tm->tm_min = bcd2bin(tm->tm_min); |
132 | BCD_TO_BIN(tm->tm_hour); | 132 | tm->tm_hour = bcd2bin(tm->tm_hour); |
133 | BCD_TO_BIN(tm->tm_mday); | 133 | tm->tm_mday = bcd2bin(tm->tm_mday); |
134 | BCD_TO_BIN(tm->tm_mon); | 134 | tm->tm_mon = bcd2bin(tm->tm_mon); |
135 | tm->tm_mon--; /* Month is 1..12 in RTC but 0..11 in linux */ | 135 | tm->tm_mon--; /* Month is 1..12 in RTC but 0..11 in linux */ |
136 | } | 136 | } |
137 | 137 | ||
@@ -279,12 +279,12 @@ int pcf8563_ioctl(struct inode *inode, struct file *filp, unsigned int cmd, | |||
279 | century = (tm.tm_year >= 2000) ? 0x80 : 0; | 279 | century = (tm.tm_year >= 2000) ? 0x80 : 0; |
280 | tm.tm_year = tm.tm_year % 100; | 280 | tm.tm_year = tm.tm_year % 100; |
281 | 281 | ||
282 | BIN_TO_BCD(tm.tm_year); | 282 | tm.tm_year = bin2bcd(tm.tm_year); |
283 | BIN_TO_BCD(tm.tm_mon); | 283 | tm.tm_mon = bin2bcd(tm.tm_mon); |
284 | BIN_TO_BCD(tm.tm_mday); | 284 | tm.tm_mday = bin2bcd(tm.tm_mday); |
285 | BIN_TO_BCD(tm.tm_hour); | 285 | tm.tm_hour = bin2bcd(tm.tm_hour); |
286 | BIN_TO_BCD(tm.tm_min); | 286 | tm.tm_min = bin2bcd(tm.tm_min); |
287 | BIN_TO_BCD(tm.tm_sec); | 287 | tm.tm_sec = bin2bcd(tm.tm_sec); |
288 | tm.tm_mon |= century; | 288 | tm.tm_mon |= century; |
289 | 289 | ||
290 | mutex_lock(&rtc_lock); | 290 | mutex_lock(&rtc_lock); |
diff --git a/arch/cris/kernel/time.c b/arch/cris/kernel/time.c index ff4c6aa75def..074fe7dea96b 100644 --- a/arch/cris/kernel/time.c +++ b/arch/cris/kernel/time.c | |||
@@ -127,7 +127,7 @@ int set_rtc_mmss(unsigned long nowtime) | |||
127 | return 0; | 127 | return 0; |
128 | 128 | ||
129 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 129 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
130 | BCD_TO_BIN(cmos_minutes); | 130 | cmos_minutes = bcd2bin(cmos_minutes); |
131 | 131 | ||
132 | /* | 132 | /* |
133 | * since we're only adjusting minutes and seconds, | 133 | * since we're only adjusting minutes and seconds, |
@@ -142,8 +142,8 @@ int set_rtc_mmss(unsigned long nowtime) | |||
142 | real_minutes %= 60; | 142 | real_minutes %= 60; |
143 | 143 | ||
144 | if (abs(real_minutes - cmos_minutes) < 30) { | 144 | if (abs(real_minutes - cmos_minutes) < 30) { |
145 | BIN_TO_BCD(real_seconds); | 145 | real_seconds = bin2bcd(real_seconds); |
146 | BIN_TO_BCD(real_minutes); | 146 | real_minutes = bin2bcd(real_minutes); |
147 | CMOS_WRITE(real_seconds,RTC_SECONDS); | 147 | CMOS_WRITE(real_seconds,RTC_SECONDS); |
148 | CMOS_WRITE(real_minutes,RTC_MINUTES); | 148 | CMOS_WRITE(real_minutes,RTC_MINUTES); |
149 | } else { | 149 | } else { |
@@ -170,12 +170,12 @@ get_cmos_time(void) | |||
170 | mon = CMOS_READ(RTC_MONTH); | 170 | mon = CMOS_READ(RTC_MONTH); |
171 | year = CMOS_READ(RTC_YEAR); | 171 | year = CMOS_READ(RTC_YEAR); |
172 | 172 | ||
173 | BCD_TO_BIN(sec); | 173 | sec = bcd2bin(sec); |
174 | BCD_TO_BIN(min); | 174 | min = bcd2bin(min); |
175 | BCD_TO_BIN(hour); | 175 | hour = bcd2bin(hour); |
176 | BCD_TO_BIN(day); | 176 | day = bcd2bin(day); |
177 | BCD_TO_BIN(mon); | 177 | mon = bcd2bin(mon); |
178 | BCD_TO_BIN(year); | 178 | year = bcd2bin(year); |
179 | 179 | ||
180 | if ((year += 1900) < 1970) | 180 | if ((year += 1900) < 1970) |
181 | year += 100; | 181 | year += 100; |
diff --git a/arch/frv/Kconfig b/arch/frv/Kconfig index a5aac1b07562..9d1552a9ee2c 100644 --- a/arch/frv/Kconfig +++ b/arch/frv/Kconfig | |||
@@ -66,6 +66,8 @@ mainmenu "Fujitsu FR-V Kernel Configuration" | |||
66 | 66 | ||
67 | source "init/Kconfig" | 67 | source "init/Kconfig" |
68 | 68 | ||
69 | source "kernel/Kconfig.freezer" | ||
70 | |||
69 | 71 | ||
70 | menu "Fujitsu FR-V system setup" | 72 | menu "Fujitsu FR-V system setup" |
71 | 73 | ||
diff --git a/arch/h8300/Kconfig b/arch/h8300/Kconfig index c7966746fbfe..bd1995403c67 100644 --- a/arch/h8300/Kconfig +++ b/arch/h8300/Kconfig | |||
@@ -90,6 +90,8 @@ config HZ | |||
90 | 90 | ||
91 | source "init/Kconfig" | 91 | source "init/Kconfig" |
92 | 92 | ||
93 | source "kernel/Kconfig.freezer" | ||
94 | |||
93 | source "arch/h8300/Kconfig.cpu" | 95 | source "arch/h8300/Kconfig.cpu" |
94 | 96 | ||
95 | menu "Executable file formats" | 97 | menu "Executable file formats" |
diff --git a/arch/h8300/include/asm/thread_info.h b/arch/h8300/include/asm/thread_info.h index aafd4d322ec3..700014d2155f 100644 --- a/arch/h8300/include/asm/thread_info.h +++ b/arch/h8300/include/asm/thread_info.h | |||
@@ -89,6 +89,7 @@ static inline struct thread_info *current_thread_info(void) | |||
89 | TIF_NEED_RESCHED */ | 89 | TIF_NEED_RESCHED */ |
90 | #define TIF_MEMDIE 4 | 90 | #define TIF_MEMDIE 4 |
91 | #define TIF_RESTORE_SIGMASK 5 /* restore signal mask in do_signal() */ | 91 | #define TIF_RESTORE_SIGMASK 5 /* restore signal mask in do_signal() */ |
92 | #define TIF_FREEZE 16 /* is freezing for suspend */ | ||
92 | 93 | ||
93 | /* as above, but as bit values */ | 94 | /* as above, but as bit values */ |
94 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 95 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
@@ -96,6 +97,7 @@ static inline struct thread_info *current_thread_info(void) | |||
96 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) | 97 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) |
97 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 98 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
98 | #define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) | 99 | #define _TIF_RESTORE_SIGMASK (1<<TIF_RESTORE_SIGMASK) |
100 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
99 | 101 | ||
100 | #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ | 102 | #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ |
101 | 103 | ||
diff --git a/arch/ia64/Kconfig b/arch/ia64/Kconfig index 3b7aa38254a8..912c57db2d21 100644 --- a/arch/ia64/Kconfig +++ b/arch/ia64/Kconfig | |||
@@ -7,6 +7,8 @@ mainmenu "IA-64 Linux Kernel Configuration" | |||
7 | 7 | ||
8 | source "init/Kconfig" | 8 | source "init/Kconfig" |
9 | 9 | ||
10 | source "kernel/Kconfig.freezer" | ||
11 | |||
10 | menu "Processor type and features" | 12 | menu "Processor type and features" |
11 | 13 | ||
12 | config IA64 | 14 | config IA64 |
diff --git a/arch/ia64/hp/common/sba_iommu.c b/arch/ia64/hp/common/sba_iommu.c index 4956be40d7b5..d98f0f4ff83f 100644 --- a/arch/ia64/hp/common/sba_iommu.c +++ b/arch/ia64/hp/common/sba_iommu.c | |||
@@ -2070,14 +2070,13 @@ sba_init(void) | |||
2070 | if (!ia64_platform_is("hpzx1") && !ia64_platform_is("hpzx1_swiotlb")) | 2070 | if (!ia64_platform_is("hpzx1") && !ia64_platform_is("hpzx1_swiotlb")) |
2071 | return 0; | 2071 | return 0; |
2072 | 2072 | ||
2073 | #if defined(CONFIG_IA64_GENERIC) && defined(CONFIG_CRASH_DUMP) && \ | 2073 | #if defined(CONFIG_IA64_GENERIC) |
2074 | defined(CONFIG_PROC_FS) | ||
2075 | /* If we are booting a kdump kernel, the sba_iommu will | 2074 | /* If we are booting a kdump kernel, the sba_iommu will |
2076 | * cause devices that were not shutdown properly to MCA | 2075 | * cause devices that were not shutdown properly to MCA |
2077 | * as soon as they are turned back on. Our only option for | 2076 | * as soon as they are turned back on. Our only option for |
2078 | * a successful kdump kernel boot is to use the swiotlb. | 2077 | * a successful kdump kernel boot is to use the swiotlb. |
2079 | */ | 2078 | */ |
2080 | if (elfcorehdr_addr < ELFCORE_ADDR_MAX) { | 2079 | if (is_kdump_kernel()) { |
2081 | if (swiotlb_late_init_with_default_size(64 * (1<<20)) != 0) | 2080 | if (swiotlb_late_init_with_default_size(64 * (1<<20)) != 0) |
2082 | panic("Unable to initialize software I/O TLB:" | 2081 | panic("Unable to initialize software I/O TLB:" |
2083 | " Try machvec=dig boot option"); | 2082 | " Try machvec=dig boot option"); |
diff --git a/arch/ia64/kernel/crash_dump.c b/arch/ia64/kernel/crash_dump.c index da60e90eeeb1..23e91290e41f 100644 --- a/arch/ia64/kernel/crash_dump.c +++ b/arch/ia64/kernel/crash_dump.c | |||
@@ -8,10 +8,14 @@ | |||
8 | 8 | ||
9 | #include <linux/errno.h> | 9 | #include <linux/errno.h> |
10 | #include <linux/types.h> | 10 | #include <linux/types.h> |
11 | #include <linux/crash_dump.h> | ||
11 | 12 | ||
12 | #include <asm/page.h> | 13 | #include <asm/page.h> |
13 | #include <asm/uaccess.h> | 14 | #include <asm/uaccess.h> |
14 | 15 | ||
16 | /* Stores the physical address of elf header of crash image. */ | ||
17 | unsigned long long elfcorehdr_addr = ELFCORE_ADDR_MAX; | ||
18 | |||
15 | /** | 19 | /** |
16 | * copy_oldmem_page - copy one page from "oldmem" | 20 | * copy_oldmem_page - copy one page from "oldmem" |
17 | * @pfn: page frame number to be copied | 21 | * @pfn: page frame number to be copied |
diff --git a/arch/ia64/kernel/efi.c b/arch/ia64/kernel/efi.c index 51b75cea7018..efaff15d8cf1 100644 --- a/arch/ia64/kernel/efi.c +++ b/arch/ia64/kernel/efi.c | |||
@@ -1335,7 +1335,7 @@ kdump_find_rsvd_region (unsigned long size, struct rsvd_region *r, int n) | |||
1335 | } | 1335 | } |
1336 | #endif | 1336 | #endif |
1337 | 1337 | ||
1338 | #ifdef CONFIG_PROC_VMCORE | 1338 | #ifdef CONFIG_CRASH_DUMP |
1339 | /* locate the size find a the descriptor at a certain address */ | 1339 | /* locate the size find a the descriptor at a certain address */ |
1340 | unsigned long __init | 1340 | unsigned long __init |
1341 | vmcore_find_descriptor_size (unsigned long address) | 1341 | vmcore_find_descriptor_size (unsigned long address) |
diff --git a/arch/ia64/kernel/setup.c b/arch/ia64/kernel/setup.c index de636b215677..916ba898237f 100644 --- a/arch/ia64/kernel/setup.c +++ b/arch/ia64/kernel/setup.c | |||
@@ -352,7 +352,7 @@ reserve_memory (void) | |||
352 | } | 352 | } |
353 | #endif | 353 | #endif |
354 | 354 | ||
355 | #ifdef CONFIG_PROC_VMCORE | 355 | #ifdef CONFIG_CRASH_KERNEL |
356 | if (reserve_elfcorehdr(&rsvd_region[n].start, | 356 | if (reserve_elfcorehdr(&rsvd_region[n].start, |
357 | &rsvd_region[n].end) == 0) | 357 | &rsvd_region[n].end) == 0) |
358 | n++; | 358 | n++; |
@@ -478,7 +478,12 @@ static __init int setup_nomca(char *s) | |||
478 | } | 478 | } |
479 | early_param("nomca", setup_nomca); | 479 | early_param("nomca", setup_nomca); |
480 | 480 | ||
481 | #ifdef CONFIG_PROC_VMCORE | 481 | /* |
482 | * Note: elfcorehdr_addr is not just limited to vmcore. It is also used by | ||
483 | * is_kdump_kernel() to determine if we are booting after a panic. Hence | ||
484 | * ifdef it under CONFIG_CRASH_DUMP and not CONFIG_PROC_VMCORE. | ||
485 | */ | ||
486 | #ifdef CONFIG_CRASH_DUMP | ||
482 | /* elfcorehdr= specifies the location of elf core header | 487 | /* elfcorehdr= specifies the location of elf core header |
483 | * stored by the crashed kernel. | 488 | * stored by the crashed kernel. |
484 | */ | 489 | */ |
@@ -502,11 +507,11 @@ int __init reserve_elfcorehdr(unsigned long *start, unsigned long *end) | |||
502 | * to work properly. | 507 | * to work properly. |
503 | */ | 508 | */ |
504 | 509 | ||
505 | if (elfcorehdr_addr >= ELFCORE_ADDR_MAX) | 510 | if (!is_vmcore_usable()) |
506 | return -EINVAL; | 511 | return -EINVAL; |
507 | 512 | ||
508 | if ((length = vmcore_find_descriptor_size(elfcorehdr_addr)) == 0) { | 513 | if ((length = vmcore_find_descriptor_size(elfcorehdr_addr)) == 0) { |
509 | elfcorehdr_addr = ELFCORE_ADDR_MAX; | 514 | vmcore_unusable(); |
510 | return -EINVAL; | 515 | return -EINVAL; |
511 | } | 516 | } |
512 | 517 | ||
diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c index f482a9098e32..054bcd9439aa 100644 --- a/arch/ia64/mm/init.c +++ b/arch/ia64/mm/init.c | |||
@@ -700,23 +700,6 @@ int arch_add_memory(int nid, u64 start, u64 size) | |||
700 | 700 | ||
701 | return ret; | 701 | return ret; |
702 | } | 702 | } |
703 | #ifdef CONFIG_MEMORY_HOTREMOVE | ||
704 | int remove_memory(u64 start, u64 size) | ||
705 | { | ||
706 | unsigned long start_pfn, end_pfn; | ||
707 | unsigned long timeout = 120 * HZ; | ||
708 | int ret; | ||
709 | start_pfn = start >> PAGE_SHIFT; | ||
710 | end_pfn = start_pfn + (size >> PAGE_SHIFT); | ||
711 | ret = offline_pages(start_pfn, end_pfn, timeout); | ||
712 | if (ret) | ||
713 | goto out; | ||
714 | /* we can free mem_map at this point */ | ||
715 | out: | ||
716 | return ret; | ||
717 | } | ||
718 | EXPORT_SYMBOL_GPL(remove_memory); | ||
719 | #endif /* CONFIG_MEMORY_HOTREMOVE */ | ||
720 | #endif | 703 | #endif |
721 | 704 | ||
722 | /* | 705 | /* |
diff --git a/arch/m32r/Kconfig b/arch/m32r/Kconfig index 00289c178f89..dbaed4a63815 100644 --- a/arch/m32r/Kconfig +++ b/arch/m32r/Kconfig | |||
@@ -42,6 +42,8 @@ config HZ | |||
42 | 42 | ||
43 | source "init/Kconfig" | 43 | source "init/Kconfig" |
44 | 44 | ||
45 | source "kernel/Kconfig.freezer" | ||
46 | |||
45 | 47 | ||
46 | menu "Processor type and features" | 48 | menu "Processor type and features" |
47 | 49 | ||
diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig index 677c93a490f6..836fb66f080d 100644 --- a/arch/m68k/Kconfig +++ b/arch/m68k/Kconfig | |||
@@ -62,6 +62,8 @@ mainmenu "Linux/68k Kernel Configuration" | |||
62 | 62 | ||
63 | source "init/Kconfig" | 63 | source "init/Kconfig" |
64 | 64 | ||
65 | source "kernel/Kconfig.freezer" | ||
66 | |||
65 | menu "Platform dependent setup" | 67 | menu "Platform dependent setup" |
66 | 68 | ||
67 | config EISA | 69 | config EISA |
diff --git a/arch/m68k/bvme6000/rtc.c b/arch/m68k/bvme6000/rtc.c index 808c9018b115..c50bec8aabb1 100644 --- a/arch/m68k/bvme6000/rtc.c +++ b/arch/m68k/bvme6000/rtc.c | |||
@@ -18,7 +18,6 @@ | |||
18 | #include <linux/poll.h> | 18 | #include <linux/poll.h> |
19 | #include <linux/module.h> | 19 | #include <linux/module.h> |
20 | #include <linux/mc146818rtc.h> /* For struct rtc_time and ioctls, etc */ | 20 | #include <linux/mc146818rtc.h> /* For struct rtc_time and ioctls, etc */ |
21 | #include <linux/smp_lock.h> | ||
22 | #include <linux/bcd.h> | 21 | #include <linux/bcd.h> |
23 | #include <asm/bvme6000hw.h> | 22 | #include <asm/bvme6000hw.h> |
24 | 23 | ||
diff --git a/arch/m68knommu/Kconfig b/arch/m68knommu/Kconfig index 0a8998315e5e..76b66feb74df 100644 --- a/arch/m68knommu/Kconfig +++ b/arch/m68knommu/Kconfig | |||
@@ -75,6 +75,8 @@ config NO_IOPORT | |||
75 | 75 | ||
76 | source "init/Kconfig" | 76 | source "init/Kconfig" |
77 | 77 | ||
78 | source "kernel/Kconfig.freezer" | ||
79 | |||
78 | menu "Processor type and features" | 80 | menu "Processor type and features" |
79 | 81 | ||
80 | choice | 82 | choice |
diff --git a/arch/m68knommu/include/asm/thread_info.h b/arch/m68knommu/include/asm/thread_info.h index 0c9bc095f3f0..82529f424ea3 100644 --- a/arch/m68knommu/include/asm/thread_info.h +++ b/arch/m68knommu/include/asm/thread_info.h | |||
@@ -84,12 +84,14 @@ static inline struct thread_info *current_thread_info(void) | |||
84 | #define TIF_POLLING_NRFLAG 3 /* true if poll_idle() is polling | 84 | #define TIF_POLLING_NRFLAG 3 /* true if poll_idle() is polling |
85 | TIF_NEED_RESCHED */ | 85 | TIF_NEED_RESCHED */ |
86 | #define TIF_MEMDIE 4 | 86 | #define TIF_MEMDIE 4 |
87 | #define TIF_FREEZE 16 /* is freezing for suspend */ | ||
87 | 88 | ||
88 | /* as above, but as bit values */ | 89 | /* as above, but as bit values */ |
89 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 90 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
90 | #define _TIF_SIGPENDING (1<<TIF_SIGPENDING) | 91 | #define _TIF_SIGPENDING (1<<TIF_SIGPENDING) |
91 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) | 92 | #define _TIF_NEED_RESCHED (1<<TIF_NEED_RESCHED) |
92 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 93 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
94 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
93 | 95 | ||
94 | #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ | 96 | #define _TIF_WORK_MASK 0x0000FFFE /* work to do on interrupt/exception return */ |
95 | 97 | ||
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig index b905744d7915..5f149b030c0f 100644 --- a/arch/mips/Kconfig +++ b/arch/mips/Kconfig | |||
@@ -1885,6 +1885,8 @@ config PROBE_INITRD_HEADER | |||
1885 | add initrd or initramfs image to the kernel image. | 1885 | add initrd or initramfs image to the kernel image. |
1886 | Otherwise, say N. | 1886 | Otherwise, say N. |
1887 | 1887 | ||
1888 | source "kernel/Kconfig.freezer" | ||
1889 | |||
1888 | menu "Bus options (PCI, PCMCIA, EISA, ISA, TC)" | 1890 | menu "Bus options (PCI, PCMCIA, EISA, ISA, TC)" |
1889 | 1891 | ||
1890 | config HW_HAS_EISA | 1892 | config HW_HAS_EISA |
diff --git a/arch/mips/dec/time.c b/arch/mips/dec/time.c index 3965fda94a89..1359c03ded51 100644 --- a/arch/mips/dec/time.c +++ b/arch/mips/dec/time.c | |||
@@ -45,12 +45,12 @@ unsigned long read_persistent_clock(void) | |||
45 | spin_unlock_irqrestore(&rtc_lock, flags); | 45 | spin_unlock_irqrestore(&rtc_lock, flags); |
46 | 46 | ||
47 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 47 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
48 | sec = BCD2BIN(sec); | 48 | sec = bcd2bin(sec); |
49 | min = BCD2BIN(min); | 49 | min = bcd2bin(min); |
50 | hour = BCD2BIN(hour); | 50 | hour = bcd2bin(hour); |
51 | day = BCD2BIN(day); | 51 | day = bcd2bin(day); |
52 | mon = BCD2BIN(mon); | 52 | mon = bcd2bin(mon); |
53 | year = BCD2BIN(year); | 53 | year = bcd2bin(year); |
54 | } | 54 | } |
55 | 55 | ||
56 | year += real_year - 72 + 2000; | 56 | year += real_year - 72 + 2000; |
@@ -83,7 +83,7 @@ int rtc_mips_set_mmss(unsigned long nowtime) | |||
83 | 83 | ||
84 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 84 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
85 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 85 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) |
86 | cmos_minutes = BCD2BIN(cmos_minutes); | 86 | cmos_minutes = bcd2bin(cmos_minutes); |
87 | 87 | ||
88 | /* | 88 | /* |
89 | * since we're only adjusting minutes and seconds, | 89 | * since we're only adjusting minutes and seconds, |
@@ -99,8 +99,8 @@ int rtc_mips_set_mmss(unsigned long nowtime) | |||
99 | 99 | ||
100 | if (abs(real_minutes - cmos_minutes) < 30) { | 100 | if (abs(real_minutes - cmos_minutes) < 30) { |
101 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 101 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
102 | real_seconds = BIN2BCD(real_seconds); | 102 | real_seconds = bin2bcd(real_seconds); |
103 | real_minutes = BIN2BCD(real_minutes); | 103 | real_minutes = bin2bcd(real_minutes); |
104 | } | 104 | } |
105 | CMOS_WRITE(real_seconds, RTC_SECONDS); | 105 | CMOS_WRITE(real_seconds, RTC_SECONDS); |
106 | CMOS_WRITE(real_minutes, RTC_MINUTES); | 106 | CMOS_WRITE(real_minutes, RTC_MINUTES); |
diff --git a/arch/mips/include/asm/mc146818-time.h b/arch/mips/include/asm/mc146818-time.h index cdc379a0a94e..199b45733a95 100644 --- a/arch/mips/include/asm/mc146818-time.h +++ b/arch/mips/include/asm/mc146818-time.h | |||
@@ -44,7 +44,7 @@ static inline int mc146818_set_rtc_mmss(unsigned long nowtime) | |||
44 | 44 | ||
45 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 45 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
46 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 46 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) |
47 | BCD_TO_BIN(cmos_minutes); | 47 | cmos_minutes = bcd2bin(cmos_minutes); |
48 | 48 | ||
49 | /* | 49 | /* |
50 | * since we're only adjusting minutes and seconds, | 50 | * since we're only adjusting minutes and seconds, |
@@ -60,8 +60,8 @@ static inline int mc146818_set_rtc_mmss(unsigned long nowtime) | |||
60 | 60 | ||
61 | if (abs(real_minutes - cmos_minutes) < 30) { | 61 | if (abs(real_minutes - cmos_minutes) < 30) { |
62 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 62 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
63 | BIN_TO_BCD(real_seconds); | 63 | real_seconds = bin2bcd(real_seconds); |
64 | BIN_TO_BCD(real_minutes); | 64 | real_minutes = bin2bcd(real_minutes); |
65 | } | 65 | } |
66 | CMOS_WRITE(real_seconds, RTC_SECONDS); | 66 | CMOS_WRITE(real_seconds, RTC_SECONDS); |
67 | CMOS_WRITE(real_minutes, RTC_MINUTES); | 67 | CMOS_WRITE(real_minutes, RTC_MINUTES); |
@@ -103,12 +103,12 @@ static inline unsigned long mc146818_get_cmos_time(void) | |||
103 | } while (sec != CMOS_READ(RTC_SECONDS)); | 103 | } while (sec != CMOS_READ(RTC_SECONDS)); |
104 | 104 | ||
105 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 105 | if (!(CMOS_READ(RTC_CONTROL) & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
106 | BCD_TO_BIN(sec); | 106 | sec = bcd2bin(sec); |
107 | BCD_TO_BIN(min); | 107 | min = bcd2bin(min); |
108 | BCD_TO_BIN(hour); | 108 | hour = bcd2bin(hour); |
109 | BCD_TO_BIN(day); | 109 | day = bcd2bin(day); |
110 | BCD_TO_BIN(mon); | 110 | mon = bcd2bin(mon); |
111 | BCD_TO_BIN(year); | 111 | year = bcd2bin(year); |
112 | } | 112 | } |
113 | spin_unlock_irqrestore(&rtc_lock, flags); | 113 | spin_unlock_irqrestore(&rtc_lock, flags); |
114 | year = mc146818_decode_year(year); | 114 | year = mc146818_decode_year(year); |
diff --git a/arch/mips/pmc-sierra/yosemite/setup.c b/arch/mips/pmc-sierra/yosemite/setup.c index 6537d90a25bb..2d3c0dca275d 100644 --- a/arch/mips/pmc-sierra/yosemite/setup.c +++ b/arch/mips/pmc-sierra/yosemite/setup.c | |||
@@ -79,14 +79,14 @@ unsigned long read_persistent_clock(void) | |||
79 | /* Stop the update to the time */ | 79 | /* Stop the update to the time */ |
80 | m48t37_base->control = 0x40; | 80 | m48t37_base->control = 0x40; |
81 | 81 | ||
82 | year = BCD2BIN(m48t37_base->year); | 82 | year = bcd2bin(m48t37_base->year); |
83 | year += BCD2BIN(m48t37_base->century) * 100; | 83 | year += bcd2bin(m48t37_base->century) * 100; |
84 | 84 | ||
85 | month = BCD2BIN(m48t37_base->month); | 85 | month = bcd2bin(m48t37_base->month); |
86 | day = BCD2BIN(m48t37_base->date); | 86 | day = bcd2bin(m48t37_base->date); |
87 | hour = BCD2BIN(m48t37_base->hour); | 87 | hour = bcd2bin(m48t37_base->hour); |
88 | min = BCD2BIN(m48t37_base->min); | 88 | min = bcd2bin(m48t37_base->min); |
89 | sec = BCD2BIN(m48t37_base->sec); | 89 | sec = bcd2bin(m48t37_base->sec); |
90 | 90 | ||
91 | /* Start the update to the time again */ | 91 | /* Start the update to the time again */ |
92 | m48t37_base->control = 0x00; | 92 | m48t37_base->control = 0x00; |
@@ -113,22 +113,22 @@ int rtc_mips_set_time(unsigned long tim) | |||
113 | m48t37_base->control = 0x80; | 113 | m48t37_base->control = 0x80; |
114 | 114 | ||
115 | /* year */ | 115 | /* year */ |
116 | m48t37_base->year = BIN2BCD(tm.tm_year % 100); | 116 | m48t37_base->year = bin2bcd(tm.tm_year % 100); |
117 | m48t37_base->century = BIN2BCD(tm.tm_year / 100); | 117 | m48t37_base->century = bin2bcd(tm.tm_year / 100); |
118 | 118 | ||
119 | /* month */ | 119 | /* month */ |
120 | m48t37_base->month = BIN2BCD(tm.tm_mon); | 120 | m48t37_base->month = bin2bcd(tm.tm_mon); |
121 | 121 | ||
122 | /* day */ | 122 | /* day */ |
123 | m48t37_base->date = BIN2BCD(tm.tm_mday); | 123 | m48t37_base->date = bin2bcd(tm.tm_mday); |
124 | 124 | ||
125 | /* hour/min/sec */ | 125 | /* hour/min/sec */ |
126 | m48t37_base->hour = BIN2BCD(tm.tm_hour); | 126 | m48t37_base->hour = bin2bcd(tm.tm_hour); |
127 | m48t37_base->min = BIN2BCD(tm.tm_min); | 127 | m48t37_base->min = bin2bcd(tm.tm_min); |
128 | m48t37_base->sec = BIN2BCD(tm.tm_sec); | 128 | m48t37_base->sec = bin2bcd(tm.tm_sec); |
129 | 129 | ||
130 | /* day of week -- not really used, but let's keep it up-to-date */ | 130 | /* day of week -- not really used, but let's keep it up-to-date */ |
131 | m48t37_base->day = BIN2BCD(tm.tm_wday + 1); | 131 | m48t37_base->day = bin2bcd(tm.tm_wday + 1); |
132 | 132 | ||
133 | /* disable writing */ | 133 | /* disable writing */ |
134 | m48t37_base->control = 0x00; | 134 | m48t37_base->control = 0x00; |
diff --git a/arch/mips/sibyte/swarm/rtc_m41t81.c b/arch/mips/sibyte/swarm/rtc_m41t81.c index 26fbff4c15b1..b732600b47f5 100644 --- a/arch/mips/sibyte/swarm/rtc_m41t81.c +++ b/arch/mips/sibyte/swarm/rtc_m41t81.c | |||
@@ -156,32 +156,32 @@ int m41t81_set_time(unsigned long t) | |||
156 | */ | 156 | */ |
157 | 157 | ||
158 | spin_lock_irqsave(&rtc_lock, flags); | 158 | spin_lock_irqsave(&rtc_lock, flags); |
159 | tm.tm_sec = BIN2BCD(tm.tm_sec); | 159 | tm.tm_sec = bin2bcd(tm.tm_sec); |
160 | m41t81_write(M41T81REG_SC, tm.tm_sec); | 160 | m41t81_write(M41T81REG_SC, tm.tm_sec); |
161 | 161 | ||
162 | tm.tm_min = BIN2BCD(tm.tm_min); | 162 | tm.tm_min = bin2bcd(tm.tm_min); |
163 | m41t81_write(M41T81REG_MN, tm.tm_min); | 163 | m41t81_write(M41T81REG_MN, tm.tm_min); |
164 | 164 | ||
165 | tm.tm_hour = BIN2BCD(tm.tm_hour); | 165 | tm.tm_hour = bin2bcd(tm.tm_hour); |
166 | tm.tm_hour = (tm.tm_hour & 0x3f) | (m41t81_read(M41T81REG_HR) & 0xc0); | 166 | tm.tm_hour = (tm.tm_hour & 0x3f) | (m41t81_read(M41T81REG_HR) & 0xc0); |
167 | m41t81_write(M41T81REG_HR, tm.tm_hour); | 167 | m41t81_write(M41T81REG_HR, tm.tm_hour); |
168 | 168 | ||
169 | /* tm_wday starts from 0 to 6 */ | 169 | /* tm_wday starts from 0 to 6 */ |
170 | if (tm.tm_wday == 0) tm.tm_wday = 7; | 170 | if (tm.tm_wday == 0) tm.tm_wday = 7; |
171 | tm.tm_wday = BIN2BCD(tm.tm_wday); | 171 | tm.tm_wday = bin2bcd(tm.tm_wday); |
172 | m41t81_write(M41T81REG_DY, tm.tm_wday); | 172 | m41t81_write(M41T81REG_DY, tm.tm_wday); |
173 | 173 | ||
174 | tm.tm_mday = BIN2BCD(tm.tm_mday); | 174 | tm.tm_mday = bin2bcd(tm.tm_mday); |
175 | m41t81_write(M41T81REG_DT, tm.tm_mday); | 175 | m41t81_write(M41T81REG_DT, tm.tm_mday); |
176 | 176 | ||
177 | /* tm_mon starts from 0, *ick* */ | 177 | /* tm_mon starts from 0, *ick* */ |
178 | tm.tm_mon ++; | 178 | tm.tm_mon ++; |
179 | tm.tm_mon = BIN2BCD(tm.tm_mon); | 179 | tm.tm_mon = bin2bcd(tm.tm_mon); |
180 | m41t81_write(M41T81REG_MO, tm.tm_mon); | 180 | m41t81_write(M41T81REG_MO, tm.tm_mon); |
181 | 181 | ||
182 | /* we don't do century, everything is beyond 2000 */ | 182 | /* we don't do century, everything is beyond 2000 */ |
183 | tm.tm_year %= 100; | 183 | tm.tm_year %= 100; |
184 | tm.tm_year = BIN2BCD(tm.tm_year); | 184 | tm.tm_year = bin2bcd(tm.tm_year); |
185 | m41t81_write(M41T81REG_YR, tm.tm_year); | 185 | m41t81_write(M41T81REG_YR, tm.tm_year); |
186 | spin_unlock_irqrestore(&rtc_lock, flags); | 186 | spin_unlock_irqrestore(&rtc_lock, flags); |
187 | 187 | ||
@@ -209,12 +209,12 @@ unsigned long m41t81_get_time(void) | |||
209 | year = m41t81_read(M41T81REG_YR); | 209 | year = m41t81_read(M41T81REG_YR); |
210 | spin_unlock_irqrestore(&rtc_lock, flags); | 210 | spin_unlock_irqrestore(&rtc_lock, flags); |
211 | 211 | ||
212 | sec = BCD2BIN(sec); | 212 | sec = bcd2bin(sec); |
213 | min = BCD2BIN(min); | 213 | min = bcd2bin(min); |
214 | hour = BCD2BIN(hour); | 214 | hour = bcd2bin(hour); |
215 | day = BCD2BIN(day); | 215 | day = bcd2bin(day); |
216 | mon = BCD2BIN(mon); | 216 | mon = bcd2bin(mon); |
217 | year = BCD2BIN(year); | 217 | year = bcd2bin(year); |
218 | 218 | ||
219 | year += 2000; | 219 | year += 2000; |
220 | 220 | ||
diff --git a/arch/mips/sibyte/swarm/rtc_xicor1241.c b/arch/mips/sibyte/swarm/rtc_xicor1241.c index ff3e5dabb348..4438b2195c44 100644 --- a/arch/mips/sibyte/swarm/rtc_xicor1241.c +++ b/arch/mips/sibyte/swarm/rtc_xicor1241.c | |||
@@ -124,18 +124,18 @@ int xicor_set_time(unsigned long t) | |||
124 | xicor_write(X1241REG_SR, X1241REG_SR_WEL | X1241REG_SR_RWEL); | 124 | xicor_write(X1241REG_SR, X1241REG_SR_WEL | X1241REG_SR_RWEL); |
125 | 125 | ||
126 | /* trivial ones */ | 126 | /* trivial ones */ |
127 | tm.tm_sec = BIN2BCD(tm.tm_sec); | 127 | tm.tm_sec = bin2bcd(tm.tm_sec); |
128 | xicor_write(X1241REG_SC, tm.tm_sec); | 128 | xicor_write(X1241REG_SC, tm.tm_sec); |
129 | 129 | ||
130 | tm.tm_min = BIN2BCD(tm.tm_min); | 130 | tm.tm_min = bin2bcd(tm.tm_min); |
131 | xicor_write(X1241REG_MN, tm.tm_min); | 131 | xicor_write(X1241REG_MN, tm.tm_min); |
132 | 132 | ||
133 | tm.tm_mday = BIN2BCD(tm.tm_mday); | 133 | tm.tm_mday = bin2bcd(tm.tm_mday); |
134 | xicor_write(X1241REG_DT, tm.tm_mday); | 134 | xicor_write(X1241REG_DT, tm.tm_mday); |
135 | 135 | ||
136 | /* tm_mon starts from 0, *ick* */ | 136 | /* tm_mon starts from 0, *ick* */ |
137 | tm.tm_mon ++; | 137 | tm.tm_mon ++; |
138 | tm.tm_mon = BIN2BCD(tm.tm_mon); | 138 | tm.tm_mon = bin2bcd(tm.tm_mon); |
139 | xicor_write(X1241REG_MO, tm.tm_mon); | 139 | xicor_write(X1241REG_MO, tm.tm_mon); |
140 | 140 | ||
141 | /* year is split */ | 141 | /* year is split */ |
@@ -148,7 +148,7 @@ int xicor_set_time(unsigned long t) | |||
148 | tmp = xicor_read(X1241REG_HR); | 148 | tmp = xicor_read(X1241REG_HR); |
149 | if (tmp & X1241REG_HR_MIL) { | 149 | if (tmp & X1241REG_HR_MIL) { |
150 | /* 24 hour format */ | 150 | /* 24 hour format */ |
151 | tm.tm_hour = BIN2BCD(tm.tm_hour); | 151 | tm.tm_hour = bin2bcd(tm.tm_hour); |
152 | tmp = (tmp & ~0x3f) | (tm.tm_hour & 0x3f); | 152 | tmp = (tmp & ~0x3f) | (tm.tm_hour & 0x3f); |
153 | } else { | 153 | } else { |
154 | /* 12 hour format, with 0x2 for pm */ | 154 | /* 12 hour format, with 0x2 for pm */ |
@@ -157,7 +157,7 @@ int xicor_set_time(unsigned long t) | |||
157 | tmp |= 0x20; | 157 | tmp |= 0x20; |
158 | tm.tm_hour -= 12; | 158 | tm.tm_hour -= 12; |
159 | } | 159 | } |
160 | tm.tm_hour = BIN2BCD(tm.tm_hour); | 160 | tm.tm_hour = bin2bcd(tm.tm_hour); |
161 | tmp |= tm.tm_hour; | 161 | tmp |= tm.tm_hour; |
162 | } | 162 | } |
163 | xicor_write(X1241REG_HR, tmp); | 163 | xicor_write(X1241REG_HR, tmp); |
@@ -191,13 +191,13 @@ unsigned long xicor_get_time(void) | |||
191 | y2k = xicor_read(X1241REG_Y2K); | 191 | y2k = xicor_read(X1241REG_Y2K); |
192 | spin_unlock_irqrestore(&rtc_lock, flags); | 192 | spin_unlock_irqrestore(&rtc_lock, flags); |
193 | 193 | ||
194 | sec = BCD2BIN(sec); | 194 | sec = bcd2bin(sec); |
195 | min = BCD2BIN(min); | 195 | min = bcd2bin(min); |
196 | hour = BCD2BIN(hour); | 196 | hour = bcd2bin(hour); |
197 | day = BCD2BIN(day); | 197 | day = bcd2bin(day); |
198 | mon = BCD2BIN(mon); | 198 | mon = bcd2bin(mon); |
199 | year = BCD2BIN(year); | 199 | year = bcd2bin(year); |
200 | y2k = BCD2BIN(y2k); | 200 | y2k = bcd2bin(y2k); |
201 | 201 | ||
202 | year += (y2k * 100); | 202 | year += (y2k * 100); |
203 | 203 | ||
diff --git a/arch/mn10300/Kconfig b/arch/mn10300/Kconfig index dd557c9cf001..9a9f43358879 100644 --- a/arch/mn10300/Kconfig +++ b/arch/mn10300/Kconfig | |||
@@ -68,6 +68,8 @@ mainmenu "Matsushita MN10300/AM33 Kernel Configuration" | |||
68 | 68 | ||
69 | source "init/Kconfig" | 69 | source "init/Kconfig" |
70 | 70 | ||
71 | source "kernel/Kconfig.freezer" | ||
72 | |||
71 | 73 | ||
72 | menu "Matsushita MN10300 system setup" | 74 | menu "Matsushita MN10300 system setup" |
73 | 75 | ||
diff --git a/arch/mn10300/kernel/rtc.c b/arch/mn10300/kernel/rtc.c index 042f792d8430..7978470b5749 100644 --- a/arch/mn10300/kernel/rtc.c +++ b/arch/mn10300/kernel/rtc.c | |||
@@ -67,7 +67,7 @@ static int set_rtc_mmss(unsigned long nowtime) | |||
67 | 67 | ||
68 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 68 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
69 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 69 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) |
70 | BCD_TO_BIN(cmos_minutes); | 70 | cmos_minutes = bcd2bin(cmos_minutes); |
71 | 71 | ||
72 | /* | 72 | /* |
73 | * since we're only adjusting minutes and seconds, | 73 | * since we're only adjusting minutes and seconds, |
@@ -84,8 +84,8 @@ static int set_rtc_mmss(unsigned long nowtime) | |||
84 | 84 | ||
85 | if (abs(real_minutes - cmos_minutes) < 30) { | 85 | if (abs(real_minutes - cmos_minutes) < 30) { |
86 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 86 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
87 | BIN_TO_BCD(real_seconds); | 87 | real_seconds = bin2bcd(real_seconds); |
88 | BIN_TO_BCD(real_minutes); | 88 | real_minutes = bin2bcd(real_minutes); |
89 | } | 89 | } |
90 | CMOS_WRITE(real_seconds, RTC_SECONDS); | 90 | CMOS_WRITE(real_seconds, RTC_SECONDS); |
91 | CMOS_WRITE(real_minutes, RTC_MINUTES); | 91 | CMOS_WRITE(real_minutes, RTC_MINUTES); |
diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig index 8313fccced5e..2bd1f6ef5db0 100644 --- a/arch/parisc/Kconfig +++ b/arch/parisc/Kconfig | |||
@@ -90,6 +90,8 @@ config ARCH_MAY_HAVE_PC_FDC | |||
90 | 90 | ||
91 | source "init/Kconfig" | 91 | source "init/Kconfig" |
92 | 92 | ||
93 | source "kernel/Kconfig.freezer" | ||
94 | |||
93 | 95 | ||
94 | menu "Processor type and features" | 96 | menu "Processor type and features" |
95 | 97 | ||
diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig index 380baa1780e9..9391199d9e77 100644 --- a/arch/powerpc/Kconfig +++ b/arch/powerpc/Kconfig | |||
@@ -230,6 +230,8 @@ config PPC_OF_PLATFORM_PCI | |||
230 | 230 | ||
231 | source "init/Kconfig" | 231 | source "init/Kconfig" |
232 | 232 | ||
233 | source "kernel/Kconfig.freezer" | ||
234 | |||
233 | source "arch/powerpc/sysdev/Kconfig" | 235 | source "arch/powerpc/sysdev/Kconfig" |
234 | source "arch/powerpc/platforms/Kconfig" | 236 | source "arch/powerpc/platforms/Kconfig" |
235 | 237 | ||
diff --git a/arch/powerpc/include/asm/ps3av.h b/arch/powerpc/include/asm/ps3av.h index fda98715cd35..5aa22cffdbd6 100644 --- a/arch/powerpc/include/asm/ps3av.h +++ b/arch/powerpc/include/asm/ps3av.h | |||
@@ -678,6 +678,8 @@ struct ps3av_pkt_avb_param { | |||
678 | u8 buf[PS3AV_PKT_AVB_PARAM_MAX_BUF_SIZE]; | 678 | u8 buf[PS3AV_PKT_AVB_PARAM_MAX_BUF_SIZE]; |
679 | }; | 679 | }; |
680 | 680 | ||
681 | /* channel status */ | ||
682 | extern u8 ps3av_mode_cs_info[]; | ||
681 | 683 | ||
682 | /** command status **/ | 684 | /** command status **/ |
683 | #define PS3AV_STATUS_SUCCESS 0x0000 /* success */ | 685 | #define PS3AV_STATUS_SUCCESS 0x0000 /* success */ |
@@ -735,6 +737,7 @@ extern int ps3av_get_mode(void); | |||
735 | extern int ps3av_video_mode2res(u32, u32 *, u32 *); | 737 | extern int ps3av_video_mode2res(u32, u32 *, u32 *); |
736 | extern int ps3av_video_mute(int); | 738 | extern int ps3av_video_mute(int); |
737 | extern int ps3av_audio_mute(int); | 739 | extern int ps3av_audio_mute(int); |
740 | extern int ps3av_audio_mute_analog(int); | ||
738 | extern int ps3av_dev_open(void); | 741 | extern int ps3av_dev_open(void); |
739 | extern int ps3av_dev_close(void); | 742 | extern int ps3av_dev_close(void); |
740 | extern void ps3av_register_flip_ctl(void (*flip_ctl)(int on, void *data), | 743 | extern void ps3av_register_flip_ctl(void (*flip_ctl)(int on, void *data), |
diff --git a/arch/powerpc/kernel/crash_dump.c b/arch/powerpc/kernel/crash_dump.c index a323c9b32ee1..97e056379728 100644 --- a/arch/powerpc/kernel/crash_dump.c +++ b/arch/powerpc/kernel/crash_dump.c | |||
@@ -27,6 +27,9 @@ | |||
27 | #define DBG(fmt...) | 27 | #define DBG(fmt...) |
28 | #endif | 28 | #endif |
29 | 29 | ||
30 | /* Stores the physical address of elf header of crash image. */ | ||
31 | unsigned long long elfcorehdr_addr = ELFCORE_ADDR_MAX; | ||
32 | |||
30 | void __init reserve_kdump_trampoline(void) | 33 | void __init reserve_kdump_trampoline(void) |
31 | { | 34 | { |
32 | lmb_reserve(0, KDUMP_RESERVE_LIMIT); | 35 | lmb_reserve(0, KDUMP_RESERVE_LIMIT); |
@@ -66,7 +69,11 @@ void __init setup_kdump_trampoline(void) | |||
66 | DBG(" <- setup_kdump_trampoline()\n"); | 69 | DBG(" <- setup_kdump_trampoline()\n"); |
67 | } | 70 | } |
68 | 71 | ||
69 | #ifdef CONFIG_PROC_VMCORE | 72 | /* |
73 | * Note: elfcorehdr_addr is not just limited to vmcore. It is also used by | ||
74 | * is_kdump_kernel() to determine if we are booting after a panic. Hence | ||
75 | * ifdef it under CONFIG_CRASH_DUMP and not CONFIG_PROC_VMCORE. | ||
76 | */ | ||
70 | static int __init parse_elfcorehdr(char *p) | 77 | static int __init parse_elfcorehdr(char *p) |
71 | { | 78 | { |
72 | if (p) | 79 | if (p) |
@@ -75,7 +82,6 @@ static int __init parse_elfcorehdr(char *p) | |||
75 | return 1; | 82 | return 1; |
76 | } | 83 | } |
77 | __setup("elfcorehdr=", parse_elfcorehdr); | 84 | __setup("elfcorehdr=", parse_elfcorehdr); |
78 | #endif | ||
79 | 85 | ||
80 | static int __init parse_savemaxmem(char *p) | 86 | static int __init parse_savemaxmem(char *p) |
81 | { | 87 | { |
diff --git a/arch/powerpc/mm/mem.c b/arch/powerpc/mm/mem.c index 98d7bf99533a..b9e1a1da6e52 100644 --- a/arch/powerpc/mm/mem.c +++ b/arch/powerpc/mm/mem.c | |||
@@ -134,23 +134,6 @@ int arch_add_memory(int nid, u64 start, u64 size) | |||
134 | 134 | ||
135 | return __add_pages(zone, start_pfn, nr_pages); | 135 | return __add_pages(zone, start_pfn, nr_pages); |
136 | } | 136 | } |
137 | |||
138 | #ifdef CONFIG_MEMORY_HOTREMOVE | ||
139 | int remove_memory(u64 start, u64 size) | ||
140 | { | ||
141 | unsigned long start_pfn, end_pfn; | ||
142 | int ret; | ||
143 | |||
144 | start_pfn = start >> PAGE_SHIFT; | ||
145 | end_pfn = start_pfn + (size >> PAGE_SHIFT); | ||
146 | ret = offline_pages(start_pfn, end_pfn, 120 * HZ); | ||
147 | if (ret) | ||
148 | goto out; | ||
149 | /* Arch-specific calls go here - next patch */ | ||
150 | out: | ||
151 | return ret; | ||
152 | } | ||
153 | #endif /* CONFIG_MEMORY_HOTREMOVE */ | ||
154 | #endif /* CONFIG_MEMORY_HOTPLUG */ | 137 | #endif /* CONFIG_MEMORY_HOTPLUG */ |
155 | 138 | ||
156 | /* | 139 | /* |
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig index bc581d8a7cd9..70b7645ce745 100644 --- a/arch/s390/Kconfig +++ b/arch/s390/Kconfig | |||
@@ -78,6 +78,8 @@ config S390 | |||
78 | 78 | ||
79 | source "init/Kconfig" | 79 | source "init/Kconfig" |
80 | 80 | ||
81 | source "kernel/Kconfig.freezer" | ||
82 | |||
81 | menu "Base setup" | 83 | menu "Base setup" |
82 | 84 | ||
83 | comment "Processor type and features" | 85 | comment "Processor type and features" |
diff --git a/arch/s390/include/asm/thread_info.h b/arch/s390/include/asm/thread_info.h index ea40a9d690fc..de3fad60c682 100644 --- a/arch/s390/include/asm/thread_info.h +++ b/arch/s390/include/asm/thread_info.h | |||
@@ -99,6 +99,7 @@ static inline struct thread_info *current_thread_info(void) | |||
99 | #define TIF_31BIT 18 /* 32bit process */ | 99 | #define TIF_31BIT 18 /* 32bit process */ |
100 | #define TIF_MEMDIE 19 | 100 | #define TIF_MEMDIE 19 |
101 | #define TIF_RESTORE_SIGMASK 20 /* restore signal mask in do_signal() */ | 101 | #define TIF_RESTORE_SIGMASK 20 /* restore signal mask in do_signal() */ |
102 | #define TIF_FREEZE 21 /* thread is freezing for suspend */ | ||
102 | 103 | ||
103 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 104 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
104 | #define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME) | 105 | #define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME) |
@@ -112,6 +113,7 @@ static inline struct thread_info *current_thread_info(void) | |||
112 | #define _TIF_USEDFPU (1<<TIF_USEDFPU) | 113 | #define _TIF_USEDFPU (1<<TIF_USEDFPU) |
113 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 114 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
114 | #define _TIF_31BIT (1<<TIF_31BIT) | 115 | #define _TIF_31BIT (1<<TIF_31BIT) |
116 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
115 | 117 | ||
116 | #endif /* __KERNEL__ */ | 118 | #endif /* __KERNEL__ */ |
117 | 119 | ||
diff --git a/arch/s390/mm/init.c b/arch/s390/mm/init.c index 1169130a97ef..158b0d6d7046 100644 --- a/arch/s390/mm/init.c +++ b/arch/s390/mm/init.c | |||
@@ -189,14 +189,3 @@ int arch_add_memory(int nid, u64 start, u64 size) | |||
189 | return rc; | 189 | return rc; |
190 | } | 190 | } |
191 | #endif /* CONFIG_MEMORY_HOTPLUG */ | 191 | #endif /* CONFIG_MEMORY_HOTPLUG */ |
192 | |||
193 | #ifdef CONFIG_MEMORY_HOTREMOVE | ||
194 | int remove_memory(u64 start, u64 size) | ||
195 | { | ||
196 | unsigned long start_pfn, end_pfn; | ||
197 | |||
198 | start_pfn = PFN_DOWN(start); | ||
199 | end_pfn = start_pfn + PFN_DOWN(size); | ||
200 | return offline_pages(start_pfn, end_pfn, 120 * HZ); | ||
201 | } | ||
202 | #endif /* CONFIG_MEMORY_HOTREMOVE */ | ||
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index b4aa2a03e19b..cb2c87df70ce 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig | |||
@@ -121,6 +121,8 @@ config IO_TRAPPED | |||
121 | 121 | ||
122 | source "init/Kconfig" | 122 | source "init/Kconfig" |
123 | 123 | ||
124 | source "kernel/Kconfig.freezer" | ||
125 | |||
124 | menu "System type" | 126 | menu "System type" |
125 | 127 | ||
126 | # | 128 | # |
diff --git a/arch/sh/kernel/crash_dump.c b/arch/sh/kernel/crash_dump.c index 4a2ecbe27d8e..95d216255565 100644 --- a/arch/sh/kernel/crash_dump.c +++ b/arch/sh/kernel/crash_dump.c | |||
@@ -10,6 +10,9 @@ | |||
10 | #include <linux/io.h> | 10 | #include <linux/io.h> |
11 | #include <asm/uaccess.h> | 11 | #include <asm/uaccess.h> |
12 | 12 | ||
13 | /* Stores the physical address of elf header of crash image. */ | ||
14 | unsigned long long elfcorehdr_addr = ELFCORE_ADDR_MAX; | ||
15 | |||
13 | /** | 16 | /** |
14 | * copy_oldmem_page - copy one page from "oldmem" | 17 | * copy_oldmem_page - copy one page from "oldmem" |
15 | * @pfn: page frame number to be copied | 18 | * @pfn: page frame number to be copied |
diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig index 97671dac12a6..e594559c8dba 100644 --- a/arch/sparc/Kconfig +++ b/arch/sparc/Kconfig | |||
@@ -37,6 +37,8 @@ config HZ | |||
37 | 37 | ||
38 | source "init/Kconfig" | 38 | source "init/Kconfig" |
39 | 39 | ||
40 | source "kernel/Kconfig.freezer" | ||
41 | |||
40 | menu "General machine setup" | 42 | menu "General machine setup" |
41 | 43 | ||
42 | config SMP | 44 | config SMP |
diff --git a/arch/sparc/include/asm/thread_info_32.h b/arch/sparc/include/asm/thread_info_32.h index 29899fd5b1b2..80fe547c3f45 100644 --- a/arch/sparc/include/asm/thread_info_32.h +++ b/arch/sparc/include/asm/thread_info_32.h | |||
@@ -135,6 +135,7 @@ BTFIXUPDEF_CALL(void, free_thread_info, struct thread_info *) | |||
135 | #define TIF_POLLING_NRFLAG 9 /* true if poll_idle() is polling | 135 | #define TIF_POLLING_NRFLAG 9 /* true if poll_idle() is polling |
136 | * TIF_NEED_RESCHED */ | 136 | * TIF_NEED_RESCHED */ |
137 | #define TIF_MEMDIE 10 | 137 | #define TIF_MEMDIE 10 |
138 | #define TIF_FREEZE 11 /* is freezing for suspend */ | ||
138 | 139 | ||
139 | /* as above, but as bit values */ | 140 | /* as above, but as bit values */ |
140 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 141 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
@@ -148,6 +149,7 @@ BTFIXUPDEF_CALL(void, free_thread_info, struct thread_info *) | |||
148 | #define _TIF_DO_NOTIFY_RESUME_MASK (_TIF_NOTIFY_RESUME | \ | 149 | #define _TIF_DO_NOTIFY_RESUME_MASK (_TIF_NOTIFY_RESUME | \ |
149 | _TIF_SIGPENDING | \ | 150 | _TIF_SIGPENDING | \ |
150 | _TIF_RESTORE_SIGMASK) | 151 | _TIF_RESTORE_SIGMASK) |
152 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
151 | 153 | ||
152 | #endif /* __KERNEL__ */ | 154 | #endif /* __KERNEL__ */ |
153 | 155 | ||
diff --git a/arch/sparc/include/asm/thread_info_64.h b/arch/sparc/include/asm/thread_info_64.h index c0a737d7292c..639ac805448a 100644 --- a/arch/sparc/include/asm/thread_info_64.h +++ b/arch/sparc/include/asm/thread_info_64.h | |||
@@ -237,6 +237,7 @@ register struct thread_info *current_thread_info_reg asm("g6"); | |||
237 | #define TIF_ABI_PENDING 12 | 237 | #define TIF_ABI_PENDING 12 |
238 | #define TIF_MEMDIE 13 | 238 | #define TIF_MEMDIE 13 |
239 | #define TIF_POLLING_NRFLAG 14 | 239 | #define TIF_POLLING_NRFLAG 14 |
240 | #define TIF_FREEZE 15 /* is freezing for suspend */ | ||
240 | 241 | ||
241 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) | 242 | #define _TIF_SYSCALL_TRACE (1<<TIF_SYSCALL_TRACE) |
242 | #define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME) | 243 | #define _TIF_NOTIFY_RESUME (1<<TIF_NOTIFY_RESUME) |
@@ -249,6 +250,7 @@ register struct thread_info *current_thread_info_reg asm("g6"); | |||
249 | #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) | 250 | #define _TIF_SYSCALL_AUDIT (1<<TIF_SYSCALL_AUDIT) |
250 | #define _TIF_ABI_PENDING (1<<TIF_ABI_PENDING) | 251 | #define _TIF_ABI_PENDING (1<<TIF_ABI_PENDING) |
251 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) | 252 | #define _TIF_POLLING_NRFLAG (1<<TIF_POLLING_NRFLAG) |
253 | #define _TIF_FREEZE (1<<TIF_FREEZE) | ||
252 | 254 | ||
253 | #define _TIF_USER_WORK_MASK ((0xff << TI_FLAG_WSAVED_SHIFT) | \ | 255 | #define _TIF_USER_WORK_MASK ((0xff << TI_FLAG_WSAVED_SHIFT) | \ |
254 | _TIF_DO_NOTIFY_RESUME_MASK | \ | 256 | _TIF_DO_NOTIFY_RESUME_MASK | \ |
diff --git a/arch/sparc64/Kconfig b/arch/sparc64/Kconfig index 5446e2a499b1..035b15af90d8 100644 --- a/arch/sparc64/Kconfig +++ b/arch/sparc64/Kconfig | |||
@@ -96,6 +96,7 @@ config GENERIC_HARDIRQS_NO__DO_IRQ | |||
96 | def_bool y | 96 | def_bool y |
97 | 97 | ||
98 | source "init/Kconfig" | 98 | source "init/Kconfig" |
99 | source "kernel/Kconfig.freezer" | ||
99 | 100 | ||
100 | menu "Processor type and features" | 101 | menu "Processor type and features" |
101 | 102 | ||
diff --git a/arch/um/Kconfig b/arch/um/Kconfig index 6976812cfb18..393bccfe1785 100644 --- a/arch/um/Kconfig +++ b/arch/um/Kconfig | |||
@@ -229,6 +229,8 @@ endmenu | |||
229 | 229 | ||
230 | source "init/Kconfig" | 230 | source "init/Kconfig" |
231 | 231 | ||
232 | source "kernel/Kconfig.freezer" | ||
233 | |||
232 | source "drivers/block/Kconfig" | 234 | source "drivers/block/Kconfig" |
233 | 235 | ||
234 | source "arch/um/Kconfig.char" | 236 | source "arch/um/Kconfig.char" |
diff --git a/arch/um/sys-i386/signal.c b/arch/um/sys-i386/signal.c index fd0c25ad6af3..129647375a6c 100644 --- a/arch/um/sys-i386/signal.c +++ b/arch/um/sys-i386/signal.c | |||
@@ -179,7 +179,8 @@ static int copy_sc_from_user(struct pt_regs *regs, | |||
179 | if (have_fpx_regs) { | 179 | if (have_fpx_regs) { |
180 | struct user_fxsr_struct fpx; | 180 | struct user_fxsr_struct fpx; |
181 | 181 | ||
182 | err = copy_from_user(&fpx, &sc.fpstate->_fxsr_env[0], | 182 | err = copy_from_user(&fpx, |
183 | &((struct _fpstate __user *)sc.fpstate)->_fxsr_env[0], | ||
183 | sizeof(struct user_fxsr_struct)); | 184 | sizeof(struct user_fxsr_struct)); |
184 | if (err) | 185 | if (err) |
185 | return 1; | 186 | return 1; |
diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig index bd3c2c53873e..49349ba77d80 100644 --- a/arch/x86/Kconfig +++ b/arch/x86/Kconfig | |||
@@ -193,6 +193,7 @@ config X86_TRAMPOLINE | |||
193 | config KTIME_SCALAR | 193 | config KTIME_SCALAR |
194 | def_bool X86_32 | 194 | def_bool X86_32 |
195 | source "init/Kconfig" | 195 | source "init/Kconfig" |
196 | source "kernel/Kconfig.freezer" | ||
196 | 197 | ||
197 | menu "Processor type and features" | 198 | menu "Processor type and features" |
198 | 199 | ||
diff --git a/arch/x86/kernel/crash_dump_32.c b/arch/x86/kernel/crash_dump_32.c index 72d0c56c1b48..f7cdb3b457aa 100644 --- a/arch/x86/kernel/crash_dump_32.c +++ b/arch/x86/kernel/crash_dump_32.c | |||
@@ -13,6 +13,9 @@ | |||
13 | 13 | ||
14 | static void *kdump_buf_page; | 14 | static void *kdump_buf_page; |
15 | 15 | ||
16 | /* Stores the physical address of elf header of crash image. */ | ||
17 | unsigned long long elfcorehdr_addr = ELFCORE_ADDR_MAX; | ||
18 | |||
16 | /** | 19 | /** |
17 | * copy_oldmem_page - copy one page from "oldmem" | 20 | * copy_oldmem_page - copy one page from "oldmem" |
18 | * @pfn: page frame number to be copied | 21 | * @pfn: page frame number to be copied |
diff --git a/arch/x86/kernel/crash_dump_64.c b/arch/x86/kernel/crash_dump_64.c index e90a60ef10c2..045b36cada65 100644 --- a/arch/x86/kernel/crash_dump_64.c +++ b/arch/x86/kernel/crash_dump_64.c | |||
@@ -10,6 +10,9 @@ | |||
10 | #include <linux/uaccess.h> | 10 | #include <linux/uaccess.h> |
11 | #include <linux/io.h> | 11 | #include <linux/io.h> |
12 | 12 | ||
13 | /* Stores the physical address of elf header of crash image. */ | ||
14 | unsigned long long elfcorehdr_addr = ELFCORE_ADDR_MAX; | ||
15 | |||
13 | /** | 16 | /** |
14 | * copy_oldmem_page - copy one page from "oldmem" | 17 | * copy_oldmem_page - copy one page from "oldmem" |
15 | * @pfn: page frame number to be copied | 18 | * @pfn: page frame number to be copied |
diff --git a/arch/x86/kernel/rtc.c b/arch/x86/kernel/rtc.c index 0a23b5795b25..dd6f2b71561b 100644 --- a/arch/x86/kernel/rtc.c +++ b/arch/x86/kernel/rtc.c | |||
@@ -52,7 +52,7 @@ int mach_set_rtc_mmss(unsigned long nowtime) | |||
52 | 52 | ||
53 | cmos_minutes = CMOS_READ(RTC_MINUTES); | 53 | cmos_minutes = CMOS_READ(RTC_MINUTES); |
54 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) | 54 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) |
55 | BCD_TO_BIN(cmos_minutes); | 55 | cmos_minutes = bcd2bin(cmos_minutes); |
56 | 56 | ||
57 | /* | 57 | /* |
58 | * since we're only adjusting minutes and seconds, | 58 | * since we're only adjusting minutes and seconds, |
@@ -69,8 +69,8 @@ int mach_set_rtc_mmss(unsigned long nowtime) | |||
69 | 69 | ||
70 | if (abs(real_minutes - cmos_minutes) < 30) { | 70 | if (abs(real_minutes - cmos_minutes) < 30) { |
71 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { | 71 | if (!(save_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) { |
72 | BIN_TO_BCD(real_seconds); | 72 | real_seconds = bin2bcd(real_seconds); |
73 | BIN_TO_BCD(real_minutes); | 73 | real_minutes = bin2bcd(real_minutes); |
74 | } | 74 | } |
75 | CMOS_WRITE(real_seconds,RTC_SECONDS); | 75 | CMOS_WRITE(real_seconds,RTC_SECONDS); |
76 | CMOS_WRITE(real_minutes,RTC_MINUTES); | 76 | CMOS_WRITE(real_minutes,RTC_MINUTES); |
@@ -124,16 +124,16 @@ unsigned long mach_get_cmos_time(void) | |||
124 | WARN_ON_ONCE(RTC_ALWAYS_BCD && (status & RTC_DM_BINARY)); | 124 | WARN_ON_ONCE(RTC_ALWAYS_BCD && (status & RTC_DM_BINARY)); |
125 | 125 | ||
126 | if (RTC_ALWAYS_BCD || !(status & RTC_DM_BINARY)) { | 126 | if (RTC_ALWAYS_BCD || !(status & RTC_DM_BINARY)) { |
127 | BCD_TO_BIN(sec); | 127 | sec = bcd2bin(sec); |
128 | BCD_TO_BIN(min); | 128 | min = bcd2bin(min); |
129 | BCD_TO_BIN(hour); | 129 | hour = bcd2bin(hour); |
130 | BCD_TO_BIN(day); | 130 | day = bcd2bin(day); |
131 | BCD_TO_BIN(mon); | 131 | mon = bcd2bin(mon); |
132 | BCD_TO_BIN(year); | 132 | year = bcd2bin(year); |
133 | } | 133 | } |
134 | 134 | ||
135 | if (century) { | 135 | if (century) { |
136 | BCD_TO_BIN(century); | 136 | century = bcd2bin(century); |
137 | year += century * 100; | 137 | year += century * 100; |
138 | printk(KERN_INFO "Extended CMOS year: %d\n", century * 100); | 138 | printk(KERN_INFO "Extended CMOS year: %d\n", century * 100); |
139 | } else | 139 | } else |
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c index 2255782e8d4b..b2c97874ec0f 100644 --- a/arch/x86/kernel/setup.c +++ b/arch/x86/kernel/setup.c | |||
@@ -561,7 +561,13 @@ static void __init reserve_standard_io_resources(void) | |||
561 | 561 | ||
562 | } | 562 | } |
563 | 563 | ||
564 | #ifdef CONFIG_PROC_VMCORE | 564 | /* |
565 | * Note: elfcorehdr_addr is not just limited to vmcore. It is also used by | ||
566 | * is_kdump_kernel() to determine if we are booting after a panic. Hence | ||
567 | * ifdef it under CONFIG_CRASH_DUMP and not CONFIG_PROC_VMCORE. | ||
568 | */ | ||
569 | |||
570 | #ifdef CONFIG_CRASH_DUMP | ||
565 | /* elfcorehdr= specifies the location of elf core header | 571 | /* elfcorehdr= specifies the location of elf core header |
566 | * stored by the crashed kernel. This option will be passed | 572 | * stored by the crashed kernel. This option will be passed |
567 | * by kexec loader to the capture kernel. | 573 | * by kexec loader to the capture kernel. |
diff --git a/arch/x86/mm/pageattr.c b/arch/x86/mm/pageattr.c index a9ec89c3fbca..407d8784f669 100644 --- a/arch/x86/mm/pageattr.c +++ b/arch/x86/mm/pageattr.c | |||
@@ -792,6 +792,8 @@ static int change_page_attr_set_clr(unsigned long *addr, int numpages, | |||
792 | /* Must avoid aliasing mappings in the highmem code */ | 792 | /* Must avoid aliasing mappings in the highmem code */ |
793 | kmap_flush_unused(); | 793 | kmap_flush_unused(); |
794 | 794 | ||
795 | vm_unmap_aliases(); | ||
796 | |||
795 | cpa.vaddr = addr; | 797 | cpa.vaddr = addr; |
796 | cpa.numpages = numpages; | 798 | cpa.numpages = numpages; |
797 | cpa.mask_set = mask_set; | 799 | cpa.mask_set = mask_set; |
diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c index 0013a729b41d..b61534c7a4c4 100644 --- a/arch/x86/xen/enlighten.c +++ b/arch/x86/xen/enlighten.c | |||
@@ -871,6 +871,7 @@ static void xen_alloc_ptpage(struct mm_struct *mm, unsigned long pfn, unsigned l | |||
871 | /* make sure there are no stray mappings of | 871 | /* make sure there are no stray mappings of |
872 | this page */ | 872 | this page */ |
873 | kmap_flush_unused(); | 873 | kmap_flush_unused(); |
874 | vm_unmap_aliases(); | ||
874 | } | 875 | } |
875 | } | 876 | } |
876 | 877 | ||
diff --git a/arch/x86/xen/mmu.c b/arch/x86/xen/mmu.c index ae173f6edd8b..d4d52f5a1cf7 100644 --- a/arch/x86/xen/mmu.c +++ b/arch/x86/xen/mmu.c | |||
@@ -846,6 +846,7 @@ static void __xen_pgd_pin(struct mm_struct *mm, pgd_t *pgd) | |||
846 | /* re-enable interrupts for kmap_flush_unused */ | 846 | /* re-enable interrupts for kmap_flush_unused */ |
847 | xen_mc_issue(0); | 847 | xen_mc_issue(0); |
848 | kmap_flush_unused(); | 848 | kmap_flush_unused(); |
849 | vm_unmap_aliases(); | ||
849 | xen_mc_batch(); | 850 | xen_mc_batch(); |
850 | } | 851 | } |
851 | 852 | ||
diff --git a/arch/xtensa/Kconfig b/arch/xtensa/Kconfig index 02e417d3d8e9..a213260b51e5 100644 --- a/arch/xtensa/Kconfig +++ b/arch/xtensa/Kconfig | |||
@@ -55,6 +55,7 @@ config HZ | |||
55 | default 100 | 55 | default 100 |
56 | 56 | ||
57 | source "init/Kconfig" | 57 | source "init/Kconfig" |
58 | source "kernel/Kconfig.freezer" | ||
58 | 59 | ||
59 | menu "Processor type and features" | 60 | menu "Processor type and features" |
60 | 61 | ||