From patchwork Sun Feb 22 14:17:14 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudio Leite X-Patchwork-Id: 442283 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 697CE14010F for ; Mon, 23 Feb 2015 01:17:36 +1100 (AEDT) Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id D043128B9A9; Sun, 22 Feb 2015 15:17:19 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00 autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 2C6EC28A248 for ; Sun, 22 Feb 2015 15:17:14 +0100 (CET) X-policyd-weight: using cached result; rate: -5.5 Received: from smtp.rcn.com (smtp.rcn.com [69.168.97.78]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Sun, 22 Feb 2015 15:17:13 +0100 (CET) X_CMAE_Category: , , X-CNFS-Analysis: v=2.0 cv=WrupwKjv c=1 sm=1 a=GuteYBN2S9jz87ZyP3BHnQ==:17 a=8ndMLmUfAAAA:8 a=ZCU1GlyK6J6YcoIyeyIA:9 a=GuteYBN2S9jz87ZyP3BHnQ==:117 X-CM-Score: 0 X-Scanned-by: Cloudmark Authority Engine X-Authed-Username: bGVpdGVjQHN0YXRpY2t5LmNvbQ== Authentication-Results: smtp02.rcn.cmh.synacor.com header.from=leitec@staticky.com; sender-id=neutral Authentication-Results: smtp02.rcn.cmh.synacor.com smtp.mail=leitec@staticky.com; spf=neutral; sender-id=neutral Received-SPF: neutral (smtp02.rcn.cmh.synacor.com: 208.58.65.14 is neither permitted nor denied by domain of staticky.com) Received: from [208.58.65.14] ([208.58.65.14:55014] helo=dirk.lan.staticky.com) by smtp.rcn.com (envelope-from ) (ecelerity 3.6.2.43620 r(Platform:3.6.2.0)) with ESMTP id 12/1D-17396-FE4E9E45; Sun, 22 Feb 2015 09:17:19 -0500 From: Claudio Leite To: openwrt-devel@lists.openwrt.org Date: Sun, 22 Feb 2015 09:17:14 -0500 Message-Id: <1424614634-9847-1-git-send-email-leitec@staticky.com> X-Mailer: git-send-email 2.1.4 Subject: [OpenWrt-Devel] [PATCH v2] mvebu: set WRT1900AC WAN interface MAC address X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" Toggles the LA bit on the WAN interface. Signed-off-by: Claudio Leite --- target/linux/mvebu/base-files/lib/preinit/06_set_iface_mac | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/target/linux/mvebu/base-files/lib/preinit/06_set_iface_mac b/target/linux/mvebu/base-files/lib/preinit/06_set_iface_mac index 30f1370..2b64eda 100644 --- a/target/linux/mvebu/base-files/lib/preinit/06_set_iface_mac +++ b/target/linux/mvebu/base-files/lib/preinit/06_set_iface_mac @@ -11,8 +11,9 @@ preinit_set_mac_address() { case $(mvebu_board_name) in armada-xp-mamba) mac=$(mtd_get_mac_ascii devinfo hw_mac_addr) + mac_wan=$(macaddr_setbit_la "$mac") ifconfig eth0 hw ether $mac 2>/dev/null - ifconfig eth1 hw ether $mac 2>/dev/null + ifconfig eth1 hw ether $mac_wan 2>/dev/null ;; esac }