blob: c54617b7e8833f64c8ae6ac1148c14a80f65834c [file] [log] [blame]
Jun Yu99998802015-10-30 18:44:26 -07001#!/bin/sh
2
3# Copyright (C) 2015. Marvell International Ltd
4#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16
Dan Shia41b8152016-01-14 15:47:28 -080017OS=${ANDROID_PROVISION_OS_PARTITIONS:-${ANDROID_PRODUCT_OUT}}
18VENDOR=${ANDROID_PROVISION_VENDOR_PARTITIONS:-${ANDROID_BUILD_TOP}/vendor/bsp/marvell/device/abox_edge}
19
Jun Yua09e4432015-11-06 15:42:42 -080020# Marvell A/B Boot Provision Script
Jun Yu99998802015-10-30 18:44:26 -070021fastboot \
Dan Shia41b8152016-01-14 15:47:28 -080022 flash partition ${VENDOR}/bin/primary_gpt \
23 flash misc ${VENDOR}/bin/misc.bin \
Jun Yu99998802015-10-30 18:44:26 -070024 erase pbootloader \
Dan Shia41b8152016-01-14 15:47:28 -080025 flash pbootloader ${VENDOR}/bootloader/u-boot.bin \
Jun Yu99998802015-10-30 18:44:26 -070026 erase rbootloader \
Dan Shia41b8152016-01-14 15:47:28 -080027 flash rbootloader ${VENDOR}/bootloader/u-boot.bin \
28 flash boot_a ${OS}/boot.img \
29 flash system_a ${OS}/system.img \
30 flash boot_b ${OS}/boot.img \
31 flash system_b ${OS}/system.img \
32 flash userdata ${OS}/userdata.img \
33 flash cache ${OS}/cache.img \
li gang7edb6df2016-01-21 00:15:24 -080034 flash secure ${VENDOR}/bootloader/teesst.img \
zhxihu51a515d2015-11-24 03:55:03 -080035 --set-active=_a "$@"