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:
  arch/sh/drivers/dma/dma-sh.c: Correct use of ! and &
  serial: Move asm-sh/sci.h to linux/serial_sci.h.
  sh: Fix up HAS_SR_RB typo in entry-macros.
  
  maple: fix device detection
  sh: fix rtc_resources setup for sh770x
  sh: heartbeat: ioremap is expected to succeed
  sh: Storage class should be before const qualifier
  maple: remove unused variable
  sh: SH5-103 needs to select CPU_SH5.
  sh: Rename SH-3 CCR3 reg to avoid synclink_cs clash.
  • Loading branch information
Linus Torvalds committed Feb 29, 2008
2 parents 219ff3a + b2d7c7f commit 83afdf2
Show file tree
Hide file tree
Showing 30 changed files with 101 additions and 83 deletions.
1 change: 1 addition & 0 deletions arch/sh/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -330,6 +330,7 @@ config CPU_SUBTYPE_SH5_101

config CPU_SUBTYPE_SH5_103
bool "Support SH5-103 processor"
select CPU_SH5

endchoice

Expand Down
2 changes: 1 addition & 1 deletion arch/sh/drivers/dma/dma-sh.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ static irqreturn_t dma_tei(int irq, void *dev_id)

static int sh_dmac_request_dma(struct dma_channel *chan)
{
if (unlikely(!chan->flags & DMA_TEI_CAPABLE))
if (unlikely(!(chan->flags & DMA_TEI_CAPABLE)))
return 0;

return request_irq(get_dmte_irq(chan->chan), dma_tei,
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/drivers/heartbeat.c
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ static int heartbeat_drv_probe(struct platform_device *pdev)
}

hd->base = ioremap_nocache(res->start, res->end - res->start + 1);
if (!unlikely(hd->base)) {
if (unlikely(!hd->base)) {
dev_err(&pdev->dev, "ioremap failed\n");

if (!pdev->dev.platform_data)
Expand Down
44 changes: 22 additions & 22 deletions arch/sh/drivers/pci/ops-dreamcast.c
Original file line number Diff line number Diff line change
Expand Up @@ -83,9 +83,9 @@ static int gapspci_read(struct pci_bus *bus, unsigned int devfn, int where, int
return PCIBIOS_DEVICE_NOT_FOUND;

switch (size) {
case 1: *val = ctrl_inb(GAPSPCI_BBA_CONFIG+where); break;
case 2: *val = ctrl_inw(GAPSPCI_BBA_CONFIG+where); break;
case 4: *val = ctrl_inl(GAPSPCI_BBA_CONFIG+where); break;
case 1: *val = inb(GAPSPCI_BBA_CONFIG+where); break;
case 2: *val = inw(GAPSPCI_BBA_CONFIG+where); break;
case 4: *val = inl(GAPSPCI_BBA_CONFIG+where); break;
}

return PCIBIOS_SUCCESSFUL;
Expand All @@ -97,9 +97,9 @@ static int gapspci_write(struct pci_bus *bus, unsigned int devfn, int where, int
return PCIBIOS_DEVICE_NOT_FOUND;

switch (size) {
case 1: ctrl_outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break;
case 2: ctrl_outw((u16)val, GAPSPCI_BBA_CONFIG+where); break;
case 4: ctrl_outl((u32)val, GAPSPCI_BBA_CONFIG+where); break;
case 1: outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break;
case 2: outw((u16)val, GAPSPCI_BBA_CONFIG+where); break;
case 4: outl((u32)val, GAPSPCI_BBA_CONFIG+where); break;
}

return PCIBIOS_SUCCESSFUL;
Expand Down Expand Up @@ -127,36 +127,36 @@ int __init gapspci_init(void)
*/

for (i=0; i<16; i++)
idbuf[i] = ctrl_inb(GAPSPCI_REGS+i);
idbuf[i] = inb(GAPSPCI_REGS+i);

if (strncmp(idbuf, "GAPSPCI_BRIDGE_2", 16))
return -ENODEV;

ctrl_outl(0x5a14a501, GAPSPCI_REGS+0x18);
outl(0x5a14a501, GAPSPCI_REGS+0x18);

for (i=0; i<1000000; i++)
;

if (ctrl_inl(GAPSPCI_REGS+0x18) != 1)
if (inl(GAPSPCI_REGS+0x18) != 1)
return -EINVAL;

ctrl_outl(0x01000000, GAPSPCI_REGS+0x20);
ctrl_outl(0x01000000, GAPSPCI_REGS+0x24);
outl(0x01000000, GAPSPCI_REGS+0x20);
outl(0x01000000, GAPSPCI_REGS+0x24);

ctrl_outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28);
ctrl_outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c);
outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28);
outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c);

ctrl_outl(1, GAPSPCI_REGS+0x14);
ctrl_outl(1, GAPSPCI_REGS+0x34);
outl(1, GAPSPCI_REGS+0x14);
outl(1, GAPSPCI_REGS+0x34);

/* Setting Broadband Adapter */
ctrl_outw(0xf900, GAPSPCI_BBA_CONFIG+0x06);
ctrl_outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30);
ctrl_outb(0x00, GAPSPCI_BBA_CONFIG+0x3c);
ctrl_outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d);
ctrl_outw(0x0006, GAPSPCI_BBA_CONFIG+0x04);
ctrl_outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10);
ctrl_outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14);
outw(0xf900, GAPSPCI_BBA_CONFIG+0x06);
outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30);
outb(0x00, GAPSPCI_BBA_CONFIG+0x3c);
outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d);
outw(0x0006, GAPSPCI_BBA_CONFIG+0x04);
outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10);
outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14);

return 0;
}
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh2/setup-sh7619.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

enum {
UNUSED = 0,
Expand Down
4 changes: 2 additions & 2 deletions arch/sh/kernel/cpu/sh2a/clock-sh7203.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@
#include <asm/freq.h>
#include <asm/io.h>

const static int pll1rate[]={8,12,16,0};
const static int pfc_divisors[]={1,2,3,4,6,8,12};
static const int pll1rate[]={8,12,16,0};
static const int pfc_divisors[]={1,2,3,4,6,8,12};
#define ifc_divisors pfc_divisors

#if (CONFIG_SH_CLK_MD == 0)
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh2a/setup-sh7203.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

enum {
UNUSED = 0,
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh2a/setup-sh7206.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

enum {
UNUSED = 0,
Expand Down
4 changes: 2 additions & 2 deletions arch/sh/kernel/cpu/sh3/probe.c
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,9 @@ int __uses_jump_to_uncached detect_cpu_and_cache_system(void)
boot_cpu_data.dcache.way_incr = (1 << 13);
boot_cpu_data.dcache.entry_mask = 0x1ff0;
boot_cpu_data.dcache.sets = 512;
ctrl_outl(CCR_CACHE_32KB, CCR3);
ctrl_outl(CCR_CACHE_32KB, CCR3_REG);
#else
ctrl_outl(CCR_CACHE_16KB, CCR3);
ctrl_outl(CCR_CACHE_16KB, CCR3_REG);
#endif
#endif
}
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh3/setup-sh7705.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <linux/init.h>
#include <linux/irq.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>
#include <asm/rtc.h>

enum {
Expand Down
8 changes: 4 additions & 4 deletions arch/sh/kernel/cpu/sh3/setup-sh770x.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <linux/irq.h>
#include <linux/platform_device.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

enum {
UNUSED = 0,
Expand Down Expand Up @@ -123,15 +123,15 @@ static struct resource rtc_resources[] = {
.flags = IORESOURCE_IO,
},
[1] = {
.start = 20,
.start = 21,
.flags = IORESOURCE_IRQ,
},
[2] = {
.start = 21,
.start = 22,
.flags = IORESOURCE_IRQ,
},
[3] = {
.start = 22,
.start = 20,
.flags = IORESOURCE_IRQ,
},
};
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh3/setup-sh7710.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <linux/init.h>
#include <linux/irq.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>
#include <asm/rtc.h>

enum {
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh3/setup-sh7720.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/io.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>
#include <asm/rtc.h>

#define INTC_ICR1 0xA4140010UL
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4/setup-sh4-202.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4/setup-sh7750.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/io.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct resource rtc_resources[] = {
[0] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4/setup-sh7760.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

enum {
UNUSED = 0,
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7343.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7366.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7722.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/serial_sci.h>
#include <linux/mm.h>
#include <asm/mmzone.h>
#include <asm/sci.h>

static struct resource usbf_resources[] = {
[0] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7763.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/io.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct resource rtc_resources[] = {
[0] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7770.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7780.c
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/io.h>
#include <asm/sci.h>
#include <linux/serial_sci.h>

static struct resource rtc_resources[] = {
[0] = {
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-sh7785.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/serial_sci.h>
#include <linux/io.h>
#include <linux/mm.h>
#include <asm/mmzone.h>
#include <asm/sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion arch/sh/kernel/cpu/sh4a/setup-shx3.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
#include <linux/platform_device.h>
#include <linux/init.h>
#include <linux/serial.h>
#include <linux/serial_sci.h>
#include <linux/io.h>
#include <asm/mmzone.h>
#include <asm/sci.h>

static struct plat_sci_port sci_platform_data[] = {
{
Expand Down
2 changes: 1 addition & 1 deletion drivers/serial/sh-sci.c
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
#include <linux/delay.h>
#include <linux/console.h>
#include <linux/platform_device.h>
#include <linux/serial_sci.h>

#ifdef CONFIG_CPU_FREQ
#include <linux/notifier.h>
Expand All @@ -54,7 +55,6 @@
#include <asm/kgdb.h>
#endif

#include <asm/sci.h>
#include "sh-sci.h"

struct sci_port {
Expand Down
Loading

0 comments on commit 83afdf2

Please sign in to comment.