From patchwork Wed Aug 19 20:39:55 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Rajashekhara, Sudhakar" X-Patchwork-Id: 42574 Received: from bear.ext.ti.com (bear.ext.ti.com [192.94.94.41]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n7JBF6V7009830 for ; Wed, 19 Aug 2009 11:15:06 GMT Received: from dlep35.itg.ti.com ([157.170.170.118]) by bear.ext.ti.com (8.13.7/8.13.7) with ESMTP id n7JBD3K8028502; Wed, 19 Aug 2009 06:13:08 -0500 Received: from linux.omap.com (localhost [127.0.0.1]) by dlep35.itg.ti.com (8.13.7/8.13.7) with ESMTP id n7JBD2VI006144; Wed, 19 Aug 2009 06:13:03 -0500 (CDT) Received: from linux.omap.com (localhost [127.0.0.1]) by linux.omap.com (Postfix) with ESMTP id D57B080627; Wed, 19 Aug 2009 06:13:02 -0500 (CDT) X-Original-To: davinci-linux-open-source@linux.davincidsp.com Delivered-To: davinci-linux-open-source@linux.davincidsp.com Received: from dflp53.itg.ti.com (dflp53.itg.ti.com [128.247.5.6]) by linux.omap.com (Postfix) with ESMTP id 697BF80626 for ; Wed, 19 Aug 2009 06:13:00 -0500 (CDT) Received: from tidmzi-ftp.india.ext.ti.com (localhost [127.0.0.1]) by dflp53.itg.ti.com (8.13.8/8.13.8) with SMTP id n7JBCwNK012370; Wed, 19 Aug 2009 06:12:59 -0500 (CDT) Received: from symphonyindia.ti.com (symphony-ftp [192.168.247.11]) by tidmzi-ftp.india.ext.ti.com (Postfix) with SMTP id 1F1583886B; Wed, 19 Aug 2009 16:40:04 +0530 (IST) Received: from localhost.localdomain ([192.168.247.76]) by symphonyindia.ti.com (8.13.1/8.12.10) with ESMTP id n7JB6Dfe012027; Wed, 19 Aug 2009 16:36:13 +0530 From: Sudhakar Rajashekhara To: netdev@vger.kernel.org Date: Wed, 19 Aug 2009 16:39:55 -0400 Message-Id: <1250714395-9588-1-git-send-email-sudhakar.raj@ti.com> X-Mailer: git-send-email 1.5.6 Cc: davinci-linux-open-source@linux.davincidsp.com, davem@davemloft.net Subject: [PATCH] TI DaVinci EMAC: delay DaVinci EMAC initialization X-BeenThere: davinci-linux-open-source@linux.davincidsp.com X-Mailman-Version: 2.1.4 Precedence: list List-Id: davinci-linux-open-source.linux.davincidsp.com List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: davinci-linux-open-source-bounces@linux.davincidsp.com Errors-To: davinci-linux-open-source-bounces@linux.davincidsp.com On TI's DA850/OMAP-L138 EVM, MAC address is stored in SPI flash which is accessed using MTD interface. This patch delays the initialization of DaVinci EMAC driver by changing module_init to late_initcall. This helps SPI and MTD drivers to get initialized before EMAC thereby enabling EMAC driver to read the MAC address while booting and use it. Tested with NFS on DM644x, DM6467, DA830/OMAP-L137 and DA850/OMAP-L138 EVMs. Signed-off-by: Sudhakar Rajashekhara Reviewed-by: Chaithrika U S Signed-off-by: Kevin Hilman --- drivers/net/davinci_emac.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/net/davinci_emac.c b/drivers/net/davinci_emac.c index 12fd446..5e6652b 100644 --- a/drivers/net/davinci_emac.c +++ b/drivers/net/davinci_emac.c @@ -2817,7 +2817,7 @@ static int __init davinci_emac_init(void) { return platform_driver_register(&davinci_emac_driver); } -module_init(davinci_emac_init); +late_initcall(davinci_emac_init); /** * davinci_emac_exit: EMAC driver module exit