summaryrefslogtreecommitdiff
path: root/arch
diff options
context:
space:
mode:
authorTony Luck <tony.luck@intel.com>2005-07-27 17:36:54 (GMT)
committerTony Luck <tony.luck@intel.com>2005-07-27 17:36:54 (GMT)
commitc2834cf4746cf13501efc3489b1895bce58a4ccb (patch)
tree13614c2ed7ec156d8518fd5bff4e1c252fb05792 /arch
parent05cb784c81a0fd1f97732156ea464bd392ce875a (diff)
parent9e566d8bd61f939b7f5d7d969f5b178571471cf9 (diff)
downloadlinux-c2834cf4746cf13501efc3489b1895bce58a4ccb.tar.xz
Auto merge with /home/aegl/GIT/linus
Diffstat (limited to 'arch')
-rw-r--r--arch/alpha/kernel/process.c3
-rw-r--r--arch/arm/kernel/process.c4
-rw-r--r--arch/arm/mach-s3c2410/Makefile2
-rw-r--r--arch/arm/mach-s3c2410/clock.c57
-rw-r--r--arch/arm/mach-s3c2410/irq.c260
-rw-r--r--arch/arm/mach-s3c2410/irq.h99
-rw-r--r--arch/arm/mach-s3c2410/mach-bast.c13
-rw-r--r--arch/arm/mach-s3c2410/s3c2440-clock.c116
-rw-r--r--arch/arm/mach-s3c2410/s3c2440-irq.c207
-rw-r--r--arch/arm/mm/mm-armv.c3
-rw-r--r--arch/arm26/kernel/process.c5
-rw-r--r--arch/cris/kernel/process.c9
-rw-r--r--arch/h8300/kernel/process.c6
-rw-r--r--arch/i386/kernel/apm.c7
-rw-r--r--arch/i386/kernel/reboot.c19
-rw-r--r--arch/i386/mach-visws/reboot.c5
-rw-r--r--arch/i386/mach-voyager/voyager_basic.c5
-rw-r--r--arch/ia64/kernel/process.c5
-rw-r--r--arch/ia64/sn/kernel/xpc_main.c2
-rw-r--r--arch/m32r/kernel/process.c6
-rw-r--r--arch/m68k/kernel/process.c6
-rw-r--r--arch/m68knommu/kernel/process.c6
-rw-r--r--arch/mips/kernel/reset.c5
-rw-r--r--arch/parisc/kernel/process.c6
-rw-r--r--arch/ppc/kernel/setup.c6
-rw-r--r--arch/ppc64/kernel/setup.c3
-rw-r--r--arch/s390/kernel/setup.c6
-rw-r--r--arch/sh/kernel/process.c6
-rw-r--r--arch/sparc/kernel/process.c6
-rw-r--r--arch/sparc64/kernel/power.c2
-rw-r--r--arch/sparc64/kernel/process.c4
-rw-r--r--arch/um/kernel/reboot.c6
-rw-r--r--arch/v850/kernel/anna.c6
-rw-r--r--arch/v850/kernel/as85ep1.c6
-rw-r--r--arch/v850/kernel/fpga85e2c.c6
-rw-r--r--arch/v850/kernel/rte_cb.c6
-rw-r--r--arch/v850/kernel/sim.c6
-rw-r--r--arch/v850/kernel/sim85e2.c5
-rw-r--r--arch/x86_64/ia32/ia32entry.S8
-rw-r--r--arch/x86_64/ia32/sys_ia32.c5
-rw-r--r--arch/x86_64/kernel/reboot.c31
41 files changed, 471 insertions, 503 deletions
diff --git a/arch/alpha/kernel/process.c b/arch/alpha/kernel/process.c
index 4933f3c..fa98dae 100644
--- a/arch/alpha/kernel/process.c
+++ b/arch/alpha/kernel/process.c
@@ -165,7 +165,6 @@ machine_restart(char *restart_cmd)
common_shutdown(LINUX_REBOOT_CMD_RESTART, restart_cmd);
}
-EXPORT_SYMBOL(machine_restart);
void
machine_halt(void)
@@ -173,7 +172,6 @@ machine_halt(void)
common_shutdown(LINUX_REBOOT_CMD_HALT, NULL);
}
-EXPORT_SYMBOL(machine_halt);
void
machine_power_off(void)
@@ -181,7 +179,6 @@ machine_power_off(void)
common_shutdown(LINUX_REBOOT_CMD_POWER_OFF, NULL);
}
-EXPORT_SYMBOL(machine_power_off);
/* Used by sysrq-p, among others. I don't believe r9-r15 are ever
saved in the context it's used. */
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c
index bbea636..409db6d 100644
--- a/arch/arm/kernel/process.c
+++ b/arch/arm/kernel/process.c
@@ -131,7 +131,6 @@ void machine_halt(void)
{
}
-EXPORT_SYMBOL(machine_halt);
void machine_power_off(void)
{
@@ -139,7 +138,6 @@ void machine_power_off(void)
pm_power_off();
}
-EXPORT_SYMBOL(machine_power_off);
void machine_restart(char * __unused)
{
@@ -169,8 +167,6 @@ void machine_restart(char * __unused)
while (1);
}
-EXPORT_SYMBOL(machine_restart);
-
void __show_regs(struct pt_regs *regs)
{
unsigned long flags = condition_codes(regs);
diff --git a/arch/arm/mach-s3c2410/Makefile b/arch/arm/mach-s3c2410/Makefile
index f99b689..55ed7c7 100644
--- a/arch/arm/mach-s3c2410/Makefile
+++ b/arch/arm/mach-s3c2410/Makefile
@@ -23,6 +23,8 @@ obj-$(CONFIG_PM_SIMTEC) += pm-simtec.o
# S3C2440 support
obj-$(CONFIG_CPU_S3C2440) += s3c2440.o s3c2440-dsc.o
+obj-$(CONFIG_CPU_S3C2440) += s3c2440-irq.o
+obj-$(CONFIG_CPU_S3C2440) += s3c2440-clock.o
# machine specific support
diff --git a/arch/arm/mach-s3c2410/clock.c b/arch/arm/mach-s3c2410/clock.c
index 8d986b8..9a66050 100644
--- a/arch/arm/mach-s3c2410/clock.c
+++ b/arch/arm/mach-s3c2410/clock.c
@@ -448,60 +448,3 @@ int __init s3c24xx_setup_clocks(unsigned long xtal,
return 0;
}
-
-/* S3C2440 extended clock support */
-
-#ifdef CONFIG_CPU_S3C2440
-
-static struct clk s3c2440_clk_upll = {
- .name = "upll",
- .id = -1,
-};
-
-static struct clk s3c2440_clk_cam = {
- .name = "camif",
- .parent = &clk_h,
- .id = -1,
- .enable = s3c24xx_clkcon_enable,
- .ctrlbit = S3C2440_CLKCON_CAMERA,
-};
-
-static struct clk s3c2440_clk_ac97 = {
- .name = "ac97",
- .parent = &clk_p,
- .id = -1,
- .enable = s3c24xx_clkcon_enable,
- .ctrlbit = S3C2440_CLKCON_CAMERA,
-};
-
-static int s3c2440_clk_add(struct sys_device *sysdev)
-{
- unsigned long upllcon = __raw_readl(S3C2410_UPLLCON);
-
- s3c2440_clk_upll.rate = s3c2410_get_pll(upllcon, clk_xtal.rate);
-
- printk("S3C2440: Clock Support, UPLL %ld.%03ld MHz\n",
- print_mhz(s3c2440_clk_upll.rate));
-
- s3c24xx_register_clock(&s3c2440_clk_ac97);
- s3c24xx_register_clock(&s3c2440_clk_cam);
- s3c24xx_register_clock(&s3c2440_clk_upll);
-
- clk_disable(&s3c2440_clk_ac97);
- clk_disable(&s3c2440_clk_cam);
-
- return 0;
-}
-
-static struct sysdev_driver s3c2440_clk_driver = {
- .add = s3c2440_clk_add,
-};
-
-static int s3c24xx_clk_driver(void)
-{
- return sysdev_driver_register(&s3c2440_sysclass, &s3c2440_clk_driver);
-}
-
-arch_initcall(s3c24xx_clk_driver);
-
-#endif /* CONFIG_CPU_S3C2440 */
diff --git a/arch/arm/mach-s3c2410/irq.c b/arch/arm/mach-s3c2410/irq.c
index cf9f46d..973a5fe 100644
--- a/arch/arm/mach-s3c2410/irq.c
+++ b/arch/arm/mach-s3c2410/irq.c
@@ -45,6 +45,9 @@
*
* 28-Jun-2005 Ben Dooks
* Mark IRQ_LCD valid
+ *
+ * 25-Jul-2005 Ben Dooks
+ * Split the S3C2440 IRQ code to seperate file
*/
#include <linux/init.h>
@@ -65,11 +68,7 @@
#include "cpu.h"
#include "pm.h"
-
-#define irqdbf(x...)
-#define irqdbf2(x...)
-
-#define EXTINT_OFF (IRQ_EINT4 - 4)
+#include "irq.h"
/* wakeup irq control */
@@ -181,7 +180,7 @@ s3c_irq_unmask(unsigned int irqno)
__raw_writel(mask, S3C2410_INTMSK);
}
-static struct irqchip s3c_irq_level_chip = {
+struct irqchip s3c_irq_level_chip = {
.ack = s3c_irq_maskack,
.mask = s3c_irq_mask,
.unmask = s3c_irq_unmask,
@@ -370,84 +369,6 @@ static struct irqchip s3c_irq_eint0t4 = {
#define INTMSK_UART2 (1UL << (IRQ_UART2 - IRQ_EINT0))
#define INTMSK_ADCPARENT (1UL << (IRQ_ADCPARENT - IRQ_EINT0))
-static inline void
-s3c_irqsub_mask(unsigned int irqno, unsigned int parentbit,
- int subcheck)
-{
- unsigned long mask;
- unsigned long submask;
-
- submask = __raw_readl(S3C2410_INTSUBMSK);
- mask = __raw_readl(S3C2410_INTMSK);
-
- submask |= (1UL << (irqno - IRQ_S3CUART_RX0));
-
- /* check to see if we need to mask the parent IRQ */
-
- if ((submask & subcheck) == subcheck) {
- __raw_writel(mask | parentbit, S3C2410_INTMSK);
- }
-
- /* write back masks */
- __raw_writel(submask, S3C2410_INTSUBMSK);
-
-}
-
-static inline void
-s3c_irqsub_unmask(unsigned int irqno, unsigned int parentbit)
-{
- unsigned long mask;
- unsigned long submask;
-
- submask = __raw_readl(S3C2410_INTSUBMSK);
- mask = __raw_readl(S3C2410_INTMSK);
-
- submask &= ~(1UL << (irqno - IRQ_S3CUART_RX0));
- mask &= ~parentbit;
-
- /* write back masks */
- __raw_writel(submask, S3C2410_INTSUBMSK);
- __raw_writel(mask, S3C2410_INTMSK);
-}
-
-
-static inline void
-s3c_irqsub_maskack(unsigned int irqno, unsigned int parentmask, unsigned int group)
-{
- unsigned int bit = 1UL << (irqno - IRQ_S3CUART_RX0);
-
- s3c_irqsub_mask(irqno, parentmask, group);
-
- __raw_writel(bit, S3C2410_SUBSRCPND);
-
- /* only ack parent if we've got all the irqs (seems we must
- * ack, all and hope that the irq system retriggers ok when
- * the interrupt goes off again)
- */
-
- if (1) {
- __raw_writel(parentmask, S3C2410_SRCPND);
- __raw_writel(parentmask, S3C2410_INTPND);
- }
-}
-
-static inline void
-s3c_irqsub_ack(unsigned int irqno, unsigned int parentmask, unsigned int group)
-{
- unsigned int bit = 1UL << (irqno - IRQ_S3CUART_RX0);
-
- __raw_writel(bit, S3C2410_SUBSRCPND);
-
- /* only ack parent if we've got all the irqs (seems we must
- * ack, all and hope that the irq system retriggers ok when
- * the interrupt goes off again)
- */
-
- if (1) {
- __raw_writel(parentmask, S3C2410_SRCPND);
- __raw_writel(parentmask, S3C2410_INTPND);
- }
-}
/* UART0 */
@@ -794,174 +715,3 @@ void __init s3c24xx_init_irq(void)
irqdbf("s3c2410: registered interrupt handlers\n");
}
-
-/* s3c2440 irq code
-*/
-
-#ifdef CONFIG_CPU_S3C2440
-
-/* WDT/AC97 */
-
-static void s3c_irq_demux_wdtac97(unsigned int irq,
- struct irqdesc *desc,
- struct pt_regs *regs)
-{
- unsigned int subsrc, submsk;
- struct irqdesc *mydesc;
-
- /* read the current pending interrupts, and the mask
- * for what it is available */
-
- subsrc = __raw_readl(S3C2410_SUBSRCPND);
- submsk = __raw_readl(S3C2410_INTSUBMSK);
-
- subsrc &= ~submsk;
- subsrc >>= 13;
- subsrc &= 3;
-
- if (subsrc != 0) {
- if (subsrc & 1) {
- mydesc = irq_desc + IRQ_S3C2440_WDT;
- mydesc->handle( IRQ_S3C2440_WDT, mydesc, regs);
- }
- if (subsrc & 2) {
- mydesc = irq_desc + IRQ_S3C2440_AC97;
- mydesc->handle(IRQ_S3C2440_AC97, mydesc, regs);
- }
- }
-}
-
-
-#define INTMSK_WDT (1UL << (IRQ_WDT - IRQ_EINT0))
-
-static void
-s3c_irq_wdtac97_mask(unsigned int irqno)
-{
- s3c_irqsub_mask(irqno, INTMSK_WDT, 3<<13);
-}
-
-static void
-s3c_irq_wdtac97_unmask(unsigned int irqno)
-{
- s3c_irqsub_unmask(irqno, INTMSK_WDT);
-}
-
-static void
-s3c_irq_wdtac97_ack(unsigned int irqno)
-{
- s3c_irqsub_maskack(irqno, INTMSK_WDT, 3<<13);
-}
-
-static struct irqchip s3c_irq_wdtac97 = {
- .mask = s3c_irq_wdtac97_mask,
- .unmask = s3c_irq_wdtac97_unmask,
- .ack = s3c_irq_wdtac97_ack,
-};
-
-/* camera irq */
-
-static void s3c_irq_demux_cam(unsigned int irq,
- struct irqdesc *desc,
- struct pt_regs *regs)
-{
- unsigned int subsrc, submsk;
- struct irqdesc *mydesc;
-
- /* read the current pending interrupts, and the mask
- * for what it is available */
-
- subsrc = __raw_readl(S3C2410_SUBSRCPND);
- submsk = __raw_readl(S3C2410_INTSUBMSK);
-
- subsrc &= ~submsk;
- subsrc >>= 11;
- subsrc &= 3;
-
- if (subsrc != 0) {
- if (subsrc & 1) {
- mydesc = irq_desc + IRQ_S3C2440_CAM_C;
- mydesc->handle( IRQ_S3C2440_WDT, mydesc, regs);
- }
- if (subsrc & 2) {
- mydesc = irq_desc + IRQ_S3C2440_CAM_P;
- mydesc->handle(IRQ_S3C2440_AC97, mydesc, regs);
- }
- }
-}
-
-#define INTMSK_CAM (1UL << (IRQ_CAM - IRQ_EINT0))
-
-static void
-s3c_irq_cam_mask(unsigned int irqno)
-{
- s3c_irqsub_mask(irqno, INTMSK_CAM, 3<<11);
-}
-
-static void
-s3c_irq_cam_unmask(unsigned int irqno)
-{
- s3c_irqsub_unmask(irqno, INTMSK_CAM);
-}
-
-static void
-s3c_irq_cam_ack(unsigned int irqno)
-{
- s3c_irqsub_maskack(irqno, INTMSK_CAM, 3<<11);
-}
-
-static struct irqchip s3c_irq_cam = {
- .mask = s3c_irq_cam_mask,
- .unmask = s3c_irq_cam_unmask,
- .ack = s3c_irq_cam_ack,
-};
-
-static int s3c2440_irq_add(struct sys_device *sysdev)
-{
- unsigned int irqno;
-
- printk("S3C2440: IRQ Support\n");
-
- set_irq_chip(IRQ_NFCON, &s3c_irq_level_chip);
- set_irq_handler(IRQ_NFCON, do_level_IRQ);
- set_irq_flags(IRQ_NFCON, IRQF_VALID);
-
- /* add new chained handler for wdt, ac7 */
-
- set_irq_chip(IRQ_WDT, &s3c_irq_level_chip);
- set_irq_handler(IRQ_WDT, do_level_IRQ);
- set_irq_chained_handler(IRQ_WDT, s3c_irq_demux_wdtac97);
-
- for (irqno = IRQ_S3C2440_WDT; irqno <= IRQ_S3C2440_AC97; irqno++) {
- set_irq_chip(irqno, &s3c_irq_wdtac97);
- set_irq_handler(irqno, do_level_IRQ);
- set_irq_flags(irqno, IRQF_VALID);
- }
-
- /* add chained handler for camera */
-
- set_irq_chip(IRQ_CAM, &s3c_irq_level_chip);
- set_irq_handler(IRQ_CAM, do_level_IRQ);
- set_irq_chained_handler(IRQ_CAM, s3c_irq_demux_cam);
-
- for (irqno = IRQ_S3C2440_CAM_C; irqno <= IRQ_S3C2440_CAM_P; irqno++) {
- set_irq_chip(irqno, &s3c_irq_cam);
- set_irq_handler(irqno, do_level_IRQ);
- set_irq_flags(irqno, IRQF_VALID);
- }
-
- return 0;
-}
-
-static struct sysdev_driver s3c2440_irq_driver = {
- .add = s3c2440_irq_add,
-};
-
-static int s3c24xx_irq_driver(void)
-{
- return sysdev_driver_register(&s3c2440_sysclass, &s3c2440_irq_driver);
-}
-
-arch_initcall(s3c24xx_irq_driver);
-
-#endif /* CONFIG_CPU_S3C2440 */
-
diff --git a/arch/arm/mach-s3c2410/irq.h b/arch/arm/mach-s3c2410/irq.h
new file mode 100644
index 0000000..4abf0ca
--- /dev/null
+++ b/arch/arm/mach-s3c2410/irq.h
@@ -0,0 +1,99 @@
+/* arch/arm/mach-s3c2410/irq.h
+ *
+ * Copyright (c) 2004-2005 Simtec Electronics
+ * Ben Dooks <ben@simtec.co.uk>
+ *
+ * Header file for S3C24XX CPU IRQ support
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ * Modifications:
+*/
+
+#define irqdbf(x...)
+#define irqdbf2(x...)
+
+#define EXTINT_OFF (IRQ_EINT4 - 4)
+
+extern struct irqchip s3c_irq_level_chip;
+
+static inline void
+s3c_irqsub_mask(unsigned int irqno, unsigned int parentbit,
+ int subcheck)
+{
+ unsigned long mask;
+ unsigned long submask;
+
+ submask = __raw_readl(S3C2410_INTSUBMSK);
+ mask = __raw_readl(S3C2410_INTMSK);
+
+ submask |= (1UL << (irqno - IRQ_S3CUART_RX0));
+
+ /* check to see if we need to mask the parent IRQ */
+
+ if ((submask & subcheck) == subcheck) {
+ __raw_writel(mask | parentbit, S3C2410_INTMSK);
+ }
+
+ /* write back masks */
+ __raw_writel(submask, S3C2410_INTSUBMSK);
+
+}
+
+static inline void
+s3c_irqsub_unmask(unsigned int irqno, unsigned int parentbit)
+{
+ unsigned long mask;
+ unsigned long submask;
+
+ submask = __raw_readl(S3C2410_INTSUBMSK);
+ mask = __raw_readl(S3C2410_INTMSK);
+
+ submask &= ~(1UL << (irqno - IRQ_S3CUART_RX0));
+ mask &= ~parentbit;
+
+ /* write back masks */
+ __raw_writel(submask, S3C2410_INTSUBMSK);
+ __raw_writel(mask, S3C2410_INTMSK);
+}
+
+
+static inline void
+s3c_irqsub_maskack(unsigned int irqno, unsigned int parentmask, unsigned int group)
+{
+ unsigned int bit = 1UL << (irqno - IRQ_S3CUART_RX0);
+
+ s3c_irqsub_mask(irqno, parentmask, group);
+
+ __raw_writel(bit, S3C2410_SUBSRCPND);
+
+ /* only ack parent if we've got all the irqs (seems we must
+ * ack, all and hope that the irq system retriggers ok when
+ * the interrupt goes off again)
+ */
+
+ if (1) {
+ __raw_writel(parentmask, S3C2410_SRCPND);
+ __raw_writel(parentmask, S3C2410_INTPND);
+ }
+}
+
+static inline void
+s3c_irqsub_ack(unsigned int irqno, unsigned int parentmask, unsigned int group)
+{
+ unsigned int bit = 1UL << (irqno - IRQ_S3CUART_RX0);
+
+ __raw_writel(bit, S3C2410_SUBSRCPND);
+
+ /* only ack parent if we've got all the irqs (seems we must
+ * ack, all and hope that the irq system retriggers ok when
+ * the interrupt goes off again)
+ */
+
+ if (1) {
+ __raw_writel(parentmask, S3C2410_SRCPND);
+ __raw_writel(parentmask, S3C2410_INTPND);
+ }
+}
diff --git a/arch/arm/mach-s3c2410/mach-bast.c b/arch/arm/mach-s3c2410/mach-bast.c
index 206778e..1e7f343 100644
--- a/arch/arm/mach-s3c2410/mach-bast.c
+++ b/arch/arm/mach-s3c2410/mach-bast.c
@@ -25,10 +25,11 @@
* 14-Jan-2005 BJD Add support for muitlple NAND devices
* 03-Mar-2005 BJD Ensured that bast-cpld.h is included
* 10-Mar-2005 LCVR Changed S3C2410_VA to S3C24XX_VA
- * 14-Mar-2006 BJD Updated for __iomem changes
- * 22-Jun-2006 BJD Added DM9000 platform information
- * 28-Jun-2006 BJD Moved pm functionality out to common code
- * 17-Jul-2006 BJD Changed to platform device for SuperIO 16550s
+ * 14-Mar-2005 BJD Updated for __iomem changes
+ * 22-Jun-2005 BJD Added DM9000 platform information
+ * 28-Jun-2005 BJD Moved pm functionality out to common code
+ * 17-Jul-2005 BJD Changed to platform device for SuperIO 16550s
+ * 25-Jul-2005 BJD Removed ASIX static mappings
*/
#include <linux/kernel.h>
@@ -116,7 +117,6 @@ static struct map_desc bast_iodesc[] __initdata = {
/* slow, byte */
{ VA_C2(BAST_VA_ISAIO), PA_CS2(BAST_PA_ISAIO), SZ_16M, MT_DEVICE },
{ VA_C2(BAST_VA_ISAMEM), PA_CS2(BAST_PA_ISAMEM), SZ_16M, MT_DEVICE },
- { VA_C2(BAST_VA_ASIXNET), PA_CS3(BAST_PA_ASIXNET), SZ_1M, MT_DEVICE },
{ VA_C2(BAST_VA_SUPERIO), PA_CS2(BAST_PA_SUPERIO), SZ_1M, MT_DEVICE },
{ VA_C2(BAST_VA_IDEPRI), PA_CS3(BAST_PA_IDEPRI), SZ_1M, MT_DEVICE },
{ VA_C2(BAST_VA_IDESEC), PA_CS3(BAST_PA_IDESEC), SZ_1M, MT_DEVICE },
@@ -126,7 +126,6 @@ static struct map_desc bast_iodesc[] __initdata = {
/* slow, word */
{ VA_C3(BAST_VA_ISAIO), PA_CS3(BAST_PA_ISAIO), SZ_16M, MT_DEVICE },
{ VA_C3(BAST_VA_ISAMEM), PA_CS3(BAST_PA_ISAMEM), SZ_16M, MT_DEVICE },
- { VA_C3(BAST_VA_ASIXNET), PA_CS3(BAST_PA_ASIXNET), SZ_1M, MT_DEVICE },
{ VA_C3(BAST_VA_SUPERIO), PA_CS3(BAST_PA_SUPERIO), SZ_1M, MT_DEVICE },
{ VA_C3(BAST_VA_IDEPRI), PA_CS3(BAST_PA_IDEPRI), SZ_1M, MT_DEVICE },
{ VA_C3(BAST_VA_IDESEC), PA_CS3(BAST_PA_IDESEC), SZ_1M, MT_DEVICE },
@@ -136,7 +135,6 @@ static struct map_desc bast_iodesc[] __initdata = {
/* fast, byte */
{ VA_C4(BAST_VA_ISAIO), PA_CS4(BAST_PA_ISAIO), SZ_16M, MT_DEVICE },
{ VA_C4(BAST_VA_ISAMEM), PA_CS4(BAST_PA_ISAMEM), SZ_16M, MT_DEVICE },
- { VA_C4(BAST_VA_ASIXNET), PA_CS5(BAST_PA_ASIXNET), SZ_1M, MT_DEVICE },
{ VA_C4(BAST_VA_SUPERIO), PA_CS4(BAST_PA_SUPERIO), SZ_1M, MT_DEVICE },
{ VA_C4(BAST_VA_IDEPRI), PA_CS5(BAST_PA_IDEPRI), SZ_1M, MT_DEVICE },
{ VA_C4(BAST_VA_IDESEC), PA_CS5(BAST_PA_IDESEC), SZ_1M, MT_DEVICE },
@@ -146,7 +144,6 @@ static struct map_desc bast_iodesc[] __initdata = {
/* fast, word */
{ VA_C5(BAST_VA_ISAIO), PA_CS5(BAST_PA_ISAIO), SZ_16M, MT_DEVICE },
{ VA_C5(BAST_VA_ISAMEM), PA_CS5(BAST_PA_ISAMEM), SZ_16M, MT_DEVICE },
- { VA_C5(BAST_VA_ASIXNET), PA_CS5(BAST_PA_ASIXNET), SZ_1M, MT_DEVICE },
{ VA_C5(BAST_VA_SUPERIO), PA_CS5(BAST_PA_SUPERIO), SZ_1M, MT_DEVICE },
{ VA_C5(BAST_VA_IDEPRI), PA_CS5(BAST_PA_IDEPRI), SZ_1M, MT_DEVICE },
{ VA_C5(BAST_VA_IDESEC), PA_CS5(BAST_PA_IDESEC), SZ_1M, MT_DEVICE },
diff --git a/arch/arm/mach-s3c2410/s3c2440-clock.c b/arch/arm/mach-s3c2410/s3c2440-clock.c
new file mode 100644
index 0000000..b018a1f
--- /dev/null
+++ b/arch/arm/mach-s3c2410/s3c2440-clock.c
@@ -0,0 +1,116 @@
+/* linux/arch/arm/mach-s3c2410/s3c2440-clock.c
+ *
+ * Copyright (c) 2004-2005 Simtec Electronics
+ * http://armlinux.simtec.co.uk/
+ * Ben Dooks <ben@simtec.co.uk>
+ *
+ * S3C2440 Clock support
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+*/
+
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/kernel.h>
+#include <linux/list.h>
+#include <linux/errno.h>
+#include <linux/err.h>
+#include <linux/device.h>
+#include <linux/sysdev.h>
+
+#include <linux/interrupt.h>
+#include <linux/ioport.h>
+
+#include <asm/hardware.h>
+#include <asm/atomic.h>
+#include <asm/irq.h>
+#include <asm/io.h>
+
+#include <asm/hardware/clock.h>
+#include <asm/arch/regs-clock.h>
+
+#include "clock.h"
+#include "cpu.h"
+
+/* S3C2440 extended clock support */
+
+static struct clk s3c2440_clk_upll = {
+ .name = "upll",
+ .id = -1,
+};
+
+static struct clk s3c2440_clk_cam = {
+ .name = "camif",
+ .id = -1,
+ .enable = s3c24xx_clkcon_enable,
+ .ctrlbit = S3C2440_CLKCON_CAMERA,
+};
+
+static struct clk s3c2440_clk_ac97 = {
+ .name = "ac97",
+ .id = -1,
+ .enable = s3c24xx_clkcon_enable,
+ .ctrlbit = S3C2440_CLKCON_CAMERA,
+};
+
+static int s3c2440_clk_add(struct sys_device *sysdev)
+{
+ unsigned long upllcon = __raw_readl(S3C2410_UPLLCON);
+ struct clk *clk_h;
+ struct clk *clk_p;
+ struct clk *clk_xtal;
+
+ clk_xtal = clk_get(NULL, "xtal");
+ if (IS_ERR(clk_xtal)) {
+ printk(KERN_ERR "S3C2440: Failed to get clk_xtal\n");
+ return -EINVAL;
+ }
+
+ s3c2440_clk_upll.rate = s3c2410_get_pll(upllcon, clk_xtal->rate);
+
+ printk("S3C2440: Clock Support, UPLL %ld.%03ld MHz\n",
+ print_mhz(s3c2440_clk_upll.rate));
+
+ clk_p = clk_get(NULL, "pclk");
+ clk_h = clk_get(NULL, "hclk");
+
+ if (IS_ERR(clk_p) || IS_ERR(clk_h)) {
+ printk(KERN_ERR "S3C2440: Failed to get parent clocks\n");
+ return -EINVAL;
+ }
+
+ s3c2440_clk_cam.parent = clk_h;
+ s3c2440_clk_ac97.parent = clk_p;
+
+ s3c24xx_register_clock(&s3c2440_clk_ac97);
+ s3c24xx_register_clock(&s3c2440_clk_cam);
+ s3c24xx_register_clock(&s3c2440_clk_upll);
+
+ clk_disable(&s3c2440_clk_ac97);
+ clk_disable(&s3c2440_clk_cam);
+
+ return 0;
+}
+
+static struct sysdev_driver s3c2440_clk_driver = {
+ .add = s3c2440_clk_add,
+};
+
+static __init int s3c24xx_clk_driver(void)
+{
+ return sysdev_driver_register(&s3c2440_sysclass, &s3c2440_clk_driver);
+}
+
+arch_initcall(s3c24xx_clk_driver);
diff --git a/arch/arm/mach-s3c2410/s3c2440-irq.c b/arch/arm/mach-s3c2410/s3c2440-irq.c
new file mode 100644
index 0000000..7cb9912
--- /dev/null
+++ b/arch/arm/mach-s3c2410/s3c2440-irq.c
@@ -0,0 +1,207 @@
+/* linux/arch/arm/mach-s3c2410/s3c2440-irq.c
+ *
+ * Copyright (c) 2003,2004 Simtec Electronics
+ * Ben Dooks <ben@simtec.co.uk>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ * Changelog:
+ * 25-Jul-2005 BJD Split from irq.c
+ *
+*/
+
+#include <linux/init.h>
+#include <linux/module.h>
+#include <linux/interrupt.h>
+#include <linux/ioport.h>
+#include <linux/ptrace.h>
+#include <linux/sysdev.h>
+
+#include <asm/hardware.h>
+#include <asm/irq.h>
+#include <asm/io.h>
+
+#include <asm/mach/irq.h>
+
+#include <asm/arch/regs-irq.h>
+#include <asm/arch/regs-gpio.h>
+
+#include "cpu.h"
+#include "pm.h"
+#include "irq.h"
+
+/* WDT/AC97 */
+
+static void s3c_irq_demux_wdtac97(unsigned int irq,
+ struct irqdesc *desc,
+ struct pt_regs *regs)
+{
+ unsigned int subsrc, submsk;
+ struct irqdesc *mydesc;
+
+ /* read the current pending interrupts, and the mask
+ * for what it is available */
+
+ subsrc = __raw_readl(S3C2410_SUBSRCPND);
+ submsk = __raw_readl(S3C2410_INTSUBMSK);
+
+ subsrc &= ~submsk;
+ subsrc >>= 13;
+ subsrc &= 3;
+
+ if (subsrc != 0) {
+ if (subsrc & 1) {
+ mydesc = irq_desc + IRQ_S3C2440_WDT;
+ mydesc->handle( IRQ_S3C2440_WDT, mydesc, regs);
+ }
+ if (subsrc & 2) {
+ mydesc = irq_desc + IRQ_S3C2440_AC97;
+ mydesc->handle(IRQ_S3C2440_AC97, mydesc, regs);
+ }
+ }
+}
+
+
+#define INTMSK_WDT (1UL << (IRQ_WDT - IRQ_EINT0))
+
+static void
+s3c_irq_wdtac97_mask(unsigned int irqno)
+{
+ s3c_irqsub_mask(irqno, INTMSK_WDT, 3<<13);
+}
+
+static void
+s3c_irq_wdtac97_unmask(unsigned int irqno)
+{
+ s3c_irqsub_unmask(irqno, INTMSK_WDT);
+}
+
+static void
+s3c_irq_wdtac97_ack(unsigned int irqno)
+{
+ s3c_irqsub_maskack(irqno, INTMSK_WDT, 3<<13);
+}
+
+static struct irqchip s3c_irq_wdtac97 = {
+ .mask = s3c_irq_wdtac97_mask,
+ .unmask = s3c_irq_wdtac97_unmask,
+ .ack = s3c_irq_wdtac97_ack,
+};
+
+/* camera irq */
+
+static void s3c_irq_demux_cam(unsigned int irq,
+ struct irqdesc *desc,
+ struct pt_regs *regs)
+{
+ unsigned int subsrc, submsk;
+ struct irqdesc *mydesc;
+
+ /* read the current pending interrupts, and the mask
+ * for what it is available */
+
+ subsrc = __raw_readl(S3C2410_SUBSRCPND);
+ submsk = __raw_readl(S3C2410_INTSUBMSK);
+
+ subsrc &= ~submsk;
+ subsrc >>= 11;
+ subsrc &= 3;
+
+ if (subsrc != 0) {
+ if (subsrc & 1) {
+ mydesc = irq_desc + IRQ_S3C2440_CAM_C;
+ mydesc->handle( IRQ_S3C2440_WDT, mydesc, regs);
+ }
+ if (subsrc & 2) {
+ mydesc = irq_desc + IRQ_S3C2440_CAM_P;
+ mydesc->handle(IRQ_S3C2440_AC97, mydesc, regs);
+ }
+ }
+}
+
+#define INTMSK_CAM (1UL << (IRQ_CAM - IRQ_EINT0))
+
+static void
+s3c_irq_cam_mask(unsigned int irqno)
+{
+ s3c_irqsub_mask(irqno, INTMSK_CAM, 3<<11);
+}
+
+static void
+s3c_irq_cam_unmask(unsigned int irqno)
+{
+ s3c_irqsub_unmask(irqno, INTMSK_CAM);
+}
+
+static void
+s3c_irq_cam_ack(unsigned int irqno)
+{
+ s3c_irqsub_maskack(irqno, INTMSK_CAM, 3<<11);
+}
+
+static struct irqchip s3c_irq_cam = {
+ .mask = s3c_irq_cam_mask,
+ .unmask = s3c_irq_cam_unmask,
+ .ack = s3c_irq_cam_ack,
+};
+
+static int s3c2440_irq_add(struct sys_device *sysdev)
+{
+ unsigned int irqno;
+
+ printk("S3C2440: IRQ Support\n");
+
+ set_irq_chip(IRQ_NFCON, &s3c_irq_level_chip);
+ set_irq_handler(IRQ_NFCON, do_level_IRQ);
+ set_irq_flags(IRQ_NFCON, IRQF_VALID);
+
+ /* add new chained handler for wdt, ac7 */
+
+ set_irq_chip(IRQ_WDT, &s3c_irq_level_chip);
+ set_irq_handler(IRQ_WDT, do_level_IRQ);
+ set_irq_chained_handler(IRQ_WDT, s3c_irq_demux_wdtac97);
+
+ for (irqno = IRQ_S3C2440_WDT; irqno <= IRQ_S3C2440_AC97; irqno++) {
+ set_irq_chip(irqno, &s3c_irq_wdtac97);
+ set_irq_handler(irqno, do_level_IRQ);
+ set_irq_flags(irqno, IRQF_VALID);
+ }
+
+ /* add chained handler for camera */
+
+ set_irq_chip(IRQ_CAM, &s3c_irq_level_chip);
+ set_irq_handler(IRQ_CAM, do_level_IRQ);
+ set_irq_chained_handler(IRQ_CAM, s3c_irq_demux_cam);
+
+ for (irqno = IRQ_S3C2440_CAM_C; irqno <= IRQ_S3C2440_CAM_P; irqno++) {
+ set_irq_chip(irqno, &s3c_irq_cam);
+ set_irq_handler(irqno, do_level_IRQ);
+ set_irq_flags(irqno, IRQF_VALID);
+ }
+
+ return 0;
+}
+
+static struct sysdev_driver s3c2440_irq_driver = {
+ .add = s3c2440_irq_add,
+};
+
+static int s3c24xx_irq_driver(void)
+{
+ return sysdev_driver_register(&s3c2440_sysclass, &s3c2440_irq_driver);
+}
+
+arch_initcall(s3c24xx_irq_driver);
+
diff --git a/arch/arm/mm/mm-armv.c b/arch/arm/mm/mm-armv.c
index b19f00e..e33fe42 100644
--- a/arch/arm/mm/mm-armv.c
+++ b/arch/arm/mm/mm-armv.c
@@ -425,6 +425,9 @@ static void __init build_mem_type_table(void)
mem_types[MT_ROM].prot_sect |= PMD_SECT_APX|PMD_SECT_AP_WRITE;
mem_types[MT_MINICLEAN].prot_sect |= PMD_SECT_APX|PMD_SECT_AP_WRITE;
mem_types[MT_CACHECLEAN].prot_sect |= PMD_SECT_APX|PMD_SECT_AP_WRITE;
+
+ mem_types[MT_DEVICE].prot_pte |= L_PTE_BUFFERABLE;
+ mem_types[MT_DEVICE].prot_sect |= PMD_SECT_BUFFERED;
}
cp = &cache_policies[cachepolicy];
diff --git a/arch/arm26/kernel/process.c b/arch/arm26/kernel/process.c
index 46aea6a..9eb9964 100644
--- a/arch/arm26/kernel/process.c
+++ b/arch/arm26/kernel/process.c
@@ -103,9 +103,6 @@ void machine_power_off(void)
{
}
-EXPORT_SYMBOL(machine_halt);
-EXPORT_SYMBOL(machine_power_off);
-
void machine_restart(char * __unused)
{
/*
@@ -136,8 +133,6 @@ void machine_restart(char * __unused)
while (1);
}
-EXPORT_SYMBOL(machine_restart);
-
void show_regs(struct pt_regs * regs)
{
unsigned long flags;
diff --git a/arch/cris/kernel/process.c b/arch/cris/kernel/process.c
index 9f7cad7..a5ad2b6 100644
--- a/arch/cris/kernel/process.c
+++ b/arch/cris/kernel/process.c
@@ -113,6 +113,7 @@
#include <linux/user.h>
#include <linux/elfcore.h>
#include <linux/mqueue.h>
+#include <linux/reboot.h>
//#define DEBUG
@@ -208,13 +209,11 @@ void cpu_idle (void)
void hard_reset_now (void);
-void machine_restart(void)
+void machine_restart(char *cmd)
{
hard_reset_now();
}
-EXPORT_SYMBOL(machine_restart);
-
/*
* Similar to machine_power_off, but don't shut off power. Add code
* here to freeze the system for e.g. post-mortem debug purpose when
@@ -225,16 +224,12 @@ void machine_halt(void)
{
}
-EXPORT_SYMBOL(machine_halt);
-
/* If or when software power-off is implemented, add code here. */
void machine_power_off(void)
{
}
-EXPORT_SYMBOL(machine_power_off);
-
/*
* When a process does an "exec", machine state like FPU and debug
* registers need to be reset. This is a hook function for that.
diff --git a/arch/h8300/kernel/process.c b/arch/h8300/kernel/process.c
index b5f83e9f..27f1fce 100644
--- a/arch/h8300/kernel/process.c
+++ b/arch/h8300/kernel/process.c
@@ -90,8 +90,6 @@ void machine_restart(char * __unused)
__asm__("jmp @@0");
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
local_irq_disable();
@@ -99,8 +97,6 @@ void machine_halt(void)
for (;;);
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
local_irq_disable();
@@ -108,8 +104,6 @@ void machine_power_off(void)
for (;;);
}
-EXPORT_SYMBOL(machine_power_off);
-
void show_regs(struct pt_regs * regs)
{
printk("\nPC: %08lx Status: %02x",
diff --git a/arch/i386/kernel/apm.c b/arch/i386/kernel/apm.c
index 064211d..d7811c4 100644
--- a/arch/i386/kernel/apm.c
+++ b/arch/i386/kernel/apm.c
@@ -911,14 +911,7 @@ static void apm_power_off(void)
0xcd, 0x15 /* int $0x15 */
};
- /*
- * This may be called on an SMP machine.
- */
-#ifdef CONFIG_SMP
/* Some bioses don't like being called from CPU != 0 */
- set_cpus_allowed(current, cpumask_of_cpu(0));
- BUG_ON(smp_processor_id() != 0);
-#endif
if (apm_info.realmode_power_off)
{
(void)apm_save_cpus();
diff --git a/arch/i386/kernel/reboot.c b/arch/i386/kernel/reboot.c
index b3e5848..c71fef3 100644
--- a/arch/i386/kernel/reboot.c
+++ b/arch/i386/kernel/reboot.c
@@ -284,7 +284,7 @@ void machine_shutdown(void)
reboot_cpu_id = 0;
/* See if there has been given a command line override */
- if ((reboot_cpu_id != -1) && (reboot_cpu < NR_CPUS) &&
+ if ((reboot_cpu != -1) && (reboot_cpu < NR_CPUS) &&
cpu_isset(reboot_cpu, cpu_online_map)) {
reboot_cpu_id = reboot_cpu;
}
@@ -311,10 +311,8 @@ void machine_shutdown(void)
#endif
}
-void machine_restart(char * __unused)
+void machine_emergency_restart(void)
{
- machine_shutdown();
-
if (!reboot_thru_bios) {
if (efi_enabled) {
efi.reset_system(EFI_RESET_COLD, EFI_SUCCESS, 0, NULL);
@@ -337,23 +335,22 @@ void machine_restart(char * __unused)
machine_real_restart(jump_to_bios, sizeof(jump_to_bios));
}
-EXPORT_SYMBOL(machine_restart);
+void machine_restart(char * __unused)
+{
+ machine_shutdown();
+ machine_emergency_restart();
+}
void machine_halt(void)
{
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
- lapic_shutdown();
+ machine_shutdown();
- if (efi_enabled)
- efi.reset_system(EFI_RESET_SHUTDOWN, EFI_SUCCESS, 0, NULL);
if (pm_power_off)
pm_power_off();
}
-EXPORT_SYMBOL(machine_power_off);
diff --git a/arch/i386/mach-visws/reboot.c b/arch/i386/mach-visws/reboot.c
index 95e4676..9e92966 100644
--- a/arch/i386/mach-visws/reboot.c
+++ b/arch/i386/mach-visws/reboot.c
@@ -22,8 +22,6 @@ void machine_restart(char * __unused)
outb(PIIX4_RESET_VAL, PIIX4_RESET_PORT);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off(void)
{
unsigned short pm_status;
@@ -43,10 +41,7 @@ void machine_power_off(void)
outl(PIIX_SPECIAL_STOP, 0xCFC);
}
-EXPORT_SYMBOL(machine_power_off);
-
void machine_halt(void)
{
}
-EXPORT_SYMBOL(machine_halt);
diff --git a/arch/i386/mach-voyager/voyager_basic.c b/arch/i386/mach-voyager/voyager_basic.c
index 8680080..b3eda46 100644
--- a/arch/i386/mach-voyager/voyager_basic.c
+++ b/arch/i386/mach-voyager/voyager_basic.c
@@ -278,8 +278,6 @@ machine_restart(char *cmd)
}
}
-EXPORT_SYMBOL(machine_restart);
-
void
mca_nmi_hook(void)
{
@@ -315,12 +313,9 @@ machine_halt(void)
machine_power_off();
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
if (pm_power_off)
pm_power_off();
}
-EXPORT_SYMBOL(machine_power_off);
diff --git a/arch/ia64/kernel/process.c b/arch/ia64/kernel/process.c
index e484910..66e8406 100644
--- a/arch/ia64/kernel/process.c
+++ b/arch/ia64/kernel/process.c
@@ -807,16 +807,12 @@ machine_restart (char *restart_cmd)
(*efi.reset_system)(EFI_RESET_WARM, 0, 0, NULL);
}
-EXPORT_SYMBOL(machine_restart);
-
void
machine_halt (void)
{
cpu_halt();
}
-EXPORT_SYMBOL(machine_halt);
-
void
machine_power_off (void)
{
@@ -825,4 +821,3 @@ machine_power_off (void)
machine_halt();
}
-EXPORT_SYMBOL(machine_power_off);
diff --git a/arch/ia64/sn/kernel/xpc_main.c b/arch/ia64/sn/kernel/xpc_main.c
index d580adc..bb1d5cf 100644
--- a/arch/ia64/sn/kernel/xpc_main.c
+++ b/arch/ia64/sn/kernel/xpc_main.c
@@ -420,7 +420,7 @@ xpc_activating(void *__partid)
partid_t partid = (u64) __partid;
struct xpc_partition *part = &xpc_partitions[partid];
unsigned long irq_flags;
- struct sched_param param = { sched_priority: MAX_USER_RT_PRIO - 1 };
+ struct sched_param param = { sched_priority: MAX_RT_PRIO - 1 };
int ret;
diff --git a/arch/m32r/kernel/process.c b/arch/m32r/kernel/process.c
index b556c3c..ea13a8f 100644
--- a/arch/m32r/kernel/process.c
+++ b/arch/m32r/kernel/process.c
@@ -115,8 +115,6 @@ void machine_restart(char *__unused)
cpu_relax();
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
printk("Please push reset button!\n");
@@ -124,15 +122,11 @@ void machine_halt(void)
cpu_relax();
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
/* M32R_FIXME */
}
-EXPORT_SYMBOL(machine_power_off);
-
static int __init idle_setup (char *str)
{
if (!strncmp(str, "poll", 4)) {
diff --git a/arch/m68k/kernel/process.c b/arch/m68k/kernel/process.c
index 93b043e..11b1b90 100644
--- a/arch/m68k/kernel/process.c
+++ b/arch/m68k/kernel/process.c
@@ -113,8 +113,6 @@ void machine_restart(char * __unused)
for (;;);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
if (mach_halt)
@@ -122,8 +120,6 @@ void machine_halt(void)
for (;;);
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
if (mach_power_off)
@@ -131,8 +127,6 @@ void machine_power_off(void)
for (;;);
}
-EXPORT_SYMBOL(machine_power_off);
-
void show_regs(struct pt_regs * regs)
{
printk("\n");
diff --git a/arch/m68knommu/kernel/process.c b/arch/m68knommu/kernel/process.c
index c4a33f2..82e7ec8 100644
--- a/arch/m68knommu/kernel/process.c
+++ b/arch/m68knommu/kernel/process.c
@@ -80,8 +80,6 @@ void machine_restart(char * __unused)
for (;;);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
if (mach_halt)
@@ -89,8 +87,6 @@ void machine_halt(void)
for (;;);
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
if (mach_power_off)
@@ -98,8 +94,6 @@ void machine_power_off(void)
for (;;);
}
-EXPORT_SYMBOL(machine_power_off);
-
void show_regs(struct pt_regs * regs)
{
printk(KERN_NOTICE "\n");
diff --git a/arch/mips/kernel/reset.c b/arch/mips/kernel/reset.c
index 7e0a982..ae2ba67 100644
--- a/arch/mips/kernel/reset.c
+++ b/arch/mips/kernel/reset.c
@@ -26,18 +26,13 @@ void machine_restart(char *command)
_machine_restart(command);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
_machine_halt();
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
_machine_power_off();
}
-EXPORT_SYMBOL(machine_power_off);
diff --git a/arch/parisc/kernel/process.c b/arch/parisc/kernel/process.c
index 46e4a68..4fc0450 100644
--- a/arch/parisc/kernel/process.c
+++ b/arch/parisc/kernel/process.c
@@ -150,8 +150,6 @@ void machine_restart(char *cmd)
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
/*
@@ -160,8 +158,6 @@ void machine_halt(void)
*/
}
-EXPORT_SYMBOL(machine_halt);
-
/*
* This routine is called from sys_reboot to actually turn off the
@@ -187,8 +183,6 @@ void machine_power_off(void)
KERN_EMERG "Please power this system off now.");
}
-EXPORT_SYMBOL(machine_power_off);
-
/*
* Create a kernel thread
diff --git a/arch/ppc/kernel/setup.c b/arch/ppc/kernel/setup.c
index c42f753..929e5d1 100644
--- a/arch/ppc/kernel/setup.c
+++ b/arch/ppc/kernel/setup.c
@@ -121,8 +121,6 @@ void machine_restart(char *cmd)
ppc_md.restart(cmd);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off(void)
{
#ifdef CONFIG_NVRAM
@@ -131,8 +129,6 @@ void machine_power_off(void)
ppc_md.power_off();
}
-EXPORT_SYMBOL(machine_power_off);
-
void machine_halt(void)
{
#ifdef CONFIG_NVRAM
@@ -141,8 +137,6 @@ void machine_halt(void)
ppc_md.halt();
}
-EXPORT_SYMBOL(machine_halt);
-
void (*pm_power_off)(void) = machine_power_off;
#ifdef CONFIG_TAU
diff --git a/arch/ppc64/kernel/setup.c b/arch/ppc64/kernel/setup.c
index d1b33f0..e80f10c 100644
--- a/arch/ppc64/kernel/setup.c
+++ b/arch/ppc64/kernel/setup.c
@@ -694,7 +694,6 @@ void machine_restart(char *cmd)
local_irq_disable();
while (1) ;
}
-EXPORT_SYMBOL(machine_restart);
void machine_power_off(void)
{
@@ -707,7 +706,6 @@ void machine_power_off(void)
local_irq_disable();
while (1) ;
}
-EXPORT_SYMBOL(machine_power_off);
void machine_halt(void)
{
@@ -720,7 +718,6 @@ void machine_halt(void)
local_irq_disable();
while (1) ;
}
-EXPORT_SYMBOL(machine_halt);
static int ppc64_panic_event(struct notifier_block *this,
unsigned long event, void *ptr)
diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c
index b6d740a..a121839 100644
--- a/arch/s390/kernel/setup.c
+++ b/arch/s390/kernel/setup.c
@@ -299,24 +299,18 @@ void machine_restart(char *command)
_machine_restart(command);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
console_unblank();
_machine_halt();
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
console_unblank();
_machine_power_off();
}
-EXPORT_SYMBOL(machine_power_off);
-
static void __init
add_memory_hole(unsigned long start, unsigned long end)
{
diff --git a/arch/sh/kernel/process.c b/arch/sh/kernel/process.c
index 3d02459..6dce9d0 100644
--- a/arch/sh/kernel/process.c
+++ b/arch/sh/kernel/process.c
@@ -80,8 +80,6 @@ void machine_restart(char * __unused)
"mov.l @%1, %0" : : "r" (0x10000000), "r" (0x80000001));
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt(void)
{
#if defined(CONFIG_SH_HS7751RVOIP)
@@ -96,8 +94,6 @@ void machine_halt(void)
cpu_sleep();
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
#if defined(CONFIG_SH_HS7751RVOIP)
@@ -110,8 +106,6 @@ void machine_power_off(void)
#endif
}
-EXPORT_SYMBOL(machine_power_off);
-
void show_regs(struct pt_regs * regs)
{
printk("\n");
diff --git a/arch/sparc/kernel/process.c b/arch/sparc/kernel/process.c
index 2c216ff..29e72b5 100644
--- a/arch/sparc/kernel/process.c
+++ b/arch/sparc/kernel/process.c
@@ -158,8 +158,6 @@ void machine_halt(void)
panic("Halt failed!");
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_restart(char * cmd)
{
char *p;
@@ -180,8 +178,6 @@ void machine_restart(char * cmd)
panic("Reboot failed!");
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off(void)
{
#ifdef CONFIG_SUN_AUXIO
@@ -191,8 +187,6 @@ void machine_power_off(void)
machine_halt();
}
-EXPORT_SYMBOL(machine_power_off);
-
static DEFINE_SPINLOCK(sparc_backtrace_lock);
void __show_backtrace(unsigned long fp)
diff --git a/arch/sparc64/kernel/power.c b/arch/sparc64/kernel/power.c
index 533104c..946cee0 100644
--- a/arch/sparc64/kernel/power.c
+++ b/arch/sparc64/kernel/power.c
@@ -69,8 +69,6 @@ void machine_power_off(void)
machine_halt();
}
-EXPORT_SYMBOL(machine_power_off);
-
#ifdef CONFIG_PCI
static int powerd(void *__unused)
{
diff --git a/arch/sparc64/kernel/process.c b/arch/sparc64/kernel/process.c
index cffb1c8..07424b0 100644
--- a/arch/sparc64/kernel/process.c
+++ b/arch/sparc64/kernel/process.c
@@ -124,8 +124,6 @@ void machine_halt(void)
panic("Halt failed!");
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_alt_power_off(void)
{
if (!serial_console && prom_palette)
@@ -154,8 +152,6 @@ void machine_restart(char * cmd)
panic("Reboot failed!");
}
-EXPORT_SYMBOL(machine_restart);
-
static void show_regwindow32(struct pt_regs *regs)
{
struct reg_window32 __user *rw;
diff --git a/arch/um/kernel/reboot.c b/arch/um/kernel/reboot.c
index fcec51d..a637e88 100644
--- a/arch/um/kernel/reboot.c
+++ b/arch/um/kernel/reboot.c
@@ -49,23 +49,17 @@ void machine_restart(char * __unused)
CHOOSE_MODE(reboot_tt(), reboot_skas());
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off(void)
{
uml_cleanup();
CHOOSE_MODE(halt_tt(), halt_skas());
}
-EXPORT_SYMBOL(machine_power_off);
-
void machine_halt(void)
{
machine_power_off();
}
-EXPORT_SYMBOL(machine_halt);
-
/*
* Overrides for Emacs so that we follow Linus's tabbing style.
* Emacs will notice this stuff at the end of the file and automatically
diff --git a/arch/v850/kernel/anna.c b/arch/v850/kernel/anna.c
index 6aaeab5..d0502e1 100644
--- a/arch/v850/kernel/anna.c
+++ b/arch/v850/kernel/anna.c
@@ -132,8 +132,6 @@ void machine_restart (char *__unused)
asm ("jmp r0"); /* Jump to the reset vector. */
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt (void)
{
#ifdef CONFIG_RESET_GUARD
@@ -145,15 +143,11 @@ void machine_halt (void)
asm ("halt; nop; nop; nop; nop; nop");
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off (void)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_power_off);
-
/* Called before configuring an on-chip UART. */
void anna_uart_pre_configure (unsigned chan, unsigned cflags, unsigned baud)
{
diff --git a/arch/v850/kernel/as85ep1.c b/arch/v850/kernel/as85ep1.c
index 4059b1d..d78c5e4 100644
--- a/arch/v850/kernel/as85ep1.c
+++ b/arch/v850/kernel/as85ep1.c
@@ -160,8 +160,6 @@ void machine_restart (char *__unused)
asm ("jmp r0"); /* Jump to the reset vector. */
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt (void)
{
#ifdef CONFIG_RESET_GUARD
@@ -173,15 +171,11 @@ void machine_halt (void)
asm ("halt; nop; nop; nop; nop; nop");
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off (void)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_power_off);
-
/* Called before configuring an on-chip UART. */
void as85ep1_uart_pre_configure (unsigned chan, unsigned cflags, unsigned baud)
{
diff --git a/arch/v850/kernel/fpga85e2c.c b/arch/v850/kernel/fpga85e2c.c
index 4bac514..d809451 100644
--- a/arch/v850/kernel/fpga85e2c.c
+++ b/arch/v850/kernel/fpga85e2c.c
@@ -121,22 +121,16 @@ void machine_halt (void)
}
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_restart (char *__unused)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off (void)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_power_off);
-
/* Interrupts */
diff --git a/arch/v850/kernel/rte_cb.c b/arch/v850/kernel/rte_cb.c
index 7ba397f..0c794b9 100644
--- a/arch/v850/kernel/rte_cb.c
+++ b/arch/v850/kernel/rte_cb.c
@@ -67,8 +67,6 @@ void machine_restart (char *__unused)
asm ("jmp r0"); /* Jump to the reset vector. */
}
-EXPORT_SYMBOL(machine_restart);
-
/* This says `HALt.' in LEDese. */
static unsigned char halt_leds_msg[] = { 0x76, 0x77, 0x38, 0xF8 };
@@ -89,15 +87,11 @@ void machine_halt (void)
asm ("halt; nop; nop; nop; nop; nop");
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off (void)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_power_off);
-
/* Animated LED display for timer tick. */
diff --git a/arch/v850/kernel/sim.c b/arch/v850/kernel/sim.c
index 4f31da9..e2cc558 100644
--- a/arch/v850/kernel/sim.c
+++ b/arch/v850/kernel/sim.c
@@ -104,24 +104,18 @@ void machine_restart (char *__unused)
V850_SIM_SYSCALL (exit, 0);
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_halt (void)
{
V850_SIM_SYSCALL (write, 1, "HALT\n", 5);
V850_SIM_SYSCALL (exit, 0);
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off (void)
{
V850_SIM_SYSCALL (write, 1, "POWER OFF\n", 10);
V850_SIM_SYSCALL (exit, 0);
}
-EXPORT_SYMBOL(machine_power_off);
-
/* Load data from a file called NAME into ram. The address and length
of the data image are returned in ADDR and LEN. */
diff --git a/arch/v850/kernel/sim85e2.c b/arch/v850/kernel/sim85e2.c
index 93a722b..9111613 100644
--- a/arch/v850/kernel/sim85e2.c
+++ b/arch/v850/kernel/sim85e2.c
@@ -184,18 +184,13 @@ void machine_halt (void)
for (;;) {}
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_restart (char *__unused)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_restart);
-
void machine_power_off (void)
{
machine_halt ();
}
-EXPORT_SYMBOL(machine_power_off);
diff --git a/arch/x86_64/ia32/ia32entry.S b/arch/x86_64/ia32/ia32entry.S
index cc93542..c45d6a0 100644
--- a/arch/x86_64/ia32/ia32entry.S
+++ b/arch/x86_64/ia32/ia32entry.S
@@ -591,11 +591,15 @@ ia32_sys_call_table:
.quad compat_sys_mq_getsetattr
.quad compat_sys_kexec_load /* reserved for kexec */
.quad compat_sys_waitid
- .quad quiet_ni_syscall /* sys_altroot */
+ .quad quiet_ni_syscall /* 285: sys_altroot */
.quad sys_add_key
.quad sys_request_key
.quad sys_keyctl
- /* don't forget to change IA32_NR_syscalls */
+ .quad sys_ioprio_set
+ .quad sys_ioprio_get /* 290 */
+ .quad sys_inotify_init
+ .quad sys_inotify_add_watch
+ .quad sys_inotify_rm_watch
ia32_syscall_end:
.rept IA32_NR_syscalls-(ia32_syscall_end-ia32_sys_call_table)/8
.quad ni_syscall
diff --git a/arch/x86_64/ia32/sys_ia32.c b/arch/x86_64/ia32/sys_ia32.c
index 68a9ab0..be996d1b 100644
--- a/arch/x86_64/ia32/sys_ia32.c
+++ b/arch/x86_64/ia32/sys_ia32.c
@@ -61,6 +61,7 @@
#include <linux/ptrace.h>
#include <linux/highuid.h>
#include <linux/vmalloc.h>
+#include <linux/fsnotify.h>
#include <asm/mman.h>
#include <asm/types.h>
#include <asm/uaccess.h>
@@ -984,8 +985,10 @@ asmlinkage long sys32_open(const char __user * filename, int flags, int mode)
if (IS_ERR(f)) {
put_unused_fd(fd);
fd = error;
- } else
+ } else {
+ fsnotify_open(f->f_dentry);
fd_install(fd, f);
+ }
}
putname(tmp);
}
diff --git a/arch/x86_64/kernel/reboot.c b/arch/x86_64/kernel/reboot.c
index 57e71db..47f9568 100644
--- a/arch/x86_64/kernel/reboot.c
+++ b/arch/x86_64/kernel/reboot.c
@@ -109,23 +109,10 @@ void machine_shutdown(void)
local_irq_enable();
}
-void machine_restart(char * __unused)
+void machine_emergency_restart(void)
{
int i;
- printk("machine restart\n");
-
- machine_shutdown();
-
- if (!reboot_force) {
- local_irq_disable();
-#ifndef CONFIG_SMP
- disable_local_APIC();
-#endif
- disable_IO_APIC();
- local_irq_enable();
- }
-
/* Tell the BIOS if we want cold or warm reboot */
*((unsigned short *)__va(0x472)) = reboot_mode;
@@ -150,18 +137,26 @@ void machine_restart(char * __unused)
}
}
-EXPORT_SYMBOL(machine_restart);
+void machine_restart(char * __unused)
+{
+ printk("machine restart\n");
+
+ if (!reboot_force) {
+ machine_shutdown();
+ }
+ machine_emergency_restart();
+}
void machine_halt(void)
{
}
-EXPORT_SYMBOL(machine_halt);
-
void machine_power_off(void)
{
+ if (!reboot_force) {
+ machine_shutdown();
+ }
if (pm_power_off)
pm_power_off();
}
-EXPORT_SYMBOL(machine_power_off);