arc/network: final fixes

Signed-off-by: AuxXxilium <info@auxxxilium.tech>
This commit is contained in:
AuxXxilium
2024-03-26 20:49:23 +01:00
parent 354a96f590
commit e25b411979
2 changed files with 6 additions and 6 deletions

View File

@@ -126,7 +126,6 @@ function arcModel() {
while true; do
echo -n "" >"${TMP_PATH}/menu"
FLGNEX=0
while read -r M Y; do
PLATFORM=$(readModelKey "${M}" "platform")
DT="$(readModelKey "${M}" "dt")"
@@ -150,13 +149,14 @@ function arcModel() {
for F in "$(readModelArray "${M}" "flags")"; do
if ! grep -q "^flags.*${F}.*" /proc/cpuinfo; then
COMPATIBLE=0
FLGNEX=1
break
fi
done
if [ "${DT}" = "true" ] && [ "${EXTERNALCONTROLLER}" = "true" ]; then
COMPATIBLE=0
FLGNEX=1
fi
if [[ ${SATACONTROLLER} -eq 0 && "${EXTERNALCONTROLLER}" = "false" && "${M}" != "SA6400" ]]; then
COMPATIBLE=0
fi
fi
[ "${DT}" = "true" ] && DTO="DT" || DTO=""

View File

@@ -43,16 +43,16 @@ function getnet() {
2>"${TMP_PATH}/resp"
resp="$(<"${TMP_PATH}/resp")"
[ -z "${resp}" ] && return 1
if [ ${resp} -eq 2 ]; then
if [ ${resp} -eq 1 ]; then
writeConfigKey "arc.macsys" "hardware" "${USER_CONFIG_FILE}"
elif [ ${resp} -eq 3 ]; then
elif [ ${resp} -eq 2 ]; then
writeConfigKey "arc.macsys" "custom" "${USER_CONFIG_FILE}"
fi
else
# Ask for Macsys
dialog --clear --backtitle "$(backtitle)" \
--nocancel --title "Macsys Setting" \
--menu "Choose an Option\n* Recommended Option" 5 50 0 \
--menu "Choose an Option\n* Recommended Option" 4 50 0 \
1 "Hardware - Use Hardware Mac for DSM *" \
2 "Custom - Use Custom Mac for DSM" \
2>"${TMP_PATH}/resp"