From ac3e05c5d757334944fbf1f14583164cd1d69172 Mon Sep 17 00:00:00 2001 From: Mathias Kresin Date: Fri, 7 Apr 2017 18:09:08 +0200 Subject: [PATCH] treewide: populate boardname and model earlier For targets using the generic board detection and board specific settings in diag.sh, the board name is still unset at the time the set_state() provided by diag.sh is called by 10_indicate_preinit. Change the execution order to ensure the boardname is populated before required the first time. Do the target specific board detection as early as possible, directly followed by the generic one to allow a seamless switch to the generic function for populating /tmp/sysinfo/. Signed-off-by: Mathias Kresin --- package/base-files/files/lib/preinit/{10_sysinfo => 02_sysinfo} | 0 .../{05_preinit_do_adm5120.sh => 01_preinit_do_adm5120.sh} | 0 .../{03_preinit_do_apm821xx.sh => 01_preinit_do_apm821xx.sh} | 0 .../preinit/{03_preinit_do_ar71xx.sh => 01_preinit_do_ar71xx.sh} | 0 .../lib/preinit/{03_preinit_do_at91.sh => 01_preinit_do_at91.sh} | 0 .../{03_preinit_do_brcm2708.sh => 01_preinit_do_brcm2708.sh} | 0 .../lib/preinit/{03_do_brcm63xx.sh => 01_do_brcm63xx.sh} | 0 .../{03_preinit_do_ipq806x.sh => 01_preinit_do_ipq806x.sh} | 0 .../lib/preinit/{03_preinit_board.sh => 01_preinit_board.sh} | 0 .../{03_preinit_do_mcs814x.sh => 01_preinit_do_mcs814x.sh} | 0 .../{03_preinit_do_mpc85xx.sh => 01_preinit_do_mpc85xx.sh} | 0 .../lib/preinit/{03_preinit_do_mxs.sh => 01_preinit_do_mxs.sh} | 0 .../octeon/base-files/lib/preinit/{20_sysinfo => 01_sysinfo} | 0 .../preinit/{03_preinit_do_oxnas.sh => 01_preinit_do_oxnas.sh} | 0 .../preinit/{03_preinit_do_ramips.sh => 01_preinit_do_ramips.sh} | 0 .../linux/rb532/base-files/lib/preinit/{10_sysinfo => 01_sysinfo} | 0 .../linux/x86/base-files/lib/preinit/{20_sysinfo => 01_sysinfo} | 0 17 files changed, 0 insertions(+), 0 deletions(-) rename package/base-files/files/lib/preinit/{10_sysinfo => 02_sysinfo} (100%) rename target/linux/adm5120/base-files/lib/preinit/{05_preinit_do_adm5120.sh => 01_preinit_do_adm5120.sh} (100%) rename target/linux/apm821xx/base-files/lib/preinit/{03_preinit_do_apm821xx.sh => 01_preinit_do_apm821xx.sh} (100%) rename target/linux/ar71xx/base-files/lib/preinit/{03_preinit_do_ar71xx.sh => 01_preinit_do_ar71xx.sh} (100%) rename target/linux/at91/base-files/lib/preinit/{03_preinit_do_at91.sh => 01_preinit_do_at91.sh} (100%) rename target/linux/brcm2708/base-files/lib/preinit/{03_preinit_do_brcm2708.sh => 01_preinit_do_brcm2708.sh} (100%) rename target/linux/brcm63xx/base-files/lib/preinit/{03_do_brcm63xx.sh => 01_do_brcm63xx.sh} (100%) rename target/linux/ipq806x/base-files/lib/preinit/{03_preinit_do_ipq806x.sh => 01_preinit_do_ipq806x.sh} (100%) rename target/linux/lantiq/base-files/lib/preinit/{03_preinit_board.sh => 01_preinit_board.sh} (100%) rename target/linux/mcs814x/base-files/lib/preinit/{03_preinit_do_mcs814x.sh => 01_preinit_do_mcs814x.sh} (100%) rename target/linux/mpc85xx/base-files/lib/preinit/{03_preinit_do_mpc85xx.sh => 01_preinit_do_mpc85xx.sh} (100%) rename target/linux/mxs/base-files/lib/preinit/{03_preinit_do_mxs.sh => 01_preinit_do_mxs.sh} (100%) rename target/linux/octeon/base-files/lib/preinit/{20_sysinfo => 01_sysinfo} (100%) rename target/linux/oxnas/base-files/lib/preinit/{03_preinit_do_oxnas.sh => 01_preinit_do_oxnas.sh} (100%) rename target/linux/ramips/base-files/lib/preinit/{03_preinit_do_ramips.sh => 01_preinit_do_ramips.sh} (100%) rename target/linux/rb532/base-files/lib/preinit/{10_sysinfo => 01_sysinfo} (100%) rename target/linux/x86/base-files/lib/preinit/{20_sysinfo => 01_sysinfo} (100%) diff --git a/package/base-files/files/lib/preinit/10_sysinfo b/package/base-files/files/lib/preinit/02_sysinfo similarity index 100% rename from package/base-files/files/lib/preinit/10_sysinfo rename to package/base-files/files/lib/preinit/02_sysinfo diff --git a/target/linux/adm5120/base-files/lib/preinit/05_preinit_do_adm5120.sh b/target/linux/adm5120/base-files/lib/preinit/01_preinit_do_adm5120.sh similarity index 100% rename from target/linux/adm5120/base-files/lib/preinit/05_preinit_do_adm5120.sh rename to target/linux/adm5120/base-files/lib/preinit/01_preinit_do_adm5120.sh diff --git a/target/linux/apm821xx/base-files/lib/preinit/03_preinit_do_apm821xx.sh b/target/linux/apm821xx/base-files/lib/preinit/01_preinit_do_apm821xx.sh similarity index 100% rename from target/linux/apm821xx/base-files/lib/preinit/03_preinit_do_apm821xx.sh rename to target/linux/apm821xx/base-files/lib/preinit/01_preinit_do_apm821xx.sh diff --git a/target/linux/ar71xx/base-files/lib/preinit/03_preinit_do_ar71xx.sh b/target/linux/ar71xx/base-files/lib/preinit/01_preinit_do_ar71xx.sh similarity index 100% rename from target/linux/ar71xx/base-files/lib/preinit/03_preinit_do_ar71xx.sh rename to target/linux/ar71xx/base-files/lib/preinit/01_preinit_do_ar71xx.sh diff --git a/target/linux/at91/base-files/lib/preinit/03_preinit_do_at91.sh b/target/linux/at91/base-files/lib/preinit/01_preinit_do_at91.sh similarity index 100% rename from target/linux/at91/base-files/lib/preinit/03_preinit_do_at91.sh rename to target/linux/at91/base-files/lib/preinit/01_preinit_do_at91.sh diff --git a/target/linux/brcm2708/base-files/lib/preinit/03_preinit_do_brcm2708.sh b/target/linux/brcm2708/base-files/lib/preinit/01_preinit_do_brcm2708.sh similarity index 100% rename from target/linux/brcm2708/base-files/lib/preinit/03_preinit_do_brcm2708.sh rename to target/linux/brcm2708/base-files/lib/preinit/01_preinit_do_brcm2708.sh diff --git a/target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh b/target/linux/brcm63xx/base-files/lib/preinit/01_do_brcm63xx.sh similarity index 100% rename from target/linux/brcm63xx/base-files/lib/preinit/03_do_brcm63xx.sh rename to target/linux/brcm63xx/base-files/lib/preinit/01_do_brcm63xx.sh diff --git a/target/linux/ipq806x/base-files/lib/preinit/03_preinit_do_ipq806x.sh b/target/linux/ipq806x/base-files/lib/preinit/01_preinit_do_ipq806x.sh similarity index 100% rename from target/linux/ipq806x/base-files/lib/preinit/03_preinit_do_ipq806x.sh rename to target/linux/ipq806x/base-files/lib/preinit/01_preinit_do_ipq806x.sh diff --git a/target/linux/lantiq/base-files/lib/preinit/03_preinit_board.sh b/target/linux/lantiq/base-files/lib/preinit/01_preinit_board.sh similarity index 100% rename from target/linux/lantiq/base-files/lib/preinit/03_preinit_board.sh rename to target/linux/lantiq/base-files/lib/preinit/01_preinit_board.sh diff --git a/target/linux/mcs814x/base-files/lib/preinit/03_preinit_do_mcs814x.sh b/target/linux/mcs814x/base-files/lib/preinit/01_preinit_do_mcs814x.sh similarity index 100% rename from target/linux/mcs814x/base-files/lib/preinit/03_preinit_do_mcs814x.sh rename to target/linux/mcs814x/base-files/lib/preinit/01_preinit_do_mcs814x.sh diff --git a/target/linux/mpc85xx/base-files/lib/preinit/03_preinit_do_mpc85xx.sh b/target/linux/mpc85xx/base-files/lib/preinit/01_preinit_do_mpc85xx.sh similarity index 100% rename from target/linux/mpc85xx/base-files/lib/preinit/03_preinit_do_mpc85xx.sh rename to target/linux/mpc85xx/base-files/lib/preinit/01_preinit_do_mpc85xx.sh diff --git a/target/linux/mxs/base-files/lib/preinit/03_preinit_do_mxs.sh b/target/linux/mxs/base-files/lib/preinit/01_preinit_do_mxs.sh similarity index 100% rename from target/linux/mxs/base-files/lib/preinit/03_preinit_do_mxs.sh rename to target/linux/mxs/base-files/lib/preinit/01_preinit_do_mxs.sh diff --git a/target/linux/octeon/base-files/lib/preinit/20_sysinfo b/target/linux/octeon/base-files/lib/preinit/01_sysinfo similarity index 100% rename from target/linux/octeon/base-files/lib/preinit/20_sysinfo rename to target/linux/octeon/base-files/lib/preinit/01_sysinfo diff --git a/target/linux/oxnas/base-files/lib/preinit/03_preinit_do_oxnas.sh b/target/linux/oxnas/base-files/lib/preinit/01_preinit_do_oxnas.sh similarity index 100% rename from target/linux/oxnas/base-files/lib/preinit/03_preinit_do_oxnas.sh rename to target/linux/oxnas/base-files/lib/preinit/01_preinit_do_oxnas.sh diff --git a/target/linux/ramips/base-files/lib/preinit/03_preinit_do_ramips.sh b/target/linux/ramips/base-files/lib/preinit/01_preinit_do_ramips.sh similarity index 100% rename from target/linux/ramips/base-files/lib/preinit/03_preinit_do_ramips.sh rename to target/linux/ramips/base-files/lib/preinit/01_preinit_do_ramips.sh diff --git a/target/linux/rb532/base-files/lib/preinit/10_sysinfo b/target/linux/rb532/base-files/lib/preinit/01_sysinfo similarity index 100% rename from target/linux/rb532/base-files/lib/preinit/10_sysinfo rename to target/linux/rb532/base-files/lib/preinit/01_sysinfo diff --git a/target/linux/x86/base-files/lib/preinit/20_sysinfo b/target/linux/x86/base-files/lib/preinit/01_sysinfo similarity index 100% rename from target/linux/x86/base-files/lib/preinit/20_sysinfo rename to target/linux/x86/base-files/lib/preinit/01_sysinfo