From a10768df3242eadbdffb7feefe36828238b55996 Mon Sep 17 00:00:00 2001 From: Igor Pecovnik Date: Mon, 17 Jun 2024 23:01:22 +0200 Subject: [PATCH] Odroid M1: add a network rule to rename default name --- config/boards/odroidm1.conf | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/config/boards/odroidm1.conf b/config/boards/odroidm1.conf index 087f73bbd52c..8635cb97051a 100644 --- a/config/boards/odroidm1.conf +++ b/config/boards/odroidm1.conf @@ -77,4 +77,12 @@ function post_family_tweaks__config_odroidm1_fwenv() { # MTD device name Device offset Env. size Flash sector size Number of sectors /dev/mtd1 0x0000 0x20000 FW_ENV_CONFIG + + # add a network rule to rename default name + display_alert "Creating network rename rule for Odroid M1" + mkdir -p "${SDCARD}"/etc/udev/rules.d/ + cat <<- EOF > "${SDCARD}"/etc/udev/rules.d/70-rename-lan.rules + SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", KERNEL=="end*", NAME="eth0" + EOF + }