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: (56 commits)
  sh: Fix declaration of __kernel_sigreturn and __kernel_rt_sigreturn
  sh: Enable soc-camera in ap325rxa/migor/se7724 defconfigs.
  sh: remove stray markers.
  sh: defconfig updates.
  sh: pci: Initial PCI-Express support for SH7786 Urquell board.
  sh: Generic HAVE_PERF_COUNTER support.
  SH: convert migor to soc-camera as platform-device
  SH: convert ap325rxa to soc-camera as platform-device
  soc-camera: unify i2c camera device platform data
  sh: add platform data for r8a66597-hcd in setup-sh7723
  sh: add platform data for r8a66597-hcd in setup-sh7366
  sh: x3proto: add platform data for r8a66597-hcd
  sh: highlander: add platform data for r8a66597-hcd
  sh: sh7785lcr: add platform data for r8a66597-hcd
  sh: turn off irqs when disabling CMT/TMU timers
  sh: use kzalloc() for cpg clocks
  sh: unbreak WARN_ON()
  sh: Use generic atomic64_t implementation.
  sh: Revised clock function in highlander
  sh: Update r7780mp defconfig
  ...
  • Loading branch information
Linus Torvalds committed Jun 18, 2009
2 parents d2aa455 + 9445571 commit 15fc204
Show file tree
Hide file tree
Showing 123 changed files with 3,835 additions and 3,743 deletions.
6 changes: 6 additions & 0 deletions arch/sh/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ config SUPERH
select HAVE_IOREMAP_PROT if MMU
select HAVE_ARCH_TRACEHOOK
select HAVE_DMA_API_DEBUG
select HAVE_PERF_COUNTER
select RTC_LIB
select GENERIC_ATOMIC64
help
The SuperH is a RISC processor targeted for use in embedded systems
and consumer electronics; it was also used in the Sega Dreamcast
Expand Down Expand Up @@ -50,6 +52,10 @@ config GENERIC_BUG
def_bool y
depends on BUG && SUPERH32

config GENERIC_CSUM
def_bool y
depends on SUPERH64

config GENERIC_FIND_NEXT_BIT
def_bool y

Expand Down
1 change: 1 addition & 0 deletions arch/sh/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ config EARLY_SCIF_CONSOLE_PORT
CPU_SUBTYPE_SH7722 || CPU_SUBTYPE_SH7366 || \
CPU_SUBTYPE_SH7343
default "0xffea0000" if CPU_SUBTYPE_SH7785
default "0xffeb0000" if CPU_SUBTYPE_SH7786
default "0xfffe8000" if CPU_SUBTYPE_SH7203
default "0xfffe9800" if CPU_SUBTYPE_SH7206 || CPU_SUBTYPE_SH7263
default "0xffe80000" if CPU_SH4
Expand Down
1 change: 1 addition & 0 deletions arch/sh/boards/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ config SH_URQUELL
bool "Urquell"
depends on CPU_SUBTYPE_SH7786
select ARCH_REQUIRE_GPIOLIB
select SYS_SUPPORTS_PCI

config SH_MIGOR
bool "Migo-R"
Expand Down
52 changes: 33 additions & 19 deletions arch/sh/boards/board-ap325rxa.c
Original file line number Diff line number Diff line change
Expand Up @@ -349,15 +349,6 @@ static int ov7725_power(struct device *dev, int mode)
return 0;
}

static struct ov772x_camera_info ov7725_info = {
.buswidth = SOCAM_DATAWIDTH_8,
.flags = OV772X_FLAG_VFLIP | OV772X_FLAG_HFLIP,
.edgectrl = OV772X_AUTO_EDGECTRL(0xf, 0),
.link = {
.power = ov7725_power,
},
};

static struct sh_mobile_ceu_info sh_mobile_ceu_info = {
.flags = SH_CEU_FLAG_USE_8BIT_BUS,
};
Expand Down Expand Up @@ -402,25 +393,48 @@ static struct platform_device sdcard_cn3_device = {
},
};

static struct platform_device *ap325rxa_devices[] __initdata = {
&smsc9118_device,
&ap325rxa_nor_flash_device,
&lcdc_device,
&ceu_device,
&nand_flash_device,
&sdcard_cn3_device,
};

