]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
usb:hsotg:samsung: Remove platform dependency from s3c-hsotg
authorLukasz Majewski <l.majewski@samsung.com>
Fri, 4 May 2012 12:16:59 +0000 (14:16 +0200)
committerFelipe Balbi <balbi@ti.com>
Fri, 4 May 2012 12:53:09 +0000 (15:53 +0300)
This code removes platform dependency from s3c-hsotg driver.

Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Kukjin Kim <kgene.kim@samsung.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
arch/arm/mach-exynos/mach-nuri.c
arch/arm/mach-exynos/mach-universal_c210.c
arch/arm/mach-s3c64xx/mach-crag6410.c
arch/arm/mach-s3c64xx/mach-smartq.c
arch/arm/mach-s3c64xx/mach-smdk6410.c
arch/arm/mach-s5pv210/mach-goni.c
arch/arm/plat-samsung/devs.c
drivers/usb/gadget/s3c-hsotg.c
drivers/usb/gadget/s3c-hsotg.h [moved from arch/arm/plat-samsung/include/plat/regs-usb-hsotg.h with 94% similarity]
include/linux/platform_data/s3c-hsotg.h [moved from arch/arm/plat-samsung/include/plat/udc-hs.h with 90% similarity]

index b4f1f902ce6d06a82cd9f9f00d90caa0e9548782..e284b0e4ca2e6bfc5c06e5ec31bc0808a8a7ac1b 100644 (file)
@@ -44,6 +44,7 @@
 #include <plat/fb.h>
 #include <plat/sdhci.h>
 #include <plat/ehci.h>
+#include <linux/platform_data/s3c-hsotg.h>
 #include <plat/clock.h>
 #include <plat/gpio-cfg.h>
 #include <plat/iic.h>
index 7ebf79c2ab348bd273099716d9bd1b4df6cdc572..ad15d0fda3c1d2f44fefdfe295850f534b55ea3b 100644 (file)
@@ -42,6 +42,7 @@
 #include <plat/fimc-core.h>
 #include <plat/camport.h>
 #include <plat/mipi_csis.h>
+#include <linux/platform_data/s3c-hsotg.h>
 
 #include <mach/map.h>
 
index e20bf58353652fdc6d39d852c696f85e206ad68f..a02f204d99edc9cd08736ea4b2de6097bb7af2f9 100644 (file)
@@ -61,7 +61,7 @@
 #include <plat/sdhci.h>
 #include <plat/gpio-cfg.h>
 #include <plat/s3c64xx-spi.h>
-#include <plat/udc-hs.h>
+#include <linux/platform_data/s3c-hsotg.h>
 
 #include <plat/keypad.h>
 #include <plat/clock.h>
index ce745e19aa2756e5a0bbc3f5094bc1ceba08060b..ee0d13c98378b3e761505ff57a38733dc1146d75 100644 (file)
@@ -33,7 +33,7 @@
 #include <plat/gpio-cfg.h>
 #include <plat/hwmon.h>
 #include <plat/regs-serial.h>
-#include <plat/udc-hs.h>
+#include <linux/platform_data/s3c-hsotg.h>
 #include <plat/usb-control.h>
 #include <plat/sdhci.h>
 #include <plat/ts.h>
index d55bc96d9582f9d24301da64e64d90984c7c585a..bf477e33f0ee15dd54a2fcd2fe9c7eb2021da0bc 100644 (file)
@@ -72,7 +72,7 @@
 #include <plat/keypad.h>
 #include <plat/backlight.h>
 #include <plat/regs-fb-v4.h>
-#include <plat/udc-hs.h>
+#include <linux/platform_data/s3c-hsotg.h>
 
 #include "common.h"
 
index a8933de3d627ca922c3560d1a907c7761f054097..921da285ff20806859b2da99e2998e1c64cc1022 100644 (file)
@@ -49,6 +49,7 @@
 #include <plat/mfc.h>
 #include <plat/regs-fb-v4.h>
 #include <plat/camport.h>
+#include <linux/platform_data/s3c-hsotg.h>
 
 #include <media/v4l2-mediabus.h>
 #include <media/s5p_fimc.h>
index 8b928f9bc1c311e72936ad392f6ed13397bc3317..a41c808847c0fd7da5b2ad6c97eeb0a1ebe5d024 100644 (file)
@@ -57,7 +57,7 @@
 #include <plat/sdhci.h>
 #include <plat/ts.h>
 #include <plat/udc.h>
-#include <plat/udc-hs.h>
+#include <linux/platform_data/s3c-hsotg.h>
 #include <plat/usb-control.h>
 #include <plat/usb-phy.h>
 #include <plat/regs-iic.h>
index 105b206cd8443dbe01bfd32b14555a51b22438b6..70c6f3b45cf2b3885313cee9b9cd2bc7a4904964 100644 (file)
@@ -34,9 +34,9 @@
 #include <mach/map.h>
 
 #include <plat/regs-usb-hsotg-phy.h>
-#include <plat/regs-usb-hsotg.h>
+#include "s3c-hsotg.h"
+#include <linux/platform_data/s3c-hsotg.h>
 #include <mach/regs-sys.h>
-#include <plat/udc-hs.h>
 #include <plat/cpu.h>
 
 #define DMA_ADDR_INVALID (~((dma_addr_t)0))
similarity index 94%
rename from arch/arm/plat-samsung/include/plat/regs-usb-hsotg.h
rename to drivers/usb/gadget/s3c-hsotg.h
index dc90f5ede88f83cf542ce71cb913d22e870b208f..4c4ccc44b577d06575719282658ff8fa6d49af07 100644 (file)
 
 #define S3C_HPTXFSIZ                           S3C_HSOTG_REG(0x100)
 
-#define S3C_DPTXFSIZn(_a)                      S3C_HSOTG_REG(0x104 + (((_a) - 1) * 4))
+#define S3C_DPTXFSIZn(_a)              S3C_HSOTG_REG(0x104 + (((_a) - 1) * 4))
 
 #define S3C_DPTXFSIZn_DPTxFSize_MASK           (0xffff << 16)
 #define S3C_DPTXFSIZn_DPTxFSize_SHIFT          (16)
 
 #define S3C_DIEPCTL0                           S3C_HSOTG_REG(0x900)
 #define S3C_DOEPCTL0                           S3C_HSOTG_REG(0xB00)
-#define S3C_DIEPCTL(_a)                                S3C_HSOTG_REG(0x900 + ((_a) * 0x20))
-#define S3C_DOEPCTL(_a)                                S3C_HSOTG_REG(0xB00 + ((_a) * 0x20))
+#define S3C_DIEPCTL(_a)                        S3C_HSOTG_REG(0x900 + ((_a) * 0x20))
+#define S3C_DOEPCTL(_a)                        S3C_HSOTG_REG(0xB00 + ((_a) * 0x20))
 
 /* EP0 specialness:
  * bits[29..28] - reserved (no SetD0PID, SetD1PID)
 #define S3C_DxEPCTL_MPS_LIMIT                  (0x7ff)
 #define S3C_DxEPCTL_MPS(_x)                    ((_x) << 0)
 
-#define S3C_DIEPINT(_a)                                S3C_HSOTG_REG(0x908 + ((_a) * 0x20))
-#define S3C_DOEPINT(_a)                                S3C_HSOTG_REG(0xB08 + ((_a) * 0x20))
+#define S3C_DIEPINT(_a)                        S3C_HSOTG_REG(0x908 + ((_a) * 0x20))
+#define S3C_DOEPINT(_a)                        S3C_HSOTG_REG(0xB08 + ((_a) * 0x20))
 
 #define S3C_DxEPINT_INEPNakEff                 (1 << 6)
 #define S3C_DxEPINT_Back2BackSetup             (1 << 6)
 #define S3C_DOEPTSIZ0_XferSize_MASK            (0x7f << 0)
 #define S3C_DOEPTSIZ0_XferSize_SHIFT           (0)
 
-#define S3C_DIEPTSIZ(_a)                       S3C_HSOTG_REG(0x910 + ((_a) * 0x20))
-#define S3C_DOEPTSIZ(_a)                       S3C_HSOTG_REG(0xB10 + ((_a) * 0x20))
+#define S3C_DIEPTSIZ(_a)               S3C_HSOTG_REG(0x910 + ((_a) * 0x20))
+#define S3C_DOEPTSIZ(_a)               S3C_HSOTG_REG(0xB10 + ((_a) * 0x20))
 
 #define S3C_DxEPTSIZ_MC_MASK                   (0x3 << 29)
 #define S3C_DxEPTSIZ_MC_SHIFT                  (29)
 #define S3C_DxEPTSIZ_XferSize(_x)              ((_x) << 0)
 
 
-#define S3C_DIEPDMA(_a)                                S3C_HSOTG_REG(0x914 + ((_a) * 0x20))
-#define S3C_DOEPDMA(_a)                                S3C_HSOTG_REG(0xB14 + ((_a) * 0x20))
-#define S3C_DTXFSTS(_a)                                S3C_HSOTG_REG(0x918 + ((_a) * 0x20))
+#define S3C_DIEPDMA(_a)                        S3C_HSOTG_REG(0x914 + ((_a) * 0x20))
+#define S3C_DOEPDMA(_a)                        S3C_HSOTG_REG(0xB14 + ((_a) * 0x20))
+#define S3C_DTXFSTS(_a)                        S3C_HSOTG_REG(0x918 + ((_a) * 0x20))
 
-#define S3C_EPFIFO(_a)                         S3C_HSOTG_REG(0x1000 + ((_a) * 0x1000))
+#define S3C_EPFIFO(_a)                 S3C_HSOTG_REG(0x1000 + ((_a) * 0x1000))
 
 #endif /* __PLAT_S3C64XX_REGS_USB_HSOTG_H */
similarity index 90%
rename from arch/arm/plat-samsung/include/plat/udc-hs.h
rename to include/linux/platform_data/s3c-hsotg.h
index c9e3667cb2b15ef142c3766de06cf519131dedf1..97ec12c2ded4bf9fe696fdaa0d100d83b8ec172e 100644 (file)
@@ -1,4 +1,4 @@
-/* arch/arm/plat-s3c/include/plat/udc-hs.h
+/* include/linux/platform_data/s3c-hsotg.h
  *
  * Copyright 2008 Openmoko, Inc.
  * Copyright 2008 Simtec Electronics
@@ -25,7 +25,8 @@ enum s3c_hsotg_dmamode {
  */
 struct s3c_hsotg_plat {
        enum s3c_hsotg_dmamode  dma;
-       unsigned int            is_osc : 1;
+       unsigned int            is_osc:1;
+       int                     phy_type;
 
        int (*phy_init)(struct platform_device *pdev, int type);
        int (*phy_exit)(struct platform_device *pdev, int type);