From patchwork Fri Jul 8 17:59:50 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 957122 Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p68HqUuS027701 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 8 Jul 2011 17:52:51 GMT Received: from canuck.infradead.org ([2001:4978:20e::1]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QfFDu-00041b-S9; Fri, 08 Jul 2011 17:52:19 +0000 Received: from localhost ([127.0.0.1] helo=canuck.infradead.org) by canuck.infradead.org with esmtp (Exim 4.76 #1 (Red Hat Linux)) id 1QfFDu-00010Y-7u; Fri, 08 Jul 2011 17:52:18 +0000 Received: from ch1ehsobe006.messaging.microsoft.com ([216.32.181.186] helo=CH1EHSOBE008.bigfish.com) by canuck.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1QfFDc-0000wz-9N for linux-arm-kernel@lists.infradead.org; Fri, 08 Jul 2011 17:52:01 +0000 Received: from mail185-ch1-R.bigfish.com (216.32.181.173) by CH1EHSOBE008.bigfish.com (10.43.70.58) with Microsoft SMTP Server id 14.1.225.22; Fri, 8 Jul 2011 17:51:57 +0000 Received: from mail185-ch1 (localhost.localdomain [127.0.0.1]) by mail185-ch1-R.bigfish.com (Postfix) with ESMTP id 5B825640143; Fri, 8 Jul 2011 17:51:57 +0000 (UTC) X-SpamScore: 0 X-BigFish: VS0(zzzz1202hzz8275bhz2dh2a8h668h839h62h) X-Spam-TCS-SCL: 1:0 X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null); IPVD:NLI; H:mail.freescale.net; RD:none; EFVD:NLI Received: from mail185-ch1 (localhost.localdomain [127.0.0.1]) by mail185-ch1 (MessageSwitch) id 1310147517254075_5700; Fri, 8 Jul 2011 17:51:57 +0000 (UTC) Received: from CH1EHSMHS014.bigfish.com (snatpool1.int.messaging.microsoft.com [10.43.68.246]) by mail185-ch1.bigfish.com (Postfix) with ESMTP id 38CD81004B; Fri, 8 Jul 2011 17:51:57 +0000 (UTC) Received: from mail.freescale.net (70.37.183.190) by CH1EHSMHS014.bigfish.com (10.43.70.14) with Microsoft SMTP Server (TLS) id 14.1.225.22; Fri, 8 Jul 2011 17:51:53 +0000 Received: from az33smr01.freescale.net (10.64.34.199) by 039-SN1MMR1-002.039d.mgd.msft.net (10.84.1.15) with Microsoft SMTP Server id 14.1.289.8; Fri, 8 Jul 2011 12:51:52 -0500 Received: from localhost.localdomain ([10.29.240.182]) by az33smr01.freescale.net (8.13.1/8.13.0) with ESMTP id p68HpmM4024474; Fri, 8 Jul 2011 12:51:50 -0500 (CDT) From: Fabio Estevam To: Subject: [PATCH 2/2] ARM: mach-imx/mx25_3ds: Add FlexCAN support Date: Fri, 8 Jul 2011 14:59:50 -0300 Message-ID: <1310147990-9198-2-git-send-email-fabio.estevam@freescale.com> X-Mailer: git-send-email 1.6.0.4 In-Reply-To: <1310147990-9198-1-git-send-email-fabio.estevam@freescale.com> References: <1310147990-9198-1-git-send-email-fabio.estevam@freescale.com> MIME-Version: 1.0 X-OriginatorOrg: freescale.com X-CRM114-Version: 20090807-BlameThorstenAndJenny ( TRE 0.7.6 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20110708_135200_724355_27A4DBC7 X-CRM114-Status: GOOD ( 16.40 ) X-Spam-Score: -0.7 (/) X-Spam-Report: SpamAssassin version 3.3.1 on canuck.infradead.org summary: Content analysis details: (-0.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [216.32.181.186 listed in list.dnswl.org] Cc: Fabio Estevam , kernel@pengutronix.de X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: linux-arm-kernel-bounces@lists.infradead.org Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Fri, 08 Jul 2011 17:52:51 +0000 (UTC) Signed-off-by: Fabio Estevam --- arch/arm/mach-imx/Kconfig | 1 + arch/arm/mach-imx/mach-mx25_3ds.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig index 0519dd7..0253e66 100644 --- a/arch/arm/mach-imx/Kconfig +++ b/arch/arm/mach-imx/Kconfig @@ -133,6 +133,7 @@ comment "MX25 platforms:" config MACH_MX25_3DS bool "Support MX25PDK (3DS) Platform" select SOC_IMX25 + select IMX_HAVE_PLATFORM_FLEXCAN select IMX_HAVE_PLATFORM_FSL_USB2_UDC select IMX_HAVE_PLATFORM_IMX2_WDT select IMX_HAVE_PLATFORM_IMXDI_RTC diff --git a/arch/arm/mach-imx/mach-mx25_3ds.c b/arch/arm/mach-imx/mach-mx25_3ds.c index 01534bb..d3518b9 100644 --- a/arch/arm/mach-imx/mach-mx25_3ds.c +++ b/arch/arm/mach-imx/mach-mx25_3ds.c @@ -43,6 +43,8 @@ #include "devices-imx25.h" +#define MX25PDK_CAN_PWDN IMX_GPIO_NR(4, 6) + static const struct imxuart_platform_data uart_pdata __initconst = { .flags = IMXUART_HAVE_RTSCTS, }; @@ -108,6 +110,11 @@ static iomux_v3_cfg_t mx25pdk_pads[] = { /* I2C1 */ MX25_PAD_I2C1_CLK__I2C1_CLK, MX25_PAD_I2C1_DAT__I2C1_DAT, + + /* CAN1 */ + MX25_PAD_GPIO_A__CAN1_TX, + MX25_PAD_GPIO_B__CAN1_RX, + MX25_PAD_D14__GPIO_4_6, /* CAN_PWDN */ }; static const struct fec_platform_data mx25_fec_pdata __initconst = { @@ -238,6 +245,9 @@ static void __init mx25pdk_init(void) imx25_add_sdhci_esdhc_imx(0, &mx25pdk_esdhc_pdata); imx25_add_imx_i2c0(&mx25_3ds_i2c0_data); + + gpio_request_one(MX25PDK_CAN_PWDN, GPIOF_OUT_INIT_LOW, "can-pwdn"); + imx25_add_flexcan0(NULL); } static void __init mx25pdk_timer_init(void)