lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue,  3 Jan 2012 23:12:10 +0100
From:	Jaccon Bastiaansen <jaccon.bastiaansen@...il.com>
To:	s.hauer@...gutronix.de, kernel@...gutronix.de,
	u.kleine-koenig@...gutronix.de, davem@...emloft.net,
	cavokz@...il.com, jaccon.bastiaansen@...il.com
Cc:	linux-arm-kernel@...ts.infradead.org, netdev@...r.kernel.org
Subject: [PATCH 2/4] CS89x0 : add CS89x0 platform device to the iMX21ADS board

Add CS89x0 networking support to the iMX21ADS board by using the
platform driver support in the CS89x0 driver.

Signed-off-by: Jaccon Bastiaansen <jaccon.bastiaansen@...il.com>
---
 arch/arm/configs/imx_v4_v5_defconfig |    2 ++
 arch/arm/mach-imx/mach-mx21ads.c     |   21 +++++++++++++++++++++
 2 files changed, 23 insertions(+), 0 deletions(-)

diff --git a/arch/arm/configs/imx_v4_v5_defconfig b/arch/arm/configs/imx_v4_v5_defconfig
index 11a4192..fc0106f 100644
--- a/arch/arm/configs/imx_v4_v5_defconfig
+++ b/arch/arm/configs/imx_v4_v5_defconfig
@@ -81,6 +81,8 @@ CONFIG_NET_ETHERNET=y
 CONFIG_SMC91X=y
 CONFIG_DM9000=y
 CONFIG_SMC911X=y
+CONFIG_CS89x0=y
+CONFIG_CS89x0_PLATFORM=y
 # CONFIG_NETDEV_1000 is not set
 # CONFIG_NETDEV_10000 is not set
 # CONFIG_INPUT_MOUSEDEV is not set
diff --git a/arch/arm/mach-imx/mach-mx21ads.c b/arch/arm/mach-imx/mach-mx21ads.c
index 25f8402..b26b49c 100644
--- a/arch/arm/mach-imx/mach-mx21ads.c
+++ b/arch/arm/mach-imx/mach-mx21ads.c
@@ -159,6 +159,26 @@ static struct platform_device mx21ads_nor_mtd_device = {
 	.resource = &mx21ads_flash_resource,
 };
 
+static struct resource mx21ads_cs8900_resources[] = {
+	{
+		.start = (u32)MX21ADS_CS8900A_IOBASE_REG,
+		.end = (u32)MX21ADS_CS8900A_IOBASE_REG + 0x200000 - 1,
+		.flags = IORESOURCE_MEM
+	},
+	{
+		.start = MX21ADS_CS8900A_IRQ,
+		.end = MX21ADS_CS8900A_IRQ,
+		.flags = IORESOURCE_IRQ
+	}
+};
+
+static struct platform_device mx21ads_cs8900_device = {
+	.name = "cs89x0",
+	.id = 0,
+	.num_resources = ARRAY_SIZE(mx21ads_cs8900_resources),
+	.resource = mx21ads_cs8900_resources
+};
+
 static const struct imxuart_platform_data uart_pdata_rts __initconst = {
 	.flags = IMXUART_HAVE_RTSCTS,
 };
@@ -275,6 +295,7 @@ static void __init mx21ads_map_io(void)
 
 static struct platform_device *platform_devices[] __initdata = {
 	&mx21ads_nor_mtd_device,
+	&mx21ads_cs8900_device
 };
 
 static void __init mx21ads_board_init(void)
-- 
1.7.1

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