From 6bf853aeb1d840222aebe532ad5afc861f4d0fbb Mon Sep 17 00:00:00 2001 From: Paul Mundt Date: Thu, 16 Apr 2009 14:15:38 +0900 Subject: sh: sh7722: Don't default enable the RTC clock. rtc-sh takes care of this now, so no need to have this always enabled. Signed-off-by: Paul Mundt --- arch/sh/kernel/cpu/sh4a/setup-sh7722.c | 1 - 1 file changed, 1 deletion(-) (limited to 'arch') diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7722.c b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c index 0e5d204bc79..406747f07dc 100644 --- a/arch/sh/kernel/cpu/sh4a/setup-sh7722.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c @@ -256,7 +256,6 @@ static int __init sh7722_devices_setup(void) { clk_always_enable("uram0"); /* URAM */ clk_always_enable("xymem0"); /* XYMEM */ - clk_always_enable("rtc0"); /* RTC */ clk_always_enable("veu0"); /* VEU */ clk_always_enable("vpu0"); /* VPU */ clk_always_enable("jpu0"); /* JPU */ -- cgit v1.2.3 From b8c193f88ebd8705b3e916532539031cd9fc0b4c Mon Sep 17 00:00:00 2001 From: Paul Mundt Date: Thu, 16 Apr 2009 14:16:33 +0900 Subject: sh: sh7723: Don't default enable the RTC clock. rtc-sh takes care of this now, so no need to have this always enabled. Signed-off-by: Paul Mundt --- arch/sh/kernel/cpu/sh4a/setup-sh7723.c | 1 - 1 file changed, 1 deletion(-) (limited to 'arch') diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7723.c b/arch/sh/kernel/cpu/sh4a/setup-sh7723.c index 5338dacbcfb..a800466b938 100644 --- a/arch/sh/kernel/cpu/sh4a/setup-sh7723.c +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7723.c @@ -267,7 +267,6 @@ static struct platform_device *sh7723_devices[] __initdata = { static int __init sh7723_devices_setup(void) { clk_always_enable("meram0"); /* MERAM */ - clk_always_enable("rtc0"); /* RTC */ clk_always_enable("veu1"); /* VEU2H1 */ clk_always_enable("veu0"); /* VEU2H0 */ clk_always_enable("vpu0"); /* VPU */ -- cgit v1.2.3 From 8c31813f31cd4403b46802866949a95a6e8fa584 Mon Sep 17 00:00:00 2001 From: Toshinobu Sugioka Date: Tue, 21 Apr 2009 07:34:53 +0900 Subject: sh: Fix mmap2 for handling differing PAGE_SIZEs. mmap2 uses a fixed page shift of 12, regardless of the PAGE_SIZE setting. Fix up the mmap2 code to add some sanity checks on the mapping, and to update pgoff accordingly. Error handling bits based on 4280e3126f641898f0ed1a931645373d3489e2a6 ("frv: fix mmap2 error handling"). Signed-off-by: Toshinobu Sugioka Signed-off-by: Paul Mundt --- arch/sh/kernel/sys_sh.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'arch') diff --git a/arch/sh/kernel/sys_sh.c b/arch/sh/kernel/sys_sh.c index 58dfc02c7af..e3a7e36639e 100644 --- a/arch/sh/kernel/sys_sh.c +++ b/arch/sh/kernel/sys_sh.c @@ -63,6 +63,15 @@ asmlinkage long sys_mmap2(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff) { + /* + * The shift for mmap2 is constant, regardless of PAGE_SIZE + * setting. + */ + if (pgoff & ((1 << (PAGE_SHIFT - 12)) - 1)) + return -EINVAL; + + pgoff >>= PAGE_SHIFT - 12; + return do_mmap2(addr, len, prot, flags, fd, pgoff); } -- cgit v1.2.3