static struct i2c_board_info __initdata ap325rxa_i2c_devices[] = {
{
I2C_BOARD_INFO("pcf8563", 0x51),
},
};

static struct i2c_board_info ap325rxa_i2c_camera[] = {
{
I2C_BOARD_INFO("ov772x", 0x21),
.platform_data = &ov7725_info,
},
};

static struct ov772x_camera_info ov7725_info = {
.buswidth = SOCAM_DATAWIDTH_8,
.flags = OV772X_FLAG_VFLIP | OV772X_FLAG_HFLIP,
.edgectrl = OV772X_AUTO_EDGECTRL(0xf, 0),
.link = {
.power = ov7725_power,
.board_info = &ap325rxa_i2c_camera[0],
.i2c_adapter_id = 0,
.module_name = "ov772x",
},
};

static struct platform_device ap325rxa_camera = {
.name = "soc-camera-pdrv",
.id = 0,
.dev = {
.platform_data = &ov7725_info.link,
},
};

static struct platform_device *ap325rxa_devices[] __initdata = {
&smsc9118_device,
&ap325rxa_nor_flash_device,
&lcdc_device,
&ceu_device,
&nand_flash_device,
&sdcard_cn3_device,
&ap325rxa_camera,
};

static struct spi_board_info ap325rxa_spi_devices[] = {
{
.modalias = "mmc_spi",
Expand Down
14 changes: 10 additions & 4 deletions arch/sh/boards/board-sh7785lcr.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,16 +15,18 @@
#include <linux/fb.h>
#include <linux/mtd/physmap.h>
#include <linux/delay.h>
#include <linux/interrupt.h>
#include <linux/i2c.h>
#include <linux/i2c-pca-platform.h>
#include <linux/i2c-algo-pca.h>
#include <linux/usb/r8a66597.h>
#include <linux/irq.h>
#include <linux/clk.h>
#include <linux/errno.h>
#include <mach/sh7785lcr.h>
#include <cpu/sh7785.h>
#include <asm/heartbeat.h>
#include <asm/clock.h>
#include <cpu/sh7785.h>

/*
* NOTE: This board has 2 physical memory maps.
Expand Down Expand Up @@ -98,18 +100,21 @@ static struct platform_device nor_flash_device = {
.resource = nor_flash_resources,
};

static struct r8a66597_platdata r8a66597_data = {
.xtal = R8A66597_PLATDATA_XTAL_12MHZ,
.vif = 1,
};

static struct resource r8a66597_usb_host_resources[] = {
[0] = {
.name = "r8a66597_hcd",
.start = R8A66597_ADDR,
.end = R8A66597_ADDR + R8A66597_SIZE - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.name = "r8a66597_hcd",
.start = 2,
.end = 2,
.flags = IORESOURCE_IRQ,
.flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW,
},
};

Expand All @@ -119,6 +124,7 @@ static struct platform_device r8a66597_usb_host_device = {
.dev = {
.dma_mask = NULL,
.coherent_dma_mask = 0xffffffff,
.platform_data = &r8a66597_data,
},
.num_resources = ARRAY_SIZE(r8a66597_usb_host_resources),
.resource = r8a66597_usb_host_resources,
Expand Down
7 changes: 7 additions & 0 deletions arch/sh/boards/board-urquell.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
* Renesas Technology Corp. SH7786 Urquell Support.
*
* Copyright (C) 2008 Kuninori Morimoto <morimoto.kuninori@renesas.com>
* Copyright (C) 2009 Paul Mundt
*
* Based on board-sh7785lcr.c
* Copyright (C) 2008 Yoshihiro Shimoda
Expand Down Expand Up @@ -178,6 +179,11 @@ static void __init urquell_init_irq(void)
plat_irq_setup_pins(IRQ_MODE_IRL3210_MASK);
}

static int urquell_mode_pins(void)
{
return __raw_readw(UBOARDREG(MDSWMR));
}

/* Initialize the board */
static void __init urquell_setup(char **cmdline_p)
{
Expand All @@ -193,4 +199,5 @@ static struct sh_machine_vector mv_urquell __initmv = {
.mv_name = "Urquell",
.mv_setup = urquell_setup,
.mv_init_irq = urquell_init_irq,
.mv_mode_pins = urquell_mode_pins,
};
64 changes: 60 additions & 4 deletions arch/sh/boards/mach-highlander/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,11 @@
#include <linux/platform_device.h>
#include <linux/ata_platform.h>
#include <linux/types.h>
#include <linux/mtd/physmap.h>
#include <linux/i2c.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
#include <linux/usb/r8a66597.h>
#include <net/ax88796.h>
#include <asm/machvec.h>
#include <mach/highlander.h>
Expand All @@ -27,18 +30,21 @@
#include <asm/io.h>
#include <asm/io_trapped.h>

static struct r8a66597_platdata r8a66597_data = {
.xtal = R8A66597_PLATDATA_XTAL_12MHZ,
.vif = 1,
};

static struct resource r8a66597_usb_host_resources[] = {
[0] = {
.name = "r8a66597_hcd",
.start = 0xA4200000,
.end = 0xA42000FF,
.flags = IORESOURCE_MEM,
},
[1] = {
.name = "r8a66597_hcd",
.start = IRQ_EXT1, /* irq number */
.end = IRQ_EXT1,
.flags = IORESOURCE_IRQ,
.flags = IORESOURCE_IRQ | IRQF_TRIGGER_LOW,
},
};

Expand All @@ -48,6 +54,7 @@ static struct platform_device r8a66597_usb_host_device = {
.dev = {
.dma_mask = NULL, /* don't use dma */
.coherent_dma_mask = 0xffffffff,
.platform_data = &r8a66597_data,
},
.num_resources = ARRAY_SIZE(r8a66597_usb_host_resources),
.resource = r8a66597_usb_host_resources,
Expand Down Expand Up @@ -178,6 +185,53 @@ static struct platform_device ax88796_device = {
.resource = ax88796_resources,
};

static struct mtd_partition nor_flash_partitions[] = {
{
.name = "loader",
.offset = 0x00000000,
.size = 512 * 1024,
},
{
.name = "bootenv",
.offset = MTDPART_OFS_APPEND,
.size = 512 * 1024,
},
{
.name = "kernel",
.offset = MTDPART_OFS_APPEND,
.size = 4 * 1024 * 1024,
},
{
.name = "data",
.offset = MTDPART_OFS_APPEND,
.size = MTDPART_SIZ_FULL,
},
};

static struct physmap_flash_data nor_flash_data = {
.width = 4,
.parts = nor_flash_partitions,
.nr_parts = ARRAY_SIZE(nor_flash_partitions),
};

/* This config is flash board for mass production. */
static struct resource nor_flash_resources[] = {
[0] = {
.start = PA_NORFLASH_ADDR,
.end = PA_NORFLASH_ADDR + PA_NORFLASH_SIZE - 1,
.flags = IORESOURCE_MEM,
}
};

static struct platform_device nor_flash_device = {
.name = "physmap-flash",
.dev = {
.platform_data = &nor_flash_data,
},
.num_resources = ARRAY_SIZE(nor_flash_resources),
.resource = nor_flash_resources,
};

static struct resource smbus_resources[] = {
[0] = {
.start = PA_SMCR,
Expand Down Expand Up @@ -209,6 +263,7 @@ static struct platform_device *r7780rp_devices[] __initdata = {
&m66592_usb_peripheral_device,
&heartbeat_device,
&smbus_device,
&nor_flash_device,
#ifndef CONFIG_SH_R7780RP
&ax88796_device,
#endif
Expand Down Expand Up @@ -247,9 +302,10 @@ device_initcall(r7780rp_devices_setup);
/*
* Platform specific clocks
*/
static void ivdr_clk_enable(struct clk *clk)
static int ivdr_clk_enable(struct clk *clk)
{
ctrl_outw(ctrl_inw(PA_IVDRCTL) | (1 << IVDR_CK_ON), PA_IVDRCTL);
return 0;
}

static void ivdr_clk_disable(struct clk *clk)
Expand Down
Loading

0 comments on commit 15fc204

Please sign in to comment.