Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 100696
b: refs/heads/master
c: 66ee156
h: refs/heads/master
v: v3
  • Loading branch information
Russell King authored and Russell King committed Jul 7, 2008
1 parent 49e58b6 commit e9e3a4c
Show file tree
Hide file tree
Showing 14 changed files with 46 additions and 172 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: 4ed47896935573c8423d05bddda3f269d6e6c613
refs/heads/master: 66ee156078697cdc013d46aed3b2fee445c325a1
9 changes: 1 addition & 8 deletions trunk/arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -232,13 +232,6 @@ config ARCH_CLPS711X
help
Support for Cirrus Logic 711x/721x based boards.

config ARCH_CO285
bool "Co-EBSA285"
select FOOTBRIDGE
select FOOTBRIDGE_ADDIN
help
Support for Intel's EBSA285 companion chip.

config ARCH_EBSA110
bool "EBSA-110"
select ISA
Expand Down Expand Up @@ -789,7 +782,7 @@ source "mm/Kconfig"

config LEDS
bool "Timer and CPU usage LEDs"
depends on ARCH_CDB89712 || ARCH_CO285 || ARCH_EBSA110 || \
depends on ARCH_CDB89712 || ARCH_EBSA110 || \
ARCH_EBSA285 || ARCH_IMX || ARCH_INTEGRATOR || \
ARCH_LUBBOCK || MACH_MAINSTONE || ARCH_NETWINDER || \
ARCH_OMAP || ARCH_P720T || ARCH_PXA_IDP || \
Expand Down
2 changes: 0 additions & 2 deletions trunk/arch/arm/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,6 @@ textofs-y := 0x00008000
incdir-$(CONFIG_ARCH_CLPS7500) := cl7500
machine-$(CONFIG_FOOTBRIDGE) := footbridge
incdir-$(CONFIG_FOOTBRIDGE) := ebsa285
machine-$(CONFIG_ARCH_CO285) := footbridge
incdir-$(CONFIG_ARCH_CO285) := ebsa285
machine-$(CONFIG_ARCH_SHARK) := shark
machine-$(CONFIG_ARCH_SA1100) := sa1100
ifeq ($(CONFIG_ARCH_SA1100),y)
Expand Down
83 changes: 40 additions & 43 deletions trunk/arch/arm/kernel/atags.c
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
#include <linux/slab.h>
#include <linux/kexec.h>
#include <linux/proc_fs.h>
#include <asm/setup.h>
#include <asm/types.h>
#include <asm/page.h>

struct buffer {
size_t size;
char *data;
char data[];
};
static struct buffer tags_buffer;

static int
read_buffer(char* page, char** start, off_t off, int count,
Expand All @@ -29,58 +27,57 @@ read_buffer(char* page, char** start, off_t off, int count,
return count;
}


static int
create_proc_entries(void)
{
struct proc_dir_entry* tags_entry;

tags_entry = create_proc_read_entry("atags", 0400, NULL, read_buffer, &tags_buffer);
if (!tags_entry)
return -ENOMEM;

return 0;
}


static char __initdata atags_copy_buf[KEXEC_BOOT_PARAMS_SIZE];
static char __initdata *atags_copy;
#define BOOT_PARAMS_SIZE 1536
static char __initdata atags_copy[BOOT_PARAMS_SIZE];

void __init save_atags(const struct tag *tags)
{
atags_copy = atags_copy_buf;
memcpy(atags_copy, tags, KEXEC_BOOT_PARAMS_SIZE);
memcpy(atags_copy, tags, sizeof(atags_copy));
}


static int __init init_atags_procfs(void)
{
struct tag *tag;
int error;
/*
* This cannot go into save_atags() because kmalloc and proc don't work
* yet when it is called.
*/
struct proc_dir_entry *tags_entry;
struct tag *tag = (struct tag *)atags_copy;
struct buffer *b;
size_t size;

if (!atags_copy) {
printk(KERN_WARNING "Exporting ATAGs: No saved tags found\n");
return -EIO;
if (tag->hdr.tag != ATAG_CORE) {
printk(KERN_INFO "No ATAGs?");
return -EINVAL;
}

for (tag = (struct tag *) atags_copy; tag->hdr.size; tag = tag_next(tag))
for (; tag->hdr.size; tag = tag_next(tag))
;

tags_buffer.size = ((char *) tag - atags_copy) + sizeof(tag->hdr);
tags_buffer.data = kmalloc(tags_buffer.size, GFP_KERNEL);
if (tags_buffer.data == NULL)
return -ENOMEM;
memcpy(tags_buffer.data, atags_copy, tags_buffer.size);

error = create_proc_entries();
if (error) {
printk(KERN_ERR "Exporting ATAGs: not enough memory\n");
kfree(tags_buffer.data);
tags_buffer.size = 0;
tags_buffer.data = NULL;
}
/* include the terminating ATAG_NONE */
size = (char *)tag - atags_copy + sizeof(struct tag_header);

return error;
}
WARN_ON(tag->hdr.tag != ATAG_NONE);

b = kmalloc(sizeof(*b) + size, GFP_KERNEL);
if (!b)
goto nomem;

b->size = size;
memcpy(b->data, atags_copy, size);

tags_entry = create_proc_read_entry("atags", 0400,
NULL, read_buffer, b);

if (!tags_entry)
goto nomem;

return 0;

nomem:
kfree(b);
printk(KERN_ERR "Exporting ATAGs: not enough memory\n");

return -ENOMEM;
}
arch_initcall(init_atags_procfs);
2 changes: 0 additions & 2 deletions trunk/arch/arm/mach-footbridge/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,10 @@ pci-$(CONFIG_ARCH_EBSA285_HOST) += ebsa285-pci.o
pci-$(CONFIG_ARCH_NETWINDER) += netwinder-pci.o
pci-$(CONFIG_ARCH_PERSONAL_SERVER) += personal-pci.o

leds-$(CONFIG_ARCH_CO285) += ebsa285-leds.o
leds-$(CONFIG_ARCH_EBSA285) += ebsa285-leds.o
leds-$(CONFIG_ARCH_NETWINDER) += netwinder-leds.o

obj-$(CONFIG_ARCH_CATS) += cats-hw.o isa-timer.o
obj-$(CONFIG_ARCH_CO285) += co285.o dc21285-timer.o
obj-$(CONFIG_ARCH_EBSA285) += ebsa285.o dc21285-timer.o
obj-$(CONFIG_ARCH_NETWINDER) += netwinder-hw.o isa-timer.o
obj-$(CONFIG_ARCH_PERSONAL_SERVER) += personal.o dc21285-timer.o
Expand Down
39 changes: 0 additions & 39 deletions trunk/arch/arm/mach-footbridge/co285.c

This file was deleted.

21 changes: 0 additions & 21 deletions trunk/arch/arm/mach-footbridge/common.c
Original file line number Diff line number Diff line change
Expand Up @@ -177,25 +177,6 @@ static struct map_desc ebsa285_host_io_desc[] __initdata = {
#endif
};

/*
* The CO-ebsa285 mapping.
*/
static struct map_desc co285_io_desc[] __initdata = {
#ifdef CONFIG_ARCH_CO285
{
.virtual = PCIO_BASE,
.pfn = __phys_to_pfn(DC21285_PCI_IO),
.length = PCIO_SIZE,
.type = MT_DEVICE,
}, {
.virtual = PCIMEM_BASE,
.pfn = __phys_to_pfn(DC21285_PCI_MEM),
.length = PCIMEM_SIZE,
.type = MT_DEVICE,
},
#endif
};

void __init footbridge_map_io(void)
{
/*
Expand All @@ -208,8 +189,6 @@ void __init footbridge_map_io(void)
* Now, work out what we've got to map in addition on this
* platform.
*/
if (machine_is_co285())
iotable_init(co285_io_desc, ARRAY_SIZE(co285_io_desc));
if (footbridge_cfn_mode())
iotable_init(ebsa285_host_io_desc, ARRAY_SIZE(ebsa285_host_io_desc));
}
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/arm/mach-footbridge/ebsa285-leds.c
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ static void ebsa285_leds_event(led_event_t evt)

static int __init leds_init(void)
{
if (machine_is_ebsa285() || machine_is_co285())
if (machine_is_ebsa285())
leds_event = ebsa285_leds_event;

leds_event(led_start);
Expand Down
3 changes: 1 addition & 2 deletions trunk/arch/arm/mach-footbridge/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ static int set_isa_cmos_time(void)

void __init isa_rtc_init(void)
{
if (machine_is_co285() ||
machine_is_personal_server())
if (machine_is_personal_server())
/*
* Add-in 21285s shouldn't access the RTC
*/
Expand Down
26 changes: 0 additions & 26 deletions trunk/include/asm-arm/arch-ebsa285/hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

#include <asm/arch/memory.h>

#ifdef CONFIG_ARCH_FOOTBRIDGE
/* Virtual Physical Size
* 0xff800000 0x40000000 1MB X-Bus
* 0xff000000 0x7c000000 1MB PCI I/O space
Expand Down Expand Up @@ -50,31 +49,6 @@
#define PCIMEM_SIZE 0x01000000
#define PCIMEM_BASE 0xf0000000

#elif defined(CONFIG_ARCH_CO285)
/*
* This is the COEBSA285 cut-down mapping
*/
#define PCIMEM_SIZE 0x80000000
#define PCIMEM_BASE 0x80000000

#define WFLUSH_SIZE 0x01000000
#define WFLUSH_BASE 0x7d000000

#define ARMCSR_SIZE 0x00100000
#define ARMCSR_BASE 0x7cf00000

#define XBUS_SIZE 0x00020000
#define XBUS_BASE 0x7cee0000

#define PCIO_SIZE 0x00010000
#define PCIO_BASE 0x7ced0000

#else

#error "Undefined footbridge architecture"

#endif

#define XBUS_LEDS ((volatile unsigned char *)(XBUS_BASE + 0x12000))
#define XBUS_LED_AMBER (1 << 0)
#define XBUS_LED_GREEN (1 << 1)
Expand Down
19 changes: 0 additions & 19 deletions trunk/include/asm-arm/arch-ebsa285/memory.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,6 @@ extern unsigned long __bus_to_virt(unsigned long);

#endif

#if defined(CONFIG_ARCH_FOOTBRIDGE)

/* Task size and page offset at 3GB */
#define TASK_SIZE UL(0xbf000000)
#define PAGE_OFFSET UL(0xc0000000)
Expand All @@ -53,23 +51,6 @@ extern unsigned long __bus_to_virt(unsigned long);
*/
#define FLUSH_BASE 0xf9000000

#elif defined(CONFIG_ARCH_CO285)

/* Task size and page offset at 1.5GB */
#define TASK_SIZE UL(0x5f000000)
#define PAGE_OFFSET UL(0x60000000)

/*
* Cache flushing area.
*/
#define FLUSH_BASE 0x7e000000

#else

#error "Undefined footbridge architecture"

#endif

/*
* Physical DRAM offset.
*/
Expand Down
4 changes: 0 additions & 4 deletions trunk/include/asm-arm/arch-ebsa285/vmalloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,4 @@
*/


#ifdef CONFIG_ARCH_FOOTBRIDGE
#define VMALLOC_END (PAGE_OFFSET + 0x30000000)
#else
#define VMALLOC_END (PAGE_OFFSET + 0x20000000)
#endif
4 changes: 2 additions & 2 deletions trunk/include/asm-arm/arch-ns9xxx/hardware.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,13 @@
__REGGET(var, reg ## _ ## field) / __REGSHIFT(reg ## _ ## field)

# define REGGETIM_IDX(var, reg, field, idx) \
__REGGET(var, reg ## _ ## field((idx))) / \
__REGGET(var, reg ## _ ## field((idx))) / \
__REGSHIFT(reg ## _ ## field((idx)))

#else

# define __REG(x) io_p2v(x)
# define __REG2(x, y) io_p2v((x) + (y))
# define __REG2(x, y) io_p2v((x) + 4 * (y))

#endif

Expand Down
2 changes: 0 additions & 2 deletions trunk/include/asm-arm/kexec.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@

#define KEXEC_ARCH KEXEC_ARCH_ARM

#define KEXEC_BOOT_PARAMS_SIZE 1536

#define KEXEC_ARM_ATAGS_OFFSET 0x1000
#define KEXEC_ARM_ZIMAGE_OFFSET 0x8000

Expand Down

0 comments on commit e9e3a4c

Please sign in to comment.