git://git.onelab.eu
/
linux-2.6.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fedora kernel-2.6.17-1.2142_FC4 patched with stable patch-2.6.17.4-vs2.0.2-rc26.diff
[linux-2.6.git]
/
arch
/
arm
/
mach-s3c2410
/
cpu.c
diff --git
a/arch/arm/mach-s3c2410/cpu.c
b/arch/arm/mach-s3c2410/cpu.c
index
0a66065
..
70c34fc
100644
(file)
--- a/
arch/arm/mach-s3c2410/cpu.c
+++ b/
arch/arm/mach-s3c2410/cpu.c
@@
-1,7
+1,8
@@
/* linux/arch/arm/mach-s3c2410/cpu.c
*
/* linux/arch/arm/mach-s3c2410/cpu.c
*
- * Copyright (c) 2004 Simtec Electronics
- * Ben Dooks <ben@simtec.co.uk>
+ * Copyright (c) 2004-2005 Simtec Electronics
+ * http://www.simtec.co.uk/products/SWLINUX/
+ * Ben Dooks <ben@simtec.co.uk>
*
* S3C24XX CPU Support
*
*
* S3C24XX CPU Support
*
@@
-25,7
+26,7
@@
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
#include <linux/module.h>
#include <linux/interrupt.h>
#include <linux/ioport.h>
-#include <linux/device.h>
+#include <linux/
platform_
device.h>
#include <asm/hardware.h>
#include <asm/irq.h>
#include <asm/hardware.h>
#include <asm/irq.h>
@@
-39,6
+40,7
@@
#include "cpu.h"
#include "clock.h"
#include "cpu.h"
#include "clock.h"
+#include "s3c2400.h"
#include "s3c2410.h"
#include "s3c2440.h"
#include "s3c2410.h"
#include "s3c2440.h"
@@
-54,6
+56,7
@@
struct cpu_table {
/* table of supported CPUs */
/* table of supported CPUs */
+static const char name_s3c2400[] = "S3C2400";
static const char name_s3c2410[] = "S3C2410";
static const char name_s3c2440[] = "S3C2440";
static const char name_s3c2410a[] = "S3C2410A";
static const char name_s3c2410[] = "S3C2410";
static const char name_s3c2440[] = "S3C2440";
static const char name_s3c2410a[] = "S3C2410A";
@@
-95,7
+98,16
@@
static struct cpu_table cpu_ids[] __initdata = {
.init_uarts = s3c2440_init_uarts,
.init = s3c2440_init,
.name = name_s3c2440a
.init_uarts = s3c2440_init_uarts,
.init = s3c2440_init,
.name = name_s3c2440a
- }
+ },
+ {
+ .idcode = 0x0, /* S3C2400 doesn't have an idcode */
+ .idmask = 0xffffffff,
+ .map_io = s3c2400_map_io,
+ .init_clocks = s3c2400_init_clocks,
+ .init_uarts = s3c2400_init_uarts,
+ .init = s3c2400_init,
+ .name = name_s3c2400
+ },
};
/* minimal IO mapping */
};
/* minimal IO mapping */
@@
-134,7
+146,7
@@
void s3c24xx_set_board(struct s3c24xx_board *b)
board = b;
if (b->clocks_count != 0) {
board = b;
if (b->clocks_count != 0) {
- struct clk **ptr = b->clocks;
;
+ struct clk **ptr = b->clocks;
for (i = b->clocks_count; i > 0; i--, ptr++)
s3c24xx_register_clock(*ptr);
for (i = b->clocks_count; i > 0; i--, ptr++)
s3c24xx_register_clock(*ptr);
@@
-147,12
+159,15
@@
static struct cpu_table *cpu;
void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
{
void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
{
- unsigned long idcode;
+ unsigned long idcode
= 0x0
;
/* initialise the io descriptors we need for initialisation */
iotable_init(s3c_iodesc, ARRAY_SIZE(s3c_iodesc));
/* initialise the io descriptors we need for initialisation */
iotable_init(s3c_iodesc, ARRAY_SIZE(s3c_iodesc));
+#ifndef CONFIG_CPU_S3C2400
idcode = __raw_readl(S3C2410_GSTATUS1);
idcode = __raw_readl(S3C2410_GSTATUS1);
+#endif
+
cpu = s3c_lookup_cpu(idcode);
if (cpu == NULL) {
cpu = s3c_lookup_cpu(idcode);
if (cpu == NULL) {
@@
-181,8
+196,8
@@
void __init s3c24xx_init_io(struct map_desc *mach_desc, int size)
void __init s3c24xx_init_clocks(int xtal)
{
void __init s3c24xx_init_clocks(int xtal)
{
- if (xtal
!
= 0)
-
s3c24xx_xtal = xtal
;
+ if (xtal
=
= 0)
+
xtal = 12*1000*1000
;
if (cpu == NULL)
panic("s3c24xx_init_clocks: no cpu setup?\n");
if (cpu == NULL)
panic("s3c24xx_init_clocks: no cpu setup?\n");