Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 120147
b: refs/heads/master
c: 073da9c
h: refs/heads/master
i:
  120145: b6d71b6
  120143: 7877cad
v: v3
  • Loading branch information
Paul Mundt committed Dec 22, 2008
1 parent ebe3be9 commit 11e1fae
Show file tree
Hide file tree
Showing 9 changed files with 64 additions and 221 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8c197c3afb4a9026973315cc6a3c189dd8434053
refs/heads/master: 073da9c0de401e8683b6bc76c008a7e0850045d5
43 changes: 0 additions & 43 deletions trunk/arch/sh/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -701,49 +701,6 @@ config MAPLE
Dreamcast with a serial line terminal or a remote network
connection.

config CF_ENABLER
bool "Compact Flash Enabler support"
depends on SOLUTION_ENGINE
---help---
Compact Flash is a small, removable mass storage device introduced
in 1994 originally as a PCMCIA device. If you say `Y' here, you
compile in support for Compact Flash devices directly connected to
a SuperH processor. A Compact Flash FAQ is available at
<http://www.compactflash.org/faqs/faq.htm>.

If your board has "Directly Connected" CompactFlash at area 5 or 6,
you may want to enable this option. Then, you can use CF as
primary IDE drive (only tested for SanDisk).

If in doubt, select 'N'.

choice
prompt "Compact Flash Connection Area"
depends on CF_ENABLER
default CF_AREA6

config CF_AREA5
bool "Area5"
help
If your board has "Directly Connected" CompactFlash, You should
select the area where your CF is connected to.

- "Area5" if CompactFlash is connected to Area 5 (0x14000000)
- "Area6" if it is connected to Area 6 (0x18000000)

"Area6" will work for most boards.

config CF_AREA6
bool "Area6"

endchoice

config CF_BASE_ADDR
hex
depends on CF_ENABLER
default "0xb8000000" if CF_AREA6
default "0xb4000000" if CF_AREA5

source "arch/sh/drivers/pci/Kconfig"

source "drivers/pci/Kconfig"
Expand Down
4 changes: 3 additions & 1 deletion trunk/arch/sh/boards/mach-se/770x/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,9 @@
*/
#include <linux/init.h>
#include <linux/platform_device.h>
#include <asm/machvec.h>
#include <mach-se/mach/se.h>
#include <mach-se/mach/mrshpc.h>
#include <asm/machvec.h>
#include <asm/io.h>
#include <asm/smc37c93x.h>
#include <asm/heartbeat.h>
Expand Down Expand Up @@ -175,6 +176,7 @@ static struct platform_device *se_devices[] __initdata = {

static int __init se_devices_setup(void)
{
mrshpc_setup_windows();
return platform_add_devices(se_devices, ARRAY_SIZE(se_devices));
}
device_initcall(se_devices_setup);
Expand Down
7 changes: 4 additions & 3 deletions trunk/arch/sh/boards/mach-se/7721/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@
*/
#include <linux/init.h>
#include <linux/platform_device.h>
#include <asm/machvec.h>
#include <mach-se/mach/se7721.h>
#include <mach-se/mach/mrshpc.h>
#include <asm/machvec.h>
#include <asm/io.h>
#include <asm/heartbeat.h>

Expand Down Expand Up @@ -74,8 +75,8 @@ static struct platform_device *se7721_devices[] __initdata = {

static int __init se7721_devices_setup(void)
{
return platform_add_devices(se7721_devices,
ARRAY_SIZE(se7721_devices));
mrshpc_setup_windows();
return platform_add_devices(se7721_devices, ARRAY_SIZE(se7721_devices));
}
device_initcall(se7721_devices_setup);

Expand Down
7 changes: 4 additions & 3 deletions trunk/arch/sh/boards/mach-se/7722/setup.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,10 @@
#include <linux/ata_platform.h>
#include <linux/input.h>
#include <linux/smc91x.h>
#include <mach-se/mach/se7722.h>
#include <mach-se/mach/mrshpc.h>
#include <asm/machvec.h>
#include <asm/clock.h>
#include <mach-se/mach/se7722.h>
#include <asm/io.h>
#include <asm/heartbeat.h>
#include <asm/sh_keysc.h>
Expand Down Expand Up @@ -147,8 +148,8 @@ static struct platform_device *se7722_devices[] __initdata = {

static int __init se7722_devices_setup(void)
{
return platform_add_devices(se7722_devices,
ARRAY_SIZE(se7722_devices));
mrshpc_setup_windows();
return platform_add_devices(se7722_devices, ARRAY_SIZE(se7722_devices));
}
device_initcall(se7722_devices_setup);

Expand Down
52 changes: 52 additions & 0 deletions trunk/arch/sh/include/mach-se/mach/mrshpc.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
#ifndef __MACH_SE_MRSHPC_H
#define __MACH_SE_MRSHPC_H

#include <linux/io.h>

static void __init mrshpc_setup_windows(void)
{
if ((__raw_readw(MRSHPC_CSR) & 0x000c) != 0)
return; /* Not detected */

if ((__raw_readw(MRSHPC_CSR) & 0x0080) == 0) {
__raw_writew(0x0674, MRSHPC_CPWCR); /* Card Vcc is 3.3v? */
} else {
__raw_writew(0x0678, MRSHPC_CPWCR); /* Card Vcc is 5V */
}

/*
* PC-Card window open
* flag == COMMON/ATTRIBUTE/IO
*/
/* common window open */
__raw_writew(0x8a84, MRSHPC_MW0CR1);
if((__raw_readw(MRSHPC_CSR) & 0x4000) != 0)
/* common mode & bus width 16bit SWAP = 1*/
__raw_writew(0x0b00, MRSHPC_MW0CR2);
else
/* common mode & bus width 16bit SWAP = 0*/
__raw_writew(0x0300, MRSHPC_MW0CR2);

/* attribute window open */
__raw_writew(0x8a85, MRSHPC_MW1CR1);
if ((__raw_readw(MRSHPC_CSR) & 0x4000) != 0)
/* attribute mode & bus width 16bit SWAP = 1*/
__raw_writew(0x0a00, MRSHPC_MW1CR2);
else
/* attribute mode & bus width 16bit SWAP = 0*/
__raw_writew(0x0200, MRSHPC_MW1CR2);

/* I/O window open */
__raw_writew(0x8a86, MRSHPC_IOWCR1);
__raw_writew(0x0008, MRSHPC_CDCR); /* I/O card mode */
if ((__raw_readw(MRSHPC_CSR) & 0x4000) != 0)
__raw_writew(0x0a00, MRSHPC_IOWCR2); /* bus width 16bit SWAP = 1*/
else
__raw_writew(0x0200, MRSHPC_IOWCR2); /* bus width 16bit SWAP = 0*/

__raw_writew(0x2000, MRSHPC_ICR);
__raw_writeb(0x00, PA_MRSHPC_MW2 + 0x206);
__raw_writeb(0x42, PA_MRSHPC_MW2 + 0x200);
}

#endif /* __MACH_SE_MRSHPC_H */
1 change: 0 additions & 1 deletion trunk/arch/sh/kernel/Makefile_32
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ obj-y := debugtraps.o disassemble.o idle.o io.o io_generic.o irq.o \
obj-y += cpu/ timers/
obj-$(CONFIG_VSYSCALL) += vsyscall/
obj-$(CONFIG_SMP) += smp.o
obj-$(CONFIG_CF_ENABLER) += cf-enabler.o
obj-$(CONFIG_SH_STANDARD_BIOS) += sh_bios.o
obj-$(CONFIG_KGDB) += kgdb.o
obj-$(CONFIG_SH_CPU_FREQ) += cpufreq.o
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/sh/kernel/Makefile_64
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ obj-y := debugtraps.o idle.o io.o io_generic.o irq.o machvec.o process_64.o \
obj-y += cpu/ timers/
obj-$(CONFIG_VSYSCALL) += vsyscall/
obj-$(CONFIG_SMP) += smp.o
obj-$(CONFIG_CF_ENABLER) += cf-enabler.o
obj-$(CONFIG_SH_STANDARD_BIOS) += sh_bios.o
obj-$(CONFIG_SH_CPU_FREQ) += cpufreq.o
obj-$(CONFIG_MODULES) += sh_ksyms_64.o module.o
Expand Down
168 changes: 0 additions & 168 deletions trunk/arch/sh/kernel/cf-enabler.c

This file was deleted.

0 comments on commit 11e1fae

Please sign in to comment.