mirror of
https://github.com/RROrg/rr.git
synced 2025-06-21 05:51:05 +08:00
新增 usbasinternal 配置项
This commit is contained in:
parent
3ab7cdd3d3
commit
523257ef27
@ -104,6 +104,7 @@ SN="$(readConfigKey "sn" "${USER_CONFIG_FILE}")"
|
||||
MAC1="$(readConfigKey "mac1" "${USER_CONFIG_FILE}")"
|
||||
MAC2="$(readConfigKey "mac2" "${USER_CONFIG_FILE}")"
|
||||
KERNELPANIC="$(readConfigKey "kernelpanic" "${USER_CONFIG_FILE}")"
|
||||
USBASINTERNAL="$(readConfigKey "usbasinternal" "${USER_CONFIG_FILE}")"
|
||||
EMMCBOOT="$(readConfigKey "emmcboot" "${USER_CONFIG_FILE}")"
|
||||
MODBLACKLIST="$(readConfigKey "modblacklist" "${USER_CONFIG_FILE}")"
|
||||
|
||||
@ -182,6 +183,10 @@ CMDLINE['pcie_aspm']="off"
|
||||
CMDLINE['modprobe.blacklist']="${MODBLACKLIST}"
|
||||
CMDLINE['mev']="${MEV:-physical}"
|
||||
|
||||
if [ "${USBASINTERNAL}" = "true" ]; then
|
||||
CMDLINE['usbasinternal']=""
|
||||
fi
|
||||
|
||||
if echo "apollolake geminilake purley" | grep -wq "${PLATFORM}"; then
|
||||
CMDLINE["nox2apic"]=""
|
||||
fi
|
||||
|
@ -44,6 +44,7 @@ initConfigKey "kernelway" "power" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "kernelpanic" "5" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "odp" "false" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "hddsort" "false" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "usbasinternal" "false" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "emmcboot" "false" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "platform" "" "${USER_CONFIG_FILE}"
|
||||
initConfigKey "model" "" "${USER_CONFIG_FILE}"
|
||||
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -57,6 +57,7 @@ KERNELWAY="$(readConfigKey "kernelway" "${USER_CONFIG_FILE}")"
|
||||
KERNELPANIC="$(readConfigKey "kernelpanic" "${USER_CONFIG_FILE}")"
|
||||
ODP="$(readConfigKey "odp" "${USER_CONFIG_FILE}")" # official drivers priorities
|
||||
HDDSORT="$(readConfigKey "hddsort" "${USER_CONFIG_FILE}")"
|
||||
USBASINTERNAL="$(readConfigKey "usbasinternal" "${USER_CONFIG_FILE}")"
|
||||
EMMCBOOT="$(readConfigKey "emmcboot" "${USER_CONFIG_FILE}")"
|
||||
SN="$(readConfigKey "sn" "${USER_CONFIG_FILE}")"
|
||||
MAC1="$(readConfigKey "mac1" "${USER_CONFIG_FILE}")"
|
||||
@ -339,6 +340,11 @@ function productversMenu() {
|
||||
KERNEL='official'
|
||||
writeConfigKey "kernel" "${KERNEL}" "${USER_CONFIG_FILE}"
|
||||
fi
|
||||
# Check usbasinternal
|
||||
if [ "true" = "$(readConfigKey "platforms.${PLATFORM}.dt" "${WORK_PATH}/platforms.yml")" ]; then
|
||||
USBASINTERNAL='false'
|
||||
writeConfigKey "usbasinternal" "${USBASINTERNAL}" "${USER_CONFIG_FILE}"
|
||||
fi
|
||||
# Check addons
|
||||
while IFS=': ' read -r ADDON PARAM; do
|
||||
[ -z "${ADDON}" ] && continue
|
||||
@ -2894,8 +2900,9 @@ function advancedMenu() {
|
||||
echo "p \"$(TEXT "Show/modify the current pat data")\""
|
||||
echo "m \"$(TEXT "Switch SATADOM mode:") \Z4${SATADOM}\Zn\""
|
||||
fi
|
||||
if [ -n "${PLATFORM}" ] && [ "true" = "$(readConfigKey "platforms.${PLATFORM}.dt" "${WORK_PATH}/platforms.yml")" ]; then
|
||||
if [ -n "${PLATFORM}" ]; then
|
||||
echo "d \"$(TEXT "Custom DTS")\""
|
||||
echo "u \"$(TEXT "USB disk as internal disk:") \Z4${USBASINTERNAL}\Zn\""
|
||||
fi
|
||||
echo "w \"$(TEXT "Timeout of boot wait:") \Z4${BOOTWAIT}\Zn\""
|
||||
if [ "${DIRECTBOOT}" = "false" ]; then
|
||||
@ -2983,9 +2990,25 @@ function advancedMenu() {
|
||||
NEXT="m"
|
||||
;;
|
||||
d)
|
||||
customDTS
|
||||
if [ "true" = "$(readConfigKey "platforms.${PLATFORM}.dt" "${WORK_PATH}/platforms.yml")" ]; then
|
||||
customDTS
|
||||
else
|
||||
DIALOG --title "$(TEXT "Advanced")" \
|
||||
--msgbox "$(TEXT "Custom DTS is not supported for current model.")" 0 0
|
||||
fi
|
||||
NEXT="e"
|
||||
;;
|
||||
u)
|
||||
if [ "true" = "$(readConfigKey "platforms.${PLATFORM}.dt" "${WORK_PATH}/platforms.yml")" ]; then
|
||||
DIALOG --title "$(TEXT "Advanced")" \
|
||||
--msgbox "$(TEXT "USB disk as internal disk is not supported for current model.")" 0 0
|
||||
NEXT="e"
|
||||
else
|
||||
USBASINTERNAL=$([ "${USBASINTERNAL}" = "true" ] && echo 'false' || echo 'true')
|
||||
writeConfigKey "usbasinternal" "${USBASINTERNAL}" "${USER_CONFIG_FILE}"
|
||||
NEXT="u"
|
||||
fi
|
||||
;;
|
||||
w)
|
||||
ITEMS="$(echo -e "1 \n5 \n10 \n30 \n60 \n")"
|
||||
DIALOG --title "$(TEXT "Advanced")" \
|
||||
|
Loading…
x
Reference in New Issue
Block a user