Add additional option as '-ab'.
If it's used, it will be flashed to both A/B partitions.
Otherwise, it will be flashed to A partition by default.
Actaully, some developers don't need to update B partiton.
Change-Id: I584be9e1be388b9f6bc247d105e406dd66d86ec0
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
declare CONV_ASCII=""
declare -i FUS_ENTRY_NUM=0
+declare -i ab_option=0
# binary name | part number | bs | label | fs type
declare -a PART_TABLE=(
}
function fusing_image_to_b () {
+ if [ $ab_option == 0 ] ; then
+ return
+ fi
local -r fusing_img=$1
# get binary info using basename
function show_usage () {
echo "- Usage:"
- echo " sudo ./sd_fusing*.sh -d <device> [-b <path> <path> ..] [--format]"
+ echo " sudo ./sd_fusing*.sh -d <device> [-b <path> <path> ..] [--format] [-ab]"
+ echo " -d : device ndoe "
+ echo " -b : binary "
+ echo " -ab : If want to update Image about B Partition, use -ab option"
}
function check_partition_format () {
binary_option=1
shift
;;
+ -ab)
+ ab_option=1
+ shift
+ ;;
*)
if [ $binary_option == 1 ];then
add_fusing_binary $option