From patchwork Tue Jan 27 16:51:13 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Steve Glendinning X-Patchwork-Id: 20469 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by ozlabs.org (Postfix) with ESMTP id 263094F386 for ; Wed, 28 Jan 2009 03:51:31 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756171AbZA0Qv0 (ORCPT ); Tue, 27 Jan 2009 11:51:26 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755607AbZA0QvZ (ORCPT ); Tue, 27 Jan 2009 11:51:25 -0500 Received: from [86.54.240.114] ([86.54.240.114]:53200 "EHLO kensington.shawell.net" rhost-flags-FAIL-FAIL-OK-FAIL) by vger.kernel.org with ESMTP id S1755781AbZA0QvV (ORCPT ); Tue, 27 Jan 2009 11:51:21 -0500 Received: from localhost.localdomain (kensington.shawell.net [127.0.0.1]) by kensington.shawell.net (Postfix) with ESMTP id E3A384A4115; Tue, 27 Jan 2009 16:51:17 +0000 (GMT) From: Steve Glendinning To: linux-arm-kernel@lists.arm.linux.org.uk, netdev@vger.kernel.org Cc: David Miller , Russell King , Stanley Miao , Ian Saturley , Mark Brown , Catalin Marinas , Steve Glendinning Subject: [PATCH 05/10] arm: convert pcm037 platform to use smsc911x Date: Tue, 27 Jan 2009 16:51:13 +0000 Message-Id: <1233075077-17205-6-git-send-email-steve.glendinning@smsc.com> X-Mailer: git-send-email 1.6.0.6 In-Reply-To: <1233075077-17205-5-git-send-email-steve.glendinning@smsc.com> References: <1233075077-17205-1-git-send-email-steve.glendinning@smsc.com> <1233075077-17205-2-git-send-email-steve.glendinning@smsc.com> <1233075077-17205-3-git-send-email-steve.glendinning@smsc.com> <1233075077-17205-4-git-send-email-steve.glendinning@smsc.com> <1233075077-17205-5-git-send-email-steve.glendinning@smsc.com> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Updated to also specify SMSC911X_FORCE_INTERNAL_PHY, as the external phy detection hardware strap is incorrectly pulled high on this platform. Signed-off-by: Steve Glendinning Acked-by: Sascha Hauer Tested-by: Sascha Hauer --- arch/arm/mach-mx3/pcm037.c | 23 +++++++++++++---------- 1 files changed, 13 insertions(+), 10 deletions(-) diff --git a/arch/arm/mach-mx3/pcm037.c b/arch/arm/mach-mx3/pcm037.c index 8cea825..c6fe26a 100644 --- a/arch/arm/mach-mx3/pcm037.c +++ b/arch/arm/mach-mx3/pcm037.c @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include @@ -64,7 +64,7 @@ static struct imxuart_platform_data uart_pdata = { .flags = IMXUART_HAVE_RTSCTS, }; -static struct resource smc911x_resources[] = { +static struct resource smsc911x_resources[] = { [0] = { .start = CS1_BASE_ADDR + 0x300, .end = CS1_BASE_ADDR + 0x300 + SZ_64K - 1, @@ -73,22 +73,25 @@ static struct resource smc911x_resources[] = { [1] = { .start = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), .end = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), - .flags = IORESOURCE_IRQ, + .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWLEVEL, }, }; -static struct smc911x_platdata smc911x_info = { - .flags = SMC911X_USE_32BIT, - .irq_flags = IRQF_SHARED | IRQF_TRIGGER_LOW, +static struct smsc911x_platform_config smsc911x_info = { + .flags = SMSC911X_USE_32BIT | SMSC911X_FORCE_INTERNAL_PHY | + SMSC911X_SAVE_MAC_ADDRESS, + .irq_polarity = SMSC911X_IRQ_POLARITY_ACTIVE_LOW, + .irq_type = SMSC911X_IRQ_TYPE_OPEN_DRAIN, + .phy_interface = PHY_INTERFACE_MODE_MII, }; static struct platform_device pcm037_eth = { - .name = "smc911x", + .name = "smsc911x", .id = -1, - .num_resources = ARRAY_SIZE(smc911x_resources), - .resource = smc911x_resources, + .num_resources = ARRAY_SIZE(smsc911x_resources), + .resource = smsc911x_resources, .dev = { - .platform_data = &smc911x_info, + .platform_data = &smsc911x_info, }, };