Skip to content

Commit

Permalink
Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6
Browse files Browse the repository at this point in the history
* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (127 commits)
  sh: update defconfigs.
  sh: Fix up the NUMA build for recent LMB changes.
  sh64: provide a stub per_cpu_trap_init() definition.
  sh: fix up CONFIG_KEXEC=n build.
  sh: fixup the docbook paths for clock framework shuffling.
  driver core: Early dev_name() depends on slab_is_available().
  sh: simplify WARN usage in SH clock driver
  sh: Check return value of clk_get on ms7724
  sh: Check return value of clk_get on ecovec24
  sh: move sh clock-cpg.c contents to drivers/sh/clk-cpg.c
  sh: move sh clock.c contents to drivers/sh/clk.
  sh: move sh asm/clock.h contents to linux/sh_clk.h V2
  sh: remove unused clock lookup
  sh: switch boards to clkdev
  sh: switch sh4-202 to clkdev
  sh: switch shx3 to clkdev
  sh: switch sh7757 to clkdev
  sh: switch sh7763 to clkdev
  sh: switch sh7780 to clkdev
  sh: switch sh7786 to clkdev
  ...
  • Loading branch information
Linus Torvalds committed May 19, 2010
2 parents ba0234e + 4d0956b commit 7c7cbaf
Show file tree
Hide file tree
Showing 172 changed files with 6,107 additions and 3,743 deletions.
10 changes: 7 additions & 3 deletions Documentation/DocBook/sh.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,17 @@
</authorgroup>

<copyright>
<year>2008</year>
<year>2008-2010</year>
<holder>Paul Mundt</holder>
</copyright>
<copyright>
<year>2008</year>
<year>2008-2010</year>
<holder>Renesas Technology Corp.</holder>
</copyright>
<copyright>
<year>2010</year>
<holder>Renesas Electronics Corp.</holder>
</copyright>

<legalnotice>
<para>
Expand Down Expand Up @@ -77,7 +81,7 @@
</chapter>
<chapter id="clk">
<title>Clock Framework Extensions</title>
!Iarch/sh/include/asm/clock.h
!Iinclude/linux/sh_clk.h
</chapter>
<chapter id="mach">
<title>Machine Specific Interfaces</title>
Expand Down
36 changes: 28 additions & 8 deletions arch/sh/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ config LOCKDEP_SUPPORT

config HAVE_LATENCYTOP_SUPPORT
def_bool y
depends on !SMP

config ARCH_HAS_ILOG2_U32
def_bool n
Expand Down Expand Up @@ -238,6 +237,8 @@ config CPU_SHX2
config CPU_SHX3
bool
select DMA_COHERENT
select SYS_SUPPORTS_SMP
select SYS_SUPPORTS_NUMA

config ARCH_SHMOBILE
bool
Expand Down Expand Up @@ -454,18 +455,12 @@ config CPU_SUBTYPE_SH7786
select CPU_SH4A
select CPU_SHX3
select CPU_HAS_PTEAEX
select ARCH_SPARSEMEM_ENABLE
select SYS_SUPPORTS_NUMA
select SYS_SUPPORTS_SMP
select GENERIC_CLOCKEVENTS_BROADCAST if SMP

config CPU_SUBTYPE_SHX3
bool "Support SH-X3 processor"
select CPU_SH4A
select CPU_SHX3
select ARCH_SPARSEMEM_ENABLE
select SYS_SUPPORTS_NUMA
select SYS_SUPPORTS_SMP
select GENERIC_CLOCKEVENTS_BROADCAST if SMP

# SH4AL-DSP Processor Support
Expand Down Expand Up @@ -635,7 +630,7 @@ config KEXEC

config CRASH_DUMP
bool "kernel crash dumps (EXPERIMENTAL)"
depends on SUPERH32 && EXPERIMENTAL
depends on SUPERH32 && EXPERIMENTAL && BROKEN_ON_SMP
help
Generate crash dump after being started by kexec.
This should be normally only set in special crash dump kernels
Expand Down Expand Up @@ -707,6 +702,13 @@ config NR_CPUS
This is purely to save memory - each supported CPU adds
approximately eight kilobytes to the kernel image.

config HOTPLUG_CPU
bool "Support for hot-pluggable CPUs (EXPERIMENTAL)"
depends on SMP && HOTPLUG && EXPERIMENTAL
help
Say Y here to experiment with turning CPUs off and on. CPUs
can be controlled through /sys/devices/system/cpu.

source "kernel/Kconfig.preempt"

config GUSA
Expand All @@ -733,6 +735,8 @@ config GUSA_RB
LLSC, this should be more efficient than the other alternative of
disabling interrupts around the atomic sequence.

source "drivers/sh/Kconfig"

endmenu

menu "Boot options"
Expand Down Expand Up @@ -864,4 +868,20 @@ source "security/Kconfig"

source "crypto/Kconfig"

menuconfig VIRTUALIZATION
bool "Virtualization"
default n
---help---
Say Y here to get to see options for using your Linux host to run other
operating systems inside virtual machines (guests).
This option alone does not add any kernel code.

