From patchwork Mon Apr 15 06:07:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Leroy X-Patchwork-Id: 1923567 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=patchwork.ozlabs.org) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4VHxZB31RCz1yXv for ; Mon, 15 Apr 2024 16:08:50 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 93293881FD; Mon, 15 Apr 2024 08:08:14 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=quarantine dis=none) header.from=csgroup.eu Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id C61B388157; Mon, 15 Apr 2024 08:08:12 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from pegase1.c-s.fr (pegase1.c-s.fr [93.17.236.30]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id E1E6A88195 for ; Mon, 15 Apr 2024 08:08:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=quarantine dis=none) header.from=csgroup.eu Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=christophe.leroy@csgroup.eu Received: from localhost (mailhub3.si.c-s.fr [192.168.12.233]) by localhost (Postfix) with ESMTP id 4VHxYQ53CGz9syj; Mon, 15 Apr 2024 08:08:10 +0200 (CEST) Received: from pegase1.c-s.fr ([192.168.12.234]) by localhost (pegase1.c-s.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id WLL_Mi_vMDsF; Mon, 15 Apr 2024 08:08:10 +0200 (CEST) Received: from messagerie.si.c-s.fr (messagerie.si.c-s.fr [192.168.25.192]) by pegase1.c-s.fr (Postfix) with ESMTP id 4VHxYK13Wcz9t2V; Mon, 15 Apr 2024 08:08:05 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 20D568B775; Mon, 15 Apr 2024 08:08:05 +0200 (CEST) Received: from messagerie.si.c-s.fr ([127.0.0.1]) by localhost (messagerie.si.c-s.fr [127.0.0.1]) (amavisd-new, port 10023) with ESMTP id Mfh2RYtYi6uq; Mon, 15 Apr 2024 08:08:05 +0200 (CEST) Received: from PO20335.idsi0.si.c-s.fr (unknown [172.25.230.108]) by messagerie.si.c-s.fr (Postfix) with ESMTP id 001648B770; Mon, 15 Apr 2024 08:08:04 +0200 (CEST) From: Christophe Leroy To: Jagan Teki , Jean-Michel CASAUBON , DUBOIS Hugo , florent.trinh-thai@csgroup.eu, Tom Rini Cc: Christophe Leroy , u-boot@lists.denx.de Subject: [PATCH v2 05/17] board: cssi: Properly initialise MAC address for fibre on CMPC885 board Date: Mon, 15 Apr 2024 08:07:18 +0200 Message-ID: <8fc6016ba367157427ddfc0f332c672e77d90009.1713160866.git.christophe.leroy@csgroup.eu> X-Mailer: git-send-email 2.43.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean From: Hugo Dubois CMPC885 board can be pluged on a mother board with fibre interface, so fibre interface MAC address must be initialised for that case. Signed-off-by: Hugo Dubois Reviewed-by: CASAUBON Jean Michel Signed-off-by: Christophe Leroy --- board/cssi/cmpc885/cmpc885.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/board/cssi/cmpc885/cmpc885.c b/board/cssi/cmpc885/cmpc885.c index e11cfafaa5..49c13056ed 100644 --- a/board/cssi/cmpc885/cmpc885.c +++ b/board/cssi/cmpc885/cmpc885.c @@ -114,8 +114,10 @@ static int setup_mac(void) if (memcmp(din + EE_OFF_MAC1, &ident, sizeof(ident)) == 0) eth_env_set_enetaddr("ethaddr", din + EE_OFF_MAC1); - if (memcmp(din + EE_OFF_MAC2, &ident, sizeof(ident)) == 0) + if (memcmp(din + EE_OFF_MAC2, &ident, sizeof(ident)) == 0) { eth_env_set_enetaddr("eth1addr", din + EE_OFF_MAC2); + eth_env_set_enetaddr("eth2addr", din + EE_OFF_MAC2); + } return 0; }