From patchwork Tue Aug 30 15:51:00 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 112361 X-Patchwork-Delegate: wd@denx.de Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id D2C9CB6F8E for ; Wed, 31 Aug 2011 01:51:27 +1000 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 9F6F4280D1; Tue, 30 Aug 2011 17:51:24 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ym3RrRQMAu4B; Tue, 30 Aug 2011 17:51:23 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id D8D92280AB; Tue, 30 Aug 2011 17:51:21 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 42EBF280AB for ; Tue, 30 Aug 2011 17:51:19 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id m4mA+xNKXurU for ; Tue, 30 Aug 2011 17:51:18 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from smtp-out.google.com (smtp-out.google.com [216.239.44.51]) by theia.denx.de (Postfix) with ESMTPS id 448BE280A7 for ; Tue, 30 Aug 2011 17:51:16 +0200 (CEST) Received: from wpaz29.hot.corp.google.com (wpaz29.hot.corp.google.com [172.24.198.93]) by smtp-out.google.com with ESMTP id p7UFp9ZK008900; Tue, 30 Aug 2011 08:51:09 -0700 Received: from sglass.mtv.corp.google.com (sglass.mtv.corp.google.com [172.22.72.144]) by wpaz29.hot.corp.google.com with ESMTP id p7UFp8gk027429; Tue, 30 Aug 2011 08:51:08 -0700 Received: by sglass.mtv.corp.google.com (Postfix, from userid 121222) id A75C1140B34; Tue, 30 Aug 2011 08:51:07 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Date: Tue, 30 Aug 2011 08:51:00 -0700 Message-Id: <1314719460-27858-1-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.7.3.1 X-System-Of-Record: true Cc: Kumar Gala Subject: [U-Boot] [PATCH] Correct call to eth_write_hwaddr() X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.9 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de This fixes "Warning: failed to set MAC address" on platforms which rely on an 'ethaddr' environment variable to set the MAC address. This bug was introduced by this commit: 7616e785 Add Ethernet hardware MAC address framework to usbnet Signed-off-by: Simon Glass Tested-by: Kumar Gala Tested-by: Michal Simek Tested-by: Heiko Schocher --- net/eth.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/net/eth.c b/net/eth.c index a34fe59..2caaf60 100644 --- a/net/eth.c +++ b/net/eth.c @@ -296,7 +296,7 @@ int eth_initialize(bd_t *bis) if (strchr(dev->name, ' ')) puts("\nWarning: eth device name has a space!\n"); - if (eth_write_hwaddr(dev, NULL, eth_number)) + if (eth_write_hwaddr(dev, "eth", eth_number)) puts("Warning: failed to set MAC address\n"); eth_number++;