From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kevin Hilman Subject: Re: [PATCH] OMAP3EVM:FIX: Reset the SMSC911x Ethernet controller in board_init Date: Mon, 24 Jan 2011 11:44:19 -0800 Message-ID: <87oc769je4.fsf@ti.com> References: <1295880108-15584-1-git-send-email-hvaibhav@ti.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from na3sys009aog109.obsmtp.com ([74.125.149.201]:46936 "EHLO na3sys009aog109.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751300Ab1AXToX (ORCPT ); Mon, 24 Jan 2011 14:44:23 -0500 Received: by mail-pv0-f178.google.com with SMTP id 6so1102621pvg.37 for ; Mon, 24 Jan 2011 11:44:23 -0800 (PST) In-Reply-To: <1295880108-15584-1-git-send-email-hvaibhav@ti.com> (hvaibhav@ti.com's message of "Mon, 24 Jan 2011 20:11:48 +0530") Sender: linux-omap-owner@vger.kernel.org List-Id: linux-omap@vger.kernel.org To: hvaibhav@ti.com Cc: linux-omap@vger.kernel.org, charu@ti.com, tony@atomide.com Hi Vaibhav, hvaibhav@ti.com writes: > From: Vaibhav Hiremath > > With addition of HWMOD support to GPIO, the Ethernet controller > goes undetected for OMAP35xEVM. So explicitely assert the reset signal to > Ethernet controller smsc911x - > > - GPIO7 (>=RevG version of EVM's) > - GPIO64 (<=RevD version of EVM's) > > I have tested this patch on RevG version of EVM with ES3.1 Si. > This patch is based on intial version from Charulatha V. > > Signed-off-by: Vaibhav Hiremath This didn't apply cleanly to l-o master, with or without your previous patches which touch the EVM board file. > --- > NOTE: I have not been able to test it on older version of EVM's. After manually applying, Tested-by: Kevin Hilman I tested on my rev D board with DHCP + nfs rootfs and it's working well. While testing though, I also noticed that the smsc driver is dumping some warnings (below) while trying to get the MAC address, resulting in not using the actual MAC but generating a random one. This isn't related to your patch, since it also happens with l-o master, but was wondering if you saw the same thing? A first glance looks like there are problems with the locking in the driver, but I didn't look very deep. Kevin [ 2.221832] smsc911x: Driver version 2008-10-21. [ 2.227447] ------------[ cut here ]------------ [ 2.232574] WARNING: at /work/kernel/omap/dev/drivers/net/smsc911x.c:261 smsc911x_mac_read+0x24/0x220() [ 2.242645] Modules linked in: [ 2.246124] [] (unwind_backtrace+0x0/0xe0) from [] (warn_slowpath_common+0x4c/0x64) [ 2.256256] [] (warn_slowpath_common+0x4c/0x64) from [] (warn_slowpath_null+0x18/0x1c) [ 2.266632] [] (warn_slowpath_null+0x18/0x1c) from [] (smsc911x_mac_read+0x24/0x220) [ 2.276855] [] (smsc911x_mac_read+0x24/0x220) from [] (smsc911x_read_mac_address+0x18/0x6c) [ 2.287750] [] (smsc911x_read_mac_address+0x18/0x6c) from [] (smsc911x_drv_probe+0x498/0x1788) [ 2.298858] [] (smsc911x_drv_probe+0x498/0x1788) from [] (platform_drv_probe+0x14/0x18) [ 2.309356] [] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xc8/0x184) [ 2.319793] [] (driver_probe_device+0xc8/0x184) from [] (__driver_attach+0x68/0x8c) [ 2.329895] [] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74) [ 2.339660] [] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x9c/0x228) [ 2.349426] [] (bus_add_driver+0x9c/0x228) from [] (driver_register+0xa0/0x124) [ 2.359191] [] (driver_register+0xa0/0x124) from [] (do_one_initcall+0xb4/0x18c) [ 2.369018] [] (do_one_initcall+0xb4/0x18c) from [] (kernel_init+0x150/0x218) [ 2.378631] [] (kernel_init+0x150/0x218) from [] (kernel_thread_exit+0x0/0x8) [ 2.388427] ---[ end trace 5ae2d34b582d5786 ]--- [ 2.393493] ------------[ cut here ]------------ [ 2.398406] WARNING: at /work/kernel/omap/dev/drivers/net/smsc911x.c:244 smsc911x_mac_complete+0x20/0xac() [ 2.408813] Modules linked in: [ 2.412139] [] (unwind_backtrace+0x0/0xe0) from [] (warn_slowpath_common+0x4c/0x64) [ 2.422241] [] (warn_slowpath_common+0x4c/0x64) from [] (warn_slowpath_null+0x18/0x1c) [ 2.432647] [] (warn_slowpath_null+0x18/0x1c) from [] (smsc911x_mac_complete+0x20/0xac) [ 2.443176] [] (smsc911x_mac_complete+0x20/0xac) from [] (smsc911x_mac_read+0x1a0/0x220) [ 2.453735] [] (smsc911x_mac_read+0x1a0/0x220) from [] (smsc911x_read_mac_address+0x18/0x6c) [ 2.464691] [] (smsc911x_read_mac_address+0x18/0x6c) from [] (smsc911x_drv_probe+0x498/0x1788) [ 2.475860] [] (smsc911x_drv_probe+0x498/0x1788) from [] (platform_drv_probe+0x14/0x18) [ 2.486328] [] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xc8/0x184) [ 2.496734] [] (driver_probe_device+0xc8/0x184) from [] (__driver_attach+0x68/0x8c) [ 2.506866] [] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74) [ 2.516601] [] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x9c/0x228) [ 2.526367] [] (bus_add_driver+0x9c/0x228) from [] (driver_register+0xa0/0x124) [ 2.536132] [] (driver_register+0xa0/0x124) from [] (do_one_initcall+0xb4/0x18c) [ 2.545989] [] (do_one_initcall+0xb4/0x18c) from [] (kernel_init+0x150/0x218) [ 2.555572] [] (kernel_init+0x150/0x218) from [] (kernel_thread_exit+0x0/0x8) [ 2.565124] ---[ end trace 5ae2d34b582d5787 ]--- [ 2.570037] ------------[ cut here ]------------ [ 2.575103] WARNING: at /work/kernel/omap/dev/drivers/net/smsc911x.c:261 smsc911x_mac_read+0x24/0x220() [ 2.585144] Modules linked in: [ 2.588470] [] (unwind_backtrace+0x0/0xe0) from [] (warn_slowpath_common+0x4c/0x64) [ 2.598602] [] (warn_slowpath_common+0x4c/0x64) from [] (warn_slowpath_null+0x18/0x1c) [ 2.609008] [] (warn_slowpath_null+0x18/0x1c) from [] (smsc911x_mac_read+0x24/0x220) [ 2.619201] [] (smsc911x_mac_read+0x24/0x220) from [] (smsc911x_read_mac_address+0x28/0x6c) [ 2.630065] [] (smsc911x_read_mac_address+0x28/0x6c) from [] (smsc911x_drv_probe+0x498/0x1788) [ 2.641204] [] (smsc911x_drv_probe+0x498/0x1788) from [] (platform_drv_probe+0x14/0x18) [ 2.651702] [] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xc8/0x184) [ 2.662109] [] (driver_probe_device+0xc8/0x184) from [] (__driver_attach+0x68/0x8c) [ 2.672210] [] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74) [ 2.681976] [] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x9c/0x228) [ 2.691741] [] (bus_add_driver+0x9c/0x228) from [] (driver_register+0xa0/0x124) [ 2.701507] [] (driver_register+0xa0/0x124) from [] (do_one_initcall+0xb4/0x18c) [ 2.711334] [] (do_one_initcall+0xb4/0x18c) from [] (kernel_init+0x150/0x218) [ 2.720916] [] (kernel_init+0x150/0x218) from [] (kernel_thread_exit+0x0/0x8) [ 2.730499] ---[ end trace 5ae2d34b582d5788 ]--- [ 2.735382] ------------[ cut here ]------------ [ 2.740447] WARNING: at /work/kernel/omap/dev/drivers/net/smsc911x.c:244 smsc911x_mac_complete+0x20/0xac() [ 2.750793] Modules linked in: [ 2.754272] [] (unwind_backtrace+0x0/0xe0) from [] (warn_slowpath_common+0x4c/0x64) [ 2.764404] [] (warn_slowpath_common+0x4c/0x64) from [] (warn_slowpath_null+0x18/0x1c) [ 2.774810] [] (warn_slowpath_null+0x18/0x1c) from [] (smsc911x_mac_complete+0x20/0xac) [ 2.785308] [] (smsc911x_mac_complete+0x20/0xac) from [] (smsc911x_mac_read+0x1a0/0x220) [ 2.795898] [] (smsc911x_mac_read+0x1a0/0x220) from [] (smsc911x_read_mac_address+0x28/0x6c) [ 2.806823] [] (smsc911x_read_mac_address+0x28/0x6c) from [] (smsc911x_drv_probe+0x498/0x1788) [ 2.817962] [] (smsc911x_drv_probe+0x498/0x1788) from [] (platform_drv_probe+0x14/0x18) [ 2.828460] [] (platform_drv_probe+0x14/0x18) from [] (driver_probe_device+0xc8/0x184) [ 2.838867] [] (driver_probe_device+0xc8/0x184) from [] (__driver_attach+0x68/0x8c) [ 2.848968] [] (__driver_attach+0x68/0x8c) from [] (bus_for_each_dev+0x48/0x74) [ 2.858734] [] (bus_for_each_dev+0x48/0x74) from [] (bus_add_driver+0x9c/0x228) [ 2.868499] [] (bus_add_driver+0x9c/0x228) from [] (driver_register+0xa0/0x124) [ 2.878265] [] (driver_register+0xa0/0x124) from [] (do_one_initcall+0xb4/0x18c) [ 2.888122] [] (do_one_initcall+0xb4/0x18c) from [] (kernel_init+0x150/0x218) [ 2.897705] [] (kernel_init+0x150/0x218) from [] (kernel_thread_exit+0x0/0x8) [ 2.907257] ---[ end trace 5ae2d34b582d5789 ]--- [ 2.929656] smsc911x-mdio: probed [ 2.934234] eth0: attached PHY driver [SMSC LAN911x Internal PHY] (mii_bus:phy_addr=ffffffff:01, irq=-1) [ 2.945068] net eth0: MAC Address: ea:a9:2b:c2:01:14