diff options
author | Ben Dooks <ben-linux@fluff.org> | 2008-10-30 06:14:33 -0400 |
---|---|---|
committer | Ben Dooks <ben-linux@fluff.org> | 2008-10-30 06:17:12 -0400 |
commit | 9498cb79463c9b2abb243a4b0c2ce3ac1853d5b0 (patch) | |
tree | 378e5c093997ba3d184250e20d6e507189da9722 /arch | |
parent | 180ee700ddfcc882d90410d979a4b3a804380ed2 (diff) |
[ARM] S3C: Move i2c headers to arch/arm/plat-s3c/include/plat.
Move the i2c headers to arch/arm/plat-s3c/include/plat
ready to clean out the old include directories.
Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-s3c2410/mach-bast.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-s3c2410/mach-n30.c | 2 | ||||
-rw-r--r-- | arch/arm/mach-s3c2412/mach-jive.c | 2 | ||||
-rw-r--r-- | arch/arm/plat-s3c/include/plat/iic.h | 33 | ||||
-rw-r--r-- | arch/arm/plat-s3c/include/plat/regs-iic.h | 56 |
5 files changed, 92 insertions, 3 deletions
diff --git a/arch/arm/mach-s3c2410/mach-bast.c b/arch/arm/mach-s3c2410/mach-bast.c index 8db9c700e3c2..8da05f9e7bb4 100644 --- a/arch/arm/mach-s3c2410/mach-bast.c +++ b/arch/arm/mach-s3c2410/mach-bast.c | |||
@@ -45,7 +45,7 @@ | |||
45 | #include <mach/regs-lcd.h> | 45 | #include <mach/regs-lcd.h> |
46 | 46 | ||
47 | #include <asm/plat-s3c/nand.h> | 47 | #include <asm/plat-s3c/nand.h> |
48 | #include <asm/plat-s3c/iic.h> | 48 | #include <plat/iic.h> |
49 | #include <mach/fb.h> | 49 | #include <mach/fb.h> |
50 | 50 | ||
51 | #include <linux/mtd/mtd.h> | 51 | #include <linux/mtd/mtd.h> |
diff --git a/arch/arm/mach-s3c2410/mach-n30.c b/arch/arm/mach-s3c2410/mach-n30.c index 82505517846c..836c9f639215 100644 --- a/arch/arm/mach-s3c2410/mach-n30.c +++ b/arch/arm/mach-s3c2410/mach-n30.c | |||
@@ -40,7 +40,7 @@ | |||
40 | #include <asm/mach/irq.h> | 40 | #include <asm/mach/irq.h> |
41 | #include <asm/mach/map.h> | 41 | #include <asm/mach/map.h> |
42 | 42 | ||
43 | #include <asm/plat-s3c/iic.h> | 43 | #include <plat/iic.h> |
44 | #include <plat/regs-serial.h> | 44 | #include <plat/regs-serial.h> |
45 | 45 | ||
46 | #include <plat/clock.h> | 46 | #include <plat/clock.h> |
diff --git a/arch/arm/mach-s3c2412/mach-jive.c b/arch/arm/mach-s3c2412/mach-jive.c index b08f18c8c47a..80208d37756d 100644 --- a/arch/arm/mach-s3c2412/mach-jive.c +++ b/arch/arm/mach-s3c2412/mach-jive.c | |||
@@ -32,7 +32,7 @@ | |||
32 | 32 | ||
33 | #include <plat/regs-serial.h> | 33 | #include <plat/regs-serial.h> |
34 | #include <asm/plat-s3c/nand.h> | 34 | #include <asm/plat-s3c/nand.h> |
35 | #include <asm/plat-s3c/iic.h> | 35 | #include <plat/iic.h> |
36 | 36 | ||
37 | #include <mach/regs-power.h> | 37 | #include <mach/regs-power.h> |
38 | #include <mach/regs-gpio.h> | 38 | #include <mach/regs-gpio.h> |
diff --git a/arch/arm/plat-s3c/include/plat/iic.h b/arch/arm/plat-s3c/include/plat/iic.h new file mode 100644 index 000000000000..5106acaa1d0e --- /dev/null +++ b/arch/arm/plat-s3c/include/plat/iic.h | |||
@@ -0,0 +1,33 @@ | |||
1 | /* arch/arm/mach-s3c2410/include/mach/iic.h | ||
2 | * | ||
3 | * Copyright (c) 2004 Simtec Electronics | ||
4 | * Ben Dooks <ben@simtec.co.uk> | ||
5 | * | ||
6 | * S3C2410 - I2C Controller platfrom_device info | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | */ | ||
12 | |||
13 | #ifndef __ASM_ARCH_IIC_H | ||
14 | #define __ASM_ARCH_IIC_H __FILE__ | ||
15 | |||
16 | #define S3C_IICFLG_FILTER (1<<0) /* enable s3c2440 filter */ | ||
17 | |||
18 | /* Notes: | ||
19 | * 1) All frequencies are expressed in Hz | ||
20 | * 2) A value of zero is `do not care` | ||
21 | */ | ||
22 | |||
23 | struct s3c2410_platform_i2c { | ||
24 | int bus_num; /* bus number to use */ | ||
25 | unsigned int flags; | ||
26 | unsigned int slave_addr; /* slave address for controller */ | ||
27 | unsigned long bus_freq; /* standard bus frequency */ | ||
28 | unsigned long max_freq; /* max frequency for the bus */ | ||
29 | unsigned long min_freq; /* min frequency for the bus */ | ||
30 | unsigned int sda_delay; /* pclks (s3c2440 only) */ | ||
31 | }; | ||
32 | |||
33 | #endif /* __ASM_ARCH_IIC_H */ | ||
diff --git a/arch/arm/plat-s3c/include/plat/regs-iic.h b/arch/arm/plat-s3c/include/plat/regs-iic.h new file mode 100644 index 000000000000..2f7c17de8ac8 --- /dev/null +++ b/arch/arm/plat-s3c/include/plat/regs-iic.h | |||
@@ -0,0 +1,56 @@ | |||
1 | /* arch/arm/mach-s3c2410/include/mach/regs-iic.h | ||
2 | * | ||
3 | * Copyright (c) 2004 Simtec Electronics <linux@simtec.co.uk> | ||
4 | * http://www.simtec.co.uk/products/SWLINUX/ | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | * | ||
10 | * S3C2410 I2C Controller | ||
11 | */ | ||
12 | |||
13 | #ifndef __ASM_ARCH_REGS_IIC_H | ||
14 | #define __ASM_ARCH_REGS_IIC_H __FILE__ | ||
15 | |||
16 | /* see s3c2410x user guide, v1.1, section 9 (p447) for more info */ | ||
17 | |||
18 | #define S3C2410_IICREG(x) (x) | ||
19 | |||
20 | #define S3C2410_IICCON S3C2410_IICREG(0x00) | ||
21 | #define S3C2410_IICSTAT S3C2410_IICREG(0x04) | ||
22 | #define S3C2410_IICADD S3C2410_IICREG(0x08) | ||
23 | #define S3C2410_IICDS S3C2410_IICREG(0x0C) | ||
24 | #define S3C2440_IICLC S3C2410_IICREG(0x10) | ||
25 | |||
26 | #define S3C2410_IICCON_ACKEN (1<<7) | ||
27 | #define S3C2410_IICCON_TXDIV_16 (0<<6) | ||
28 | #define S3C2410_IICCON_TXDIV_512 (1<<6) | ||
29 | #define S3C2410_IICCON_IRQEN (1<<5) | ||
30 | #define S3C2410_IICCON_IRQPEND (1<<4) | ||
31 | #define S3C2410_IICCON_SCALE(x) ((x)&15) | ||
32 | #define S3C2410_IICCON_SCALEMASK (0xf) | ||
33 | |||
34 | #define S3C2410_IICSTAT_MASTER_RX (2<<6) | ||
35 | #define S3C2410_IICSTAT_MASTER_TX (3<<6) | ||
36 | #define S3C2410_IICSTAT_SLAVE_RX (0<<6) | ||
37 | #define S3C2410_IICSTAT_SLAVE_TX (1<<6) | ||
38 | #define S3C2410_IICSTAT_MODEMASK (3<<6) | ||
39 | |||
40 | #define S3C2410_IICSTAT_START (1<<5) | ||
41 | #define S3C2410_IICSTAT_BUSBUSY (1<<5) | ||
42 | #define S3C2410_IICSTAT_TXRXEN (1<<4) | ||
43 | #define S3C2410_IICSTAT_ARBITR (1<<3) | ||
44 | #define S3C2410_IICSTAT_ASSLAVE (1<<2) | ||
45 | #define S3C2410_IICSTAT_ADDR0 (1<<1) | ||
46 | #define S3C2410_IICSTAT_LASTBIT (1<<0) | ||
47 | |||
48 | #define S3C2410_IICLC_SDA_DELAY0 (0 << 0) | ||
49 | #define S3C2410_IICLC_SDA_DELAY5 (1 << 0) | ||
50 | #define S3C2410_IICLC_SDA_DELAY10 (2 << 0) | ||
51 | #define S3C2410_IICLC_SDA_DELAY15 (3 << 0) | ||
52 | #define S3C2410_IICLC_SDA_DELAY_MASK (3 << 0) | ||
53 | |||
54 | #define S3C2410_IICLC_FILTER_ON (1<<2) | ||
55 | |||
56 | #endif /* __ASM_ARCH_REGS_IIC_H */ | ||