From: Oleksij Rempel <o.rempel@pengutronix.de> To: barebox@lists.infradead.org Cc: Robin van der Gracht <robin@protonic.nl>, Oleksij Rempel <o.rempel@pengutronix.de> Subject: [PATCH v1 2/6] ARM: boards: protonic-imx6: Don't fixup MAC address for disabled device Date: Wed, 18 Aug 2021 14:19:41 +0200 Message-ID: <20210818121945.26089-3-o.rempel@pengutronix.de> (raw) In-Reply-To: <20210818121945.26089-1-o.rempel@pengutronix.de> From: Robin van der Gracht <robin@protonic.nl> The prtvt7 board variant has no enabled ethernet interface. For these boards the MAC address in the RFID flash is unset or invalid and should not be copied to the device-tree. Signed-off-by: Robin van der Gracht <robin@protonic.nl> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de> --- arch/arm/boards/protonic-imx6/board.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boards/protonic-imx6/board.c b/arch/arm/boards/protonic-imx6/board.c index e7938ac0fd..7368f3458f 100644 --- a/arch/arm/boards/protonic-imx6/board.c +++ b/arch/arm/boards/protonic-imx6/board.c @@ -171,6 +171,9 @@ static int prt_imx6_set_mac(struct prt_imx6_priv *priv, return -ENODEV; } + if (!of_device_is_available(node)) + return 0; + if (!is_valid_ether_addr(&rfid->mac[0])) { unsigned char ethaddr_str[sizeof("xx:xx:xx:xx:xx:xx")]; -- 2.30.2 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2021-08-18 12:22 UTC|newest] Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-08-18 12:19 [PATCH v1 0/6] protonic: fix and maintaining Oleksij Rempel 2021-08-18 12:19 ` [PATCH v1 1/6] ARM: boards: protonic-imx6: Run usb boot entry instead of bare device Oleksij Rempel 2021-08-18 12:19 ` Oleksij Rempel [this message] 2021-08-18 12:19 ` [PATCH v1 3/6] ARM: dts: imx6dl-prtvt7: Add brand state variable Oleksij Rempel 2021-08-18 12:19 ` [PATCH v1 4/6] ARM: boards: protonic-imx6: Don't register SD with bbu Oleksij Rempel 2021-08-18 12:19 ` [PATCH v1 5/6] ARM: boards: protonic-imx6: Add emmc_usdhc machine data variable Oleksij Rempel 2021-08-18 12:19 ` [PATCH v1 6/6] ARM: boards: protonic-imx6: Enable bootchooser on prti6g board Oleksij Rempel 2021-08-23 13:45 ` [PATCH v1 0/6] protonic: fix and maintaining Sascha Hauer
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20210818121945.26089-3-o.rempel@pengutronix.de \ --to=o.rempel@pengutronix.de \ --cc=barebox@lists.infradead.org \ --cc=robin@protonic.nl \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
mail archive of the barebox mailing list This inbox may be cloned and mirrored by anyone: git clone --mirror https://lore.barebox.org/barebox/0 barebox/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 barebox barebox/ https://lore.barebox.org/barebox \ barebox@lists.infradead.org barebox@lists.infradead.org public-inbox-index barebox Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git