]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
board: cssi: Properly initialise MAC address for fibre on CMPC885 board
authorHugo Dubois <hugo.dubois.ext@csgroup.eu>
Tue, 5 Dec 2023 16:10:44 +0000 (17:10 +0100)
committerChristophe Leroy <christophe.leroy@csgroup.eu>
Thu, 18 Apr 2024 13:47:46 +0000 (15:47 +0200)
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 <hugo.dubois.ext@csgroup.eu>
Reviewed-by: CASAUBON Jean Michel <jean-michel.casaubon@csgroup.eu>
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
board/cssi/cmpc885/cmpc885.c

index e11cfafaa5801f14bb3f068c1105be4a82f13dd0..49c13056edcb35af47508e5c6cbfbe097dabfd97 100644 (file)
@@ -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;
 }