aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files
diff options
context:
space:
mode:
authorDaniel Golle <daniel@makrotopia.org>2021-02-24 11:40:50 +0000
committerDaniel Golle <daniel@makrotopia.org>2021-02-24 11:42:02 +0000
commit287bd78e6f8af68fc3095839c7b70842cf3ddb4c (patch)
treeafe5b2b279b13f386430bc5ff267eb94bd9e1c9f /package/base-files
parentce8b535ed3aea743f58d8445dfaa1c2ced375f94 (diff)
downloadupstream-287bd78e6f8af68fc3095839c7b70842cf3ddb4c.tar.gz
upstream-287bd78e6f8af68fc3095839c7b70842cf3ddb4c.tar.bz2
upstream-287bd78e6f8af68fc3095839c7b70842cf3ddb4c.zip
base-files: remove unneeded '$' signs in nand.sh
When using Shell arithmetric evaluation via $((..)) the variables in the expression do not need to be prefixed by the '$' sign. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
Diffstat (limited to 'package/base-files')
-rw-r--r--package/base-files/files/lib/upgrade/nand.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/package/base-files/files/lib/upgrade/nand.sh b/package/base-files/files/lib/upgrade/nand.sh
index 2b766480d7..faeb3d6fc1 100644
--- a/package/base-files/files/lib/upgrade/nand.sh
+++ b/package/base-files/files/lib/upgrade/nand.sh
@@ -118,7 +118,7 @@ nand_upgrade_prepare_ubi() {
local rootfs_length="$1"
local rootfs_type="$2"
local rootfs_data_max="$(fw_printenv -n rootfs_data_max 2>/dev/null)"
- [ -n "$rootfs_data_max" ] && rootfs_data_max=$(($rootfs_data_max))
+ [ -n "$rootfs_data_max" ] && rootfs_data_max=$((rootfs_data_max))
local kernel_length="$3"
local has_env="${4:-0}"
@@ -195,7 +195,7 @@ nand_upgrade_prepare_ubi() {
if [ "$rootfs_type" != "ubifs" ]; then
local availeb=$(cat /sys/devices/virtual/ubi/$ubidev/avail_eraseblocks)
local ebsize=$(cat /sys/devices/virtual/ubi/$ubidev/eraseblock_size)
- local avail_size=$(( $availeb * $ebsize ))
+ local avail_size=$((availeb * ebsize))
local rootfs_data_size_param="-m"
if [ -n "$rootfs_data_max" ] &&
[ "$rootfs_data_max" != "0" ] &&