From 97976e223be3091a91da103358c3c6cffff7db81 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Mon, 7 Feb 2011 16:35:20 +0100 Subject: ARM: mx3: use .init_early to initialize cpu type, reset address and iomuxer MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This used to be done in .map_io which is supposed to only setup the memory mapping. Signed-off-by: Uwe Kleine-König Signed-off-by: Sascha Hauer --- arch/arm/mach-mx3/mach-mx35_3ds.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c') diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c index b1963f257c20..c5115dc5c0c5 100644 --- a/arch/arm/mach-mx3/mach-mx35_3ds.c +++ b/arch/arm/mach-mx3/mach-mx35_3ds.c @@ -193,9 +193,10 @@ struct sys_timer mx35pdk_timer = { MACHINE_START(MX35_3DS, "Freescale MX35PDK") /* Maintainer: Freescale Semiconductor, Inc */ - .boot_params = MX3x_PHYS_OFFSET + 0x100, - .map_io = mx35_map_io, - .init_irq = mx35_init_irq, - .init_machine = mxc_board_init, - .timer = &mx35pdk_timer, + .boot_params = MX3x_PHYS_OFFSET + 0x100, + .map_io = mx35_map_io, + .init_early = imx35_init_early, + .init_irq = mx35_init_irq, + .timer = &mx35pdk_timer, + .init_machine = mxc_board_init, MACHINE_END -- cgit v1.2.1 From 4bd597b633ae630e09d58957bd99870eac35fcb4 Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Mon, 3 Jan 2011 11:30:28 +0100 Subject: ARM i.MX ehci: do ehci init in board specific functions The mxc-ehci driver calls SoC specific phy initialization right after calling board specific initialization. To offer greater flexibility for boards to setup the phy and to get rid of some unnecessary flags in platform data this patch lets the boards call the SoC specific phy initialization and remove it from the driver. Signed-off-by: Sascha Hauer --- arch/arm/mach-mx3/mach-mx35_3ds.c | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c') diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c index c5115dc5c0c5..dac1896a5b21 100644 --- a/arch/arm/mach-mx3/mach-mx35_3ds.c +++ b/arch/arm/mach-mx3/mach-mx35_3ds.c @@ -120,6 +120,11 @@ static iomux_v3_cfg_t mx35pdk_pads[] = { MX35_PAD_SD1_DATA3__ESDHC1_DAT3, }; +static int mx35_3ds_otg_init(struct platform_device *pdev) +{ + return mx35_initialize_usb_hw(pdev->id, MXC_EHCI_INTERNAL_PHY); +} + /* OTG config */ static const struct fsl_usb2_platform_data usb_otg_pdata __initconst = { .operating_mode = FSL_USB2_DR_DEVICE, @@ -127,15 +132,20 @@ static const struct fsl_usb2_platform_data usb_otg_pdata __initconst = { }; static struct mxc_usbh_platform_data otg_pdata __initdata = { + .init = mx35_3ds_otg_init, .portsc = MXC_EHCI_MODE_UTMI, - .flags = MXC_EHCI_INTERNAL_PHY, }; +static int mx35_3ds_usbh_init(struct platform_device *pdev) +{ + return mx35_initialize_usb_hw(pdev->id, MXC_EHCI_INTERFACE_SINGLE_UNI | + MXC_EHCI_INTERNAL_PHY); +} + /* USB HOST config */ static const struct mxc_usbh_platform_data usb_host_pdata __initconst = { + .init = mx35_3ds_usbh_init, .portsc = MXC_EHCI_MODE_SERIAL, - .flags = MXC_EHCI_INTERFACE_SINGLE_UNI | - MXC_EHCI_INTERNAL_PHY, }; static int otg_mode_host; -- cgit v1.2.1 From e134fb2b40ca7e2d96ba460b0c844c6a9fa489c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Fri, 11 Feb 2011 10:23:19 +0100 Subject: ARM: mx3+mx5: rename mxc_board_init to ${machine}_init MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit mxc_board_init is too generic to be useful. Additionally change some mxc_timer to ${machine}_timer, too. Signed-off-by: Uwe Kleine-König Signed-off-by: Sascha Hauer --- arch/arm/mach-mx3/mach-mx35_3ds.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c') diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c index dac1896a5b21..be12ac1d1954 100644 --- a/arch/arm/mach-mx3/mach-mx35_3ds.c +++ b/arch/arm/mach-mx3/mach-mx35_3ds.c @@ -166,7 +166,7 @@ __setup("otg_mode=", mx35_3ds_otg_mode); /* * Board specific initialization. */ -static void __init mxc_board_init(void) +static void __init mx35_3ds_init(void) { mxc_iomux_v3_setup_multiple_pads(mx35pdk_pads, ARRAY_SIZE(mx35pdk_pads)); @@ -208,5 +208,5 @@ MACHINE_START(MX35_3DS, "Freescale MX35PDK") .init_early = imx35_init_early, .init_irq = mx35_init_irq, .timer = &mx35pdk_timer, - .init_machine = mxc_board_init, + .init_machine = mx35_3ds_init, MACHINE_END -- cgit v1.2.1 From 352cd9a0b849494a44a46c60219b8b6ea99f1d70 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Tue, 1 Mar 2011 16:59:44 -0300 Subject: ARM: mx35_3ds: Add I2C support Signed-off-by: Fabio Estevam Signed-off-by: Sascha Hauer --- arch/arm/mach-mx3/mach-mx35_3ds.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c') diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c index be12ac1d1954..5f35d5c88f19 100644 --- a/arch/arm/mach-mx3/mach-mx35_3ds.c +++ b/arch/arm/mach-mx3/mach-mx35_3ds.c @@ -118,6 +118,9 @@ static iomux_v3_cfg_t mx35pdk_pads[] = { MX35_PAD_SD1_DATA1__ESDHC1_DAT1, MX35_PAD_SD1_DATA2__ESDHC1_DAT2, MX35_PAD_SD1_DATA3__ESDHC1_DAT3, + /* I2C1 */ + MX35_PAD_I2C1_CLK__I2C1_SCL, + MX35_PAD_I2C1_DAT__I2C1_SDA, }; static int mx35_3ds_otg_init(struct platform_device *pdev) @@ -163,6 +166,10 @@ static int __init mx35_3ds_otg_mode(char *options) } __setup("otg_mode=", mx35_3ds_otg_mode); +static const struct imxi2c_platform_data mx35_3ds_i2c0_data __initconst = { + .bitrate = 100000, +}; + /* * Board specific initialization. */ @@ -190,6 +197,7 @@ static void __init mx35_3ds_init(void) if (mxc_expio_init(MX35_CS5_BASE_ADDR, EXPIO_PARENT_INT)) pr_warn("Init of the debugboard failed, all " "devices on the debugboard are unusable.\n"); + imx35_add_imx_i2c0(&mx35_3ds_i2c0_data); } static void __init mx35pdk_timer_init(void) -- cgit v1.2.1 From 1a46cce8564b3f4e42c283bd7d18ad9674383ef5 Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Wed, 2 Mar 2011 11:26:49 -0300 Subject: ARM: mx3/mx35_3ds: Use MX35 USB OTG Erratum Signed-off-by: Fabio Estevam Signed-off-by: Sascha Hauer --- arch/arm/mach-mx3/mach-mx35_3ds.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'arch/arm/mach-mx3/mach-mx35_3ds.c') diff --git a/arch/arm/mach-mx3/mach-mx35_3ds.c b/arch/arm/mach-mx3/mach-mx35_3ds.c index 5f35d5c88f19..ff5fe231b8d6 100644 --- a/arch/arm/mach-mx3/mach-mx35_3ds.c +++ b/arch/arm/mach-mx3/mach-mx35_3ds.c @@ -132,6 +132,11 @@ static int mx35_3ds_otg_init(struct platform_device *pdev) static const struct fsl_usb2_platform_data usb_otg_pdata __initconst = { .operating_mode = FSL_USB2_DR_DEVICE, .phy_mode = FSL_USB2_PHY_UTMI_WIDE, + .workaround = FLS_USB2_WORKAROUND_ENGCM09152, +/* + * ENGCM09152 also requires a hardware change. + * Please check the MX35 Chip Errata document for details. + */ }; static struct mxc_usbh_platform_data otg_pdata __initdata = { -- cgit v1.2.1