If you say N, all options in this submenu will be skipped and disabled.

if VIRTUALIZATION

source drivers/virtio/Kconfig

endif # VIRTUALIZATION

source "lib/Kconfig"
1 change: 0 additions & 1 deletion arch/sh/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,6 @@ defaultimage-$(CONFIG_SH_AP325RXA) := uImage
defaultimage-$(CONFIG_SH_7724_SOLUTION_ENGINE) := uImage
defaultimage-$(CONFIG_SH_7206_SOLUTION_ENGINE) := vmlinux
defaultimage-$(CONFIG_SH_7619_SOLUTION_ENGINE) := vmlinux
defaultimage-$(CONFIG_SH_SDK7786) := vmlinux.bin

# Set some sensible Kbuild defaults
KBUILD_IMAGE := $(defaultimage-y)
Expand Down
3 changes: 3 additions & 0 deletions arch/sh/boards/board-urquell.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
#include <cpu/sh7786.h>
#include <asm/heartbeat.h>
#include <asm/sizes.h>
#include <asm/smp-ops.h>

/*
* bit 1234 5678
Expand Down Expand Up @@ -203,6 +204,8 @@ static void __init urquell_setup(char **cmdline_p)
printk(KERN_INFO "Renesas Technology Corp. Urquell support.\n");

pm_power_off = urquell_power_off;

register_smp_ops(&shx3_smp_ops);
}

/*
Expand Down
26 changes: 15 additions & 11 deletions arch/sh/boards/mach-ecovec24/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -710,8 +710,6 @@ static struct clk_ops fsimck_clk_ops = {
};

static struct clk fsimckb_clk = {
.name = "fsimckb_clk",
.id = -1,
.ops = &fsimck_clk_ops,
.enable_reg = (void __iomem *)FCLKBCR,
.rate = 0, /* unknown */
Expand Down Expand Up @@ -1138,16 +1136,20 @@ static int __init arch_setup(void)

/* set SPU2 clock to 83.4 MHz */
clk = clk_get(NULL, "spu_clk");
clk_set_rate(clk, clk_round_rate(clk, 83333333));
clk_put(clk);
if (clk) {
clk_set_rate(clk, clk_round_rate(clk, 83333333));
clk_put(clk);
}

/* change parent of FSI B */
clk = clk_get(NULL, "fsib_clk");
clk_register(&fsimckb_clk);
clk_set_parent(clk, &fsimckb_clk);
clk_set_rate(clk, 11000);
clk_set_rate(&fsimckb_clk, 11000);
clk_put(clk);
if (clk) {
clk_register(&fsimckb_clk);
clk_set_parent(clk, &fsimckb_clk);
clk_set_rate(clk, 11000);
clk_set_rate(&fsimckb_clk, 11000);
clk_put(clk);
}

gpio_request(GPIO_PTU0, NULL);
gpio_direction_output(GPIO_PTU0, 0);
Expand All @@ -1159,8 +1161,10 @@ static int __init arch_setup(void)

/* set VPU clock to 166 MHz */
clk = clk_get(NULL, "vpu_clk");
clk_set_rate(clk, clk_round_rate(clk, 166000000));
clk_put(clk);
if (clk) {
clk_set_rate(clk, clk_round_rate(clk, 166000000));
clk_put(clk);
}

/* enable IrDA */
gpio_request(GPIO_FN_IRDA_OUT, NULL);
Expand Down
12 changes: 11 additions & 1 deletion arch/sh/boards/mach-highlander/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
* for more details.
*/
#include <linux/init.h>
#include <linux/io.h>
#include <linux/platform_device.h>
#include <linux/ata_platform.h>
#include <linux/types.h>
Expand All @@ -26,6 +27,7 @@
#include <net/ax88796.h>
#include <asm/machvec.h>
#include <mach/highlander.h>
#include <asm/clkdev.h>
#include <asm/clock.h>
#include <asm/heartbeat.h>
#include <asm/io.h>
Expand Down Expand Up @@ -326,14 +328,20 @@ static struct clk_ops ivdr_clk_ops = {
};

static struct clk ivdr_clk = {
.name = "ivdr_clk",
.ops = &ivdr_clk_ops,
};

static struct clk *r7780rp_clocks[] = {
&ivdr_clk,
};

#define CLKDEV_CON_ID(_id, _clk) { .con_id = _id, .clk = _clk }

static struct clk_lookup lookups[] = {
/* main clocks */
CLKDEV_CON_ID("ivdr_clk", &ivdr_clk),
};

static void r7780rp_power_off(void)
{
if (mach_is_r7780mp() || mach_is_r7785rp())
Expand Down Expand Up @@ -370,6 +378,8 @@ static void __init highlander_setup(char **cmdline_p)
clk_enable(clk);
}

clkdev_add_table(lookups, ARRAY_SIZE(lookups));

__raw_writew(0x0000, PA_OBLED); /* Clear LED. */

if (mach_is_r7780rp())
Expand Down
17 changes: 17 additions & 0 deletions arch/sh/boards/mach-sdk7786/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
#include <asm/heartbeat.h>
#include <asm/sizes.h>
#include <asm/reboot.h>
#include <asm/smp-ops.h>

static struct resource heartbeat_resource = {
.start = 0x07fff8b0,
Expand Down Expand Up @@ -165,6 +166,19 @@ static void sdk7786_restart(char *cmd)
fpga_write_reg(0xa5a5, SRSTR);
}

static void sdk7786_power_off(void)
{
fpga_write_reg(fpga_read_reg(PWRCR) | PWRCR_PDWNREQ, PWRCR);

/*
* It can take up to 20us for the R8C to do its job, back off and
* wait a bit until we've been shut off. Even though newer FPGA
* versions don't set the ACK bit, the latency issue remains.
*/
while ((fpga_read_reg(PWRCR) & PWRCR_PDWNACK) == 0)
cpu_sleep();
}

/* Initialize the board */
static void __init sdk7786_setup(char **cmdline_p)
{
Expand All @@ -175,6 +189,9 @@ static void __init sdk7786_setup(char **cmdline_p)
pr_info("\tPCB revision:\t%d\n", fpga_read_reg(PCBRR) & 0xf);

machine_ops.restart = sdk7786_restart;
pm_power_off = sdk7786_power_off;

register_smp_ops(&shx3_smp_ops);
}

/*
Expand Down
20 changes: 11 additions & 9 deletions arch/sh/boards/mach-se/7724/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -276,8 +276,6 @@ static struct clk_ops fsimck_clk_ops = {
};

static struct clk fsimcka_clk = {
.name = "fsimcka_clk",
.id = -1,
.ops = &fsimck_clk_ops,
.enable_reg = (void __iomem *)FCLKACR,
.rate = 0, /* unknown */
Expand Down Expand Up @@ -771,16 +769,20 @@ static int __init devices_setup(void)

/* set SPU2 clock to 83.4 MHz */
clk = clk_get(NULL, "spu_clk");
clk_set_rate(clk, clk_round_rate(clk, 83333333));
clk_put(clk);
if (clk) {
clk_set_rate(clk, clk_round_rate(clk, 83333333));
clk_put(clk);
}

/* change parent of FSI A */
clk = clk_get(NULL, "fsia_clk");
clk_register(&fsimcka_clk);
clk_set_parent(clk, &fsimcka_clk);
clk_set_rate(clk, 11000);
clk_set_rate(&fsimcka_clk, 11000);
clk_put(clk);
if (clk) {
clk_register(&fsimcka_clk);
clk_set_parent(clk, &fsimcka_clk);
clk_set_rate(clk, 11000);
clk_set_rate(&fsimcka_clk, 11000);
clk_put(clk);
}

/* SDHI0 connected to cn7 */
gpio_request(GPIO_FN_SDHI0CD, NULL);
Expand Down
7 changes: 7 additions & 0 deletions arch/sh/boards/mach-x3proto/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
#include <linux/usb/r8a66597.h>
#include <linux/usb/m66592.h>
#include <asm/ilsel.h>
#include <asm/smp-ops.h>

static struct resource heartbeat_resources[] = {
[0] = {
Expand Down Expand Up @@ -152,7 +153,13 @@ static void __init x3proto_init_irq(void)
__raw_writel(__raw_readl(0xfe410000) | (1 << 21), 0xfe410000);
}

static void __init x3proto_setup(char **cmdline_p)
{
register_smp_ops(&shx3_smp_ops);
}

static struct sh_machine_vector mv_x3proto __initmv = {
.mv_name = "x3proto",
.mv_setup = x3proto_setup,
.mv_init_irq = x3proto_init_irq,
};
6 changes: 6 additions & 0 deletions arch/sh/boot/compressed/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,16 @@ OBJECTS = $(obj)/head_$(BITS).o $(obj)/misc.o $(obj)/cache.o
#
# IMAGE_OFFSET is the load offset of the compression loader
#
ifeq ($(CONFIG_32BIT),y)
IMAGE_OFFSET := $(shell /bin/bash -c 'printf "0x%08x" \
$$[$(CONFIG_MEMORY_START) + \
$(CONFIG_BOOT_LINK_OFFSET)]')
else
IMAGE_OFFSET := $(shell /bin/bash -c 'printf "0x%08x" \
$$[$(CONFIG_PAGE_OFFSET) + \
$(KERNEL_MEMORY) + \
$(CONFIG_BOOT_LINK_OFFSET)]')
endif

LIBGCC := $(shell $(CC) $(KBUILD_CFLAGS) -print-libgcc-file-name)

Expand Down
4 changes: 4 additions & 0 deletions arch/sh/boot/compressed/head_32.S
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,11 @@ init_stack_addr:
decompress_kernel_addr:
.long decompress_kernel
kernel_start_addr:
#ifdef CONFIG_32BIT
.long ___pa(_text+PAGE_SIZE)
#else
.long _text+PAGE_SIZE
#endif

.align 9
fake_headers_as_bzImage:
Expand Down
Loading

0 comments on commit 7c7cbaf

Please sign in to comment.