diff options
author | Arnd Bergmann <arnd@arndb.de> | 2013-04-19 08:34:05 -0400 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2013-04-19 10:50:56 -0400 |
commit | 0dc488e778069b208d09516c5f0793dc37023c8e (patch) | |
tree | 704ad7fa4d8202f1933297e4dd348128a2b9f702 /drivers | |
parent | c4c54da24b8ae12abb2034edaf08021894caf0d0 (diff) | |
parent | bd51de53e1be9896d815bbea30560262216d4616 (diff) |
Merge branch 'samsung/exynos-multiplatform' into next/drivers
Merging this into the next/drivers branch avoids a number of
pointless conflicts with code changed here.
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpio/Makefile | 2 | ||||
-rw-r--r-- | drivers/mmc/host/Kconfig | 2 | ||||
-rw-r--r-- | drivers/mmc/host/sdhci-s3c-regs.h | 87 | ||||
-rw-r--r-- | drivers/mmc/host/sdhci-s3c.c | 5 | ||||
-rw-r--r-- | drivers/mtd/onenand/samsung.c | 4 | ||||
-rw-r--r-- | drivers/mtd/onenand/samsung.h | 61 | ||||
-rw-r--r-- | drivers/rtc/rtc-s3c.c | 3 | ||||
-rw-r--r-- | drivers/rtc/rtc-s3c.h | 70 | ||||
-rw-r--r-- | drivers/thermal/exynos_thermal.c | 2 |
9 files changed, 225 insertions, 11 deletions
diff --git a/drivers/gpio/Makefile b/drivers/gpio/Makefile index a274d7df3c8c..7b6f8105d352 100644 --- a/drivers/gpio/Makefile +++ b/drivers/gpio/Makefile | |||
@@ -57,7 +57,7 @@ obj-$(CONFIG_GPIO_PL061) += gpio-pl061.o | |||
57 | obj-$(CONFIG_GPIO_PXA) += gpio-pxa.o | 57 | obj-$(CONFIG_GPIO_PXA) += gpio-pxa.o |
58 | obj-$(CONFIG_GPIO_RC5T583) += gpio-rc5t583.o | 58 | obj-$(CONFIG_GPIO_RC5T583) += gpio-rc5t583.o |
59 | obj-$(CONFIG_GPIO_RDC321X) += gpio-rdc321x.o | 59 | obj-$(CONFIG_GPIO_RDC321X) += gpio-rdc321x.o |
60 | obj-$(CONFIG_PLAT_SAMSUNG) += gpio-samsung.o | 60 | obj-$(CONFIG_PLAT_SAMSUNG_SINGLE) += gpio-samsung.o |
61 | obj-$(CONFIG_ARCH_SA1100) += gpio-sa1100.o | 61 | obj-$(CONFIG_ARCH_SA1100) += gpio-sa1100.o |
62 | obj-$(CONFIG_GPIO_SCH) += gpio-sch.o | 62 | obj-$(CONFIG_GPIO_SCH) += gpio-sch.o |
63 | obj-$(CONFIG_GPIO_SODAVILLE) += gpio-sodaville.o | 63 | obj-$(CONFIG_GPIO_SODAVILLE) += gpio-sodaville.o |
diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig index d88219e1d86e..d0547448606d 100644 --- a/drivers/mmc/host/Kconfig +++ b/drivers/mmc/host/Kconfig | |||
@@ -180,7 +180,7 @@ config MMC_SDHCI_TEGRA | |||
180 | 180 | ||
181 | config MMC_SDHCI_S3C | 181 | config MMC_SDHCI_S3C |
182 | tristate "SDHCI support on Samsung S3C SoC" | 182 | tristate "SDHCI support on Samsung S3C SoC" |
183 | depends on MMC_SDHCI && PLAT_SAMSUNG | 183 | depends on MMC_SDHCI && PLAT_SAMSUNG_SINGLE |
184 | help | 184 | help |
185 | This selects the Secure Digital Host Controller Interface (SDHCI) | 185 | This selects the Secure Digital Host Controller Interface (SDHCI) |
186 | often referrered to as the HSMMC block in some of the Samsung S3C | 186 | often referrered to as the HSMMC block in some of the Samsung S3C |
diff --git a/drivers/mmc/host/sdhci-s3c-regs.h b/drivers/mmc/host/sdhci-s3c-regs.h new file mode 100644 index 000000000000..e34049ad44cc --- /dev/null +++ b/drivers/mmc/host/sdhci-s3c-regs.h | |||
@@ -0,0 +1,87 @@ | |||
1 | /* linux/arch/arm/plat-s3c/include/plat/regs-sdhci.h | ||
2 | * | ||
3 | * Copyright 2008 Openmoko, Inc. | ||
4 | * Copyright 2008 Simtec Electronics | ||
5 | * http://armlinux.simtec.co.uk/ | ||
6 | * Ben Dooks <ben@simtec.co.uk> | ||
7 | * | ||
8 | * S3C Platform - SDHCI (HSMMC) register definitions | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License version 2 as | ||
12 | * published by the Free Software Foundation. | ||
13 | */ | ||
14 | |||
15 | #ifndef __PLAT_S3C_SDHCI_REGS_H | ||
16 | #define __PLAT_S3C_SDHCI_REGS_H __FILE__ | ||
17 | |||
18 | #define S3C_SDHCI_CONTROL2 (0x80) | ||
19 | #define S3C_SDHCI_CONTROL3 (0x84) | ||
20 | #define S3C64XX_SDHCI_CONTROL4 (0x8C) | ||
21 | |||
22 | #define S3C64XX_SDHCI_CTRL2_ENSTAASYNCCLR (1 << 31) | ||
23 | #define S3C64XX_SDHCI_CTRL2_ENCMDCNFMSK (1 << 30) | ||
24 | #define S3C_SDHCI_CTRL2_CDINVRXD3 (1 << 29) | ||
25 | #define S3C_SDHCI_CTRL2_SLCARDOUT (1 << 28) | ||
26 | |||
27 | #define S3C_SDHCI_CTRL2_FLTCLKSEL_MASK (0xf << 24) | ||
28 | #define S3C_SDHCI_CTRL2_FLTCLKSEL_SHIFT (24) | ||
29 | #define S3C_SDHCI_CTRL2_FLTCLKSEL(_x) ((_x) << 24) | ||
30 | |||
31 | #define S3C_SDHCI_CTRL2_LVLDAT_MASK (0xff << 16) | ||
32 | #define S3C_SDHCI_CTRL2_LVLDAT_SHIFT (16) | ||
33 | #define S3C_SDHCI_CTRL2_LVLDAT(_x) ((_x) << 16) | ||
34 | |||
35 | #define S3C_SDHCI_CTRL2_ENFBCLKTX (1 << 15) | ||
36 | #define S3C_SDHCI_CTRL2_ENFBCLKRX (1 << 14) | ||
37 | #define S3C_SDHCI_CTRL2_SDCDSEL (1 << 13) | ||
38 | #define S3C_SDHCI_CTRL2_SDSIGPC (1 << 12) | ||
39 | #define S3C_SDHCI_CTRL2_ENBUSYCHKTXSTART (1 << 11) | ||
40 | |||
41 | #define S3C_SDHCI_CTRL2_DFCNT_MASK (0x3 << 9) | ||
42 | #define S3C_SDHCI_CTRL2_DFCNT_SHIFT (9) | ||
43 | #define S3C_SDHCI_CTRL2_DFCNT_NONE (0x0 << 9) | ||
44 | #define S3C_SDHCI_CTRL2_DFCNT_4SDCLK (0x1 << 9) | ||
45 | #define S3C_SDHCI_CTRL2_DFCNT_16SDCLK (0x2 << 9) | ||
46 | #define S3C_SDHCI_CTRL2_DFCNT_64SDCLK (0x3 << 9) | ||
47 | |||
48 | #define S3C_SDHCI_CTRL2_ENCLKOUTHOLD (1 << 8) | ||
49 | #define S3C_SDHCI_CTRL2_RWAITMODE (1 << 7) | ||
50 | #define S3C_SDHCI_CTRL2_DISBUFRD (1 << 6) | ||
51 | #define S3C_SDHCI_CTRL2_SELBASECLK_MASK (0x3 << 4) | ||
52 | #define S3C_SDHCI_CTRL2_SELBASECLK_SHIFT (4) | ||
53 | #define S3C_SDHCI_CTRL2_PWRSYNC (1 << 3) | ||
54 | #define S3C_SDHCI_CTRL2_ENCLKOUTMSKCON (1 << 1) | ||
55 | #define S3C_SDHCI_CTRL2_HWINITFIN (1 << 0) | ||
56 | |||
57 | #define S3C_SDHCI_CTRL3_FCSEL3 (1 << 31) | ||
58 | #define S3C_SDHCI_CTRL3_FCSEL2 (1 << 23) | ||
59 | #define S3C_SDHCI_CTRL3_FCSEL1 (1 << 15) | ||
60 | #define S3C_SDHCI_CTRL3_FCSEL0 (1 << 7) | ||
61 | |||
62 | #define S3C_SDHCI_CTRL3_FIA3_MASK (0x7f << 24) | ||
63 | #define S3C_SDHCI_CTRL3_FIA3_SHIFT (24) | ||
64 | #define S3C_SDHCI_CTRL3_FIA3(_x) ((_x) << 24) | ||
65 | |||
66 | #define S3C_SDHCI_CTRL3_FIA2_MASK (0x7f << 16) | ||
67 | #define S3C_SDHCI_CTRL3_FIA2_SHIFT (16) | ||
68 | #define S3C_SDHCI_CTRL3_FIA2(_x) ((_x) << 16) | ||
69 | |||
70 | #define S3C_SDHCI_CTRL3_FIA1_MASK (0x7f << 8) | ||
71 | #define S3C_SDHCI_CTRL3_FIA1_SHIFT (8) | ||
72 | #define S3C_SDHCI_CTRL3_FIA1(_x) ((_x) << 8) | ||
73 | |||
74 | #define S3C_SDHCI_CTRL3_FIA0_MASK (0x7f << 0) | ||
75 | #define S3C_SDHCI_CTRL3_FIA0_SHIFT (0) | ||
76 | #define S3C_SDHCI_CTRL3_FIA0(_x) ((_x) << 0) | ||
77 | |||
78 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_MASK (0x3 << 16) | ||
79 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_SHIFT (16) | ||
80 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_2mA (0x0 << 16) | ||
81 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_4mA (0x1 << 16) | ||
82 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_7mA (0x2 << 16) | ||
83 | #define S3C64XX_SDHCI_CONTROL4_DRIVE_9mA (0x3 << 16) | ||
84 | |||
85 | #define S3C64XX_SDHCI_CONTROL4_BUSY (1) | ||
86 | |||
87 | #endif /* __PLAT_S3C_SDHCI_REGS_H */ | ||
diff --git a/drivers/mmc/host/sdhci-s3c.c b/drivers/mmc/host/sdhci-s3c.c index 7363efe72287..e4f52b5c2592 100644 --- a/drivers/mmc/host/sdhci-s3c.c +++ b/drivers/mmc/host/sdhci-s3c.c | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/delay.h> | 15 | #include <linux/delay.h> |
16 | #include <linux/dma-mapping.h> | 16 | #include <linux/dma-mapping.h> |
17 | #include <linux/platform_device.h> | 17 | #include <linux/platform_device.h> |
18 | #include <linux/platform_data/mmc-sdhci-s3c.h> | ||
18 | #include <linux/slab.h> | 19 | #include <linux/slab.h> |
19 | #include <linux/clk.h> | 20 | #include <linux/clk.h> |
20 | #include <linux/io.h> | 21 | #include <linux/io.h> |
@@ -28,9 +29,7 @@ | |||
28 | 29 | ||
29 | #include <linux/mmc/host.h> | 30 | #include <linux/mmc/host.h> |
30 | 31 | ||
31 | #include <plat/sdhci.h> | 32 | #include "sdhci-s3c-regs.h" |
32 | #include <plat/regs-sdhci.h> | ||
33 | |||
34 | #include "sdhci.h" | 33 | #include "sdhci.h" |
35 | 34 | ||
36 | #define MAX_BUS_CLK (4) | 35 | #define MAX_BUS_CLK (4) |
diff --git a/drivers/mtd/onenand/samsung.c b/drivers/mtd/onenand/samsung.c index 33f2a8fb8df9..2cf74085f935 100644 --- a/drivers/mtd/onenand/samsung.c +++ b/drivers/mtd/onenand/samsung.c | |||
@@ -23,11 +23,11 @@ | |||
23 | #include <linux/mtd/partitions.h> | 23 | #include <linux/mtd/partitions.h> |
24 | #include <linux/dma-mapping.h> | 24 | #include <linux/dma-mapping.h> |
25 | #include <linux/interrupt.h> | 25 | #include <linux/interrupt.h> |
26 | #include <linux/io.h> | ||
26 | 27 | ||
27 | #include <asm/mach/flash.h> | 28 | #include <asm/mach/flash.h> |
28 | #include <plat/regs-onenand.h> | ||
29 | 29 | ||
30 | #include <linux/io.h> | 30 | #include "samsung.h" |
31 | 31 | ||
32 | enum soc_type { | 32 | enum soc_type { |
33 | TYPE_S3C6400, | 33 | TYPE_S3C6400, |
diff --git a/drivers/mtd/onenand/samsung.h b/drivers/mtd/onenand/samsung.h new file mode 100644 index 000000000000..c4a80e67e438 --- /dev/null +++ b/drivers/mtd/onenand/samsung.h | |||
@@ -0,0 +1,61 @@ | |||
1 | /* | ||
2 | * linux/arch/arm/plat-s3c/include/plat/regs-onenand.h | ||
3 | * | ||
4 | * Copyright (C) 2008-2010 Samsung Electronics | ||
5 | * Kyungmin Park <kyungmin.park@samsung.com> | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License version 2 as | ||
9 | * published by the Free Software Foundation. | ||
10 | */ | ||
11 | #ifndef __SAMSUNG_ONENAND_H__ | ||
12 | #define __SAMSUNG_ONENAND_H__ | ||
13 | |||
14 | /* | ||
15 | * OneNAND Controller | ||
16 | */ | ||
17 | #define MEM_CFG_OFFSET 0x0000 | ||
18 | #define BURST_LEN_OFFSET 0x0010 | ||
19 | #define MEM_RESET_OFFSET 0x0020 | ||
20 | #define INT_ERR_STAT_OFFSET 0x0030 | ||
21 | #define INT_ERR_MASK_OFFSET 0x0040 | ||
22 | #define INT_ERR_ACK_OFFSET 0x0050 | ||
23 | #define ECC_ERR_STAT_OFFSET 0x0060 | ||
24 | #define MANUFACT_ID_OFFSET 0x0070 | ||
25 | #define DEVICE_ID_OFFSET 0x0080 | ||
26 | #define DATA_BUF_SIZE_OFFSET 0x0090 | ||
27 | #define BOOT_BUF_SIZE_OFFSET 0x00A0 | ||
28 | #define BUF_AMOUNT_OFFSET 0x00B0 | ||
29 | #define TECH_OFFSET 0x00C0 | ||
30 | #define FBA_WIDTH_OFFSET 0x00D0 | ||
31 | #define FPA_WIDTH_OFFSET 0x00E0 | ||
32 | #define FSA_WIDTH_OFFSET 0x00F0 | ||
33 | #define TRANS_SPARE_OFFSET 0x0140 | ||
34 | #define DBS_DFS_WIDTH_OFFSET 0x0160 | ||
35 | #define INT_PIN_ENABLE_OFFSET 0x01A0 | ||
36 | #define ACC_CLOCK_OFFSET 0x01C0 | ||
37 | #define FLASH_VER_ID_OFFSET 0x01F0 | ||
38 | #define FLASH_AUX_CNTRL_OFFSET 0x0300 /* s3c64xx only */ | ||
39 | |||
40 | #define ONENAND_MEM_RESET_HOT 0x3 | ||
41 | #define ONENAND_MEM_RESET_COLD 0x2 | ||
42 | #define ONENAND_MEM_RESET_WARM 0x1 | ||
43 | |||
44 | #define CACHE_OP_ERR (1 << 13) | ||
45 | #define RST_CMP (1 << 12) | ||
46 | #define RDY_ACT (1 << 11) | ||
47 | #define INT_ACT (1 << 10) | ||
48 | #define UNSUP_CMD (1 << 9) | ||
49 | #define LOCKED_BLK (1 << 8) | ||
50 | #define BLK_RW_CMP (1 << 7) | ||
51 | #define ERS_CMP (1 << 6) | ||
52 | #define PGM_CMP (1 << 5) | ||
53 | #define LOAD_CMP (1 << 4) | ||
54 | #define ERS_FAIL (1 << 3) | ||
55 | #define PGM_FAIL (1 << 2) | ||
56 | #define INT_TO (1 << 1) | ||
57 | #define LD_FAIL_ECC_ERR (1 << 0) | ||
58 | |||
59 | #define TSRF (1 << 0) | ||
60 | |||
61 | #endif | ||
diff --git a/drivers/rtc/rtc-s3c.c b/drivers/rtc/rtc-s3c.c index fb994e9ddc15..7995f79d07e1 100644 --- a/drivers/rtc/rtc-s3c.c +++ b/drivers/rtc/rtc-s3c.c | |||
@@ -29,9 +29,8 @@ | |||
29 | #include <linux/uaccess.h> | 29 | #include <linux/uaccess.h> |
30 | #include <linux/io.h> | 30 | #include <linux/io.h> |
31 | 31 | ||
32 | #include <mach/hardware.h> | ||
33 | #include <asm/irq.h> | 32 | #include <asm/irq.h> |
34 | #include <plat/regs-rtc.h> | 33 | #include "rtc-s3c.h" |
35 | 34 | ||
36 | enum s3c_cpu_type { | 35 | enum s3c_cpu_type { |
37 | TYPE_S3C2410, | 36 | TYPE_S3C2410, |
diff --git a/drivers/rtc/rtc-s3c.h b/drivers/rtc/rtc-s3c.h new file mode 100644 index 000000000000..004b61a8343f --- /dev/null +++ b/drivers/rtc/rtc-s3c.h | |||
@@ -0,0 +1,70 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2003 Simtec Electronics <linux@simtec.co.uk> | ||
3 | * http://www.simtec.co.uk/products/SWLINUX/ | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or modify | ||
6 | * it under the terms of the GNU General Public License version 2 as | ||
7 | * published by the Free Software Foundation. | ||
8 | * | ||
9 | * S3C2410 Internal RTC register definition | ||
10 | */ | ||
11 | |||
12 | #ifndef __ASM_ARCH_REGS_RTC_H | ||
13 | #define __ASM_ARCH_REGS_RTC_H __FILE__ | ||
14 | |||
15 | #define S3C2410_RTCREG(x) (x) | ||
16 | #define S3C2410_INTP S3C2410_RTCREG(0x30) | ||
17 | #define S3C2410_INTP_ALM (1 << 1) | ||
18 | #define S3C2410_INTP_TIC (1 << 0) | ||
19 | |||
20 | #define S3C2410_RTCCON S3C2410_RTCREG(0x40) | ||
21 | #define S3C2410_RTCCON_RTCEN (1 << 0) | ||
22 | #define S3C2410_RTCCON_CNTSEL (1 << 2) | ||
23 | #define S3C2410_RTCCON_CLKRST (1 << 3) | ||
24 | #define S3C2443_RTCCON_TICSEL (1 << 4) | ||
25 | #define S3C64XX_RTCCON_TICEN (1 << 8) | ||
26 | |||
27 | #define S3C2410_TICNT S3C2410_RTCREG(0x44) | ||
28 | #define S3C2410_TICNT_ENABLE (1 << 7) | ||
29 | |||
30 | /* S3C2443: tick count is 15 bit wide | ||
31 | * TICNT[6:0] contains upper 7 bits | ||
32 | * TICNT1[7:0] contains lower 8 bits | ||
33 | */ | ||
34 | #define S3C2443_TICNT_PART(x) ((x & 0x7f00) >> 8) | ||
35 | #define S3C2443_TICNT1 S3C2410_RTCREG(0x4C) | ||
36 | #define S3C2443_TICNT1_PART(x) (x & 0xff) | ||
37 | |||
38 | /* S3C2416: tick count is 32 bit wide | ||
39 | * TICNT[6:0] contains bits [14:8] | ||
40 | * TICNT1[7:0] contains lower 8 bits | ||
41 | * TICNT2[16:0] contains upper 17 bits | ||
42 | */ | ||
43 | #define S3C2416_TICNT2 S3C2410_RTCREG(0x48) | ||
44 | #define S3C2416_TICNT2_PART(x) ((x & 0xffff8000) >> 15) | ||
45 | |||
46 | #define S3C2410_RTCALM S3C2410_RTCREG(0x50) | ||
47 | #define S3C2410_RTCALM_ALMEN (1 << 6) | ||
48 | #define S3C2410_RTCALM_YEAREN (1 << 5) | ||
49 | #define S3C2410_RTCALM_MONEN (1 << 4) | ||
50 | #define S3C2410_RTCALM_DAYEN (1 << 3) | ||
51 | #define S3C2410_RTCALM_HOUREN (1 << 2) | ||
52 | #define S3C2410_RTCALM_MINEN (1 << 1) | ||
53 | #define S3C2410_RTCALM_SECEN (1 << 0) | ||
54 | |||
55 | #define S3C2410_ALMSEC S3C2410_RTCREG(0x54) | ||
56 | #define S3C2410_ALMMIN S3C2410_RTCREG(0x58) | ||
57 | #define S3C2410_ALMHOUR S3C2410_RTCREG(0x5c) | ||
58 | |||
59 | #define S3C2410_ALMDATE S3C2410_RTCREG(0x60) | ||
60 | #define S3C2410_ALMMON S3C2410_RTCREG(0x64) | ||
61 | #define S3C2410_ALMYEAR S3C2410_RTCREG(0x68) | ||
62 | |||
63 | #define S3C2410_RTCSEC S3C2410_RTCREG(0x70) | ||
64 | #define S3C2410_RTCMIN S3C2410_RTCREG(0x74) | ||
65 | #define S3C2410_RTCHOUR S3C2410_RTCREG(0x78) | ||
66 | #define S3C2410_RTCDATE S3C2410_RTCREG(0x7c) | ||
67 | #define S3C2410_RTCMON S3C2410_RTCREG(0x84) | ||
68 | #define S3C2410_RTCYEAR S3C2410_RTCREG(0x88) | ||
69 | |||
70 | #endif /* __ASM_ARCH_REGS_RTC_H */ | ||
diff --git a/drivers/thermal/exynos_thermal.c b/drivers/thermal/exynos_thermal.c index 46568c078dee..b777ae6f0a8f 100644 --- a/drivers/thermal/exynos_thermal.c +++ b/drivers/thermal/exynos_thermal.c | |||
@@ -39,8 +39,6 @@ | |||
39 | #include <linux/cpu_cooling.h> | 39 | #include <linux/cpu_cooling.h> |
40 | #include <linux/of.h> | 40 | #include <linux/of.h> |
41 | 41 | ||
42 | #include <plat/cpu.h> | ||
43 | |||
44 | /* Exynos generic registers */ | 42 | /* Exynos generic registers */ |
45 | #define EXYNOS_TMU_REG_TRIMINFO 0x0 | 43 | #define EXYNOS_TMU_REG_TRIMINFO 0x0 |
46 | #define EXYNOS_TMU_REG_CONTROL 0x20 | 44 | #define EXYNOS_TMU_REG_CONTROL 0x20 |