mirror of
https://git.codelinaro.org/clo/qsdk/oss/boot/u-boot-2016.git
synced 2025-12-10 07:44:53 +01:00
pack: Remove flash wifi_fw command
'flash wifi_fw' command writes into flash based on 'rootfs' partition offset. After sysupgrade, flashing single image at u-boot write wifi firmware into failsafe partitions because post sysupgarde primary and failsafe partitions are swapped vice-versa. Single image always boots with primary partitions, and the wifi firmware flashed into failsafe partition won't be loaded subsequently q6 will crash. This patch resolves issue by using "ubi" command's instead of "flash wifi_fw" command. Signed-off-by: Manikanta Mylavarapu <mmanikan@codeaurora.org> Change-Id: I9a89872ade5cbd753272e11fd15e7b8f06d4f92c
This commit is contained in:
parent
ebcbd6d5f6
commit
5ddba484f3
1 changed files with 18 additions and 2 deletions
|
|
@ -760,7 +760,23 @@ class Pack(object):
|
|||
script.start_if_or("machid", machid_list)
|
||||
script.start_activity("Flashing " + fw_filename[:-13] + ":")
|
||||
script.imxtract(fw_filename[:-13] + "-" + sha1(fw_filename))
|
||||
script.append('flash wifi_fw', fatal=False)
|
||||
|
||||
rootfs_info = self.__get_part_info("rootfs")
|
||||
rootfs_offset = rootfs_info.offset
|
||||
rootfs_len = rootfs_info.length
|
||||
|
||||
wifi_fw_cmd = "setenv mtdids nand0=nand0\n"
|
||||
wifi_fw_cmd += "setenv mtdparts mtdparts=nand0:0x%x@0x%x(rootfs)\n" % (rootfs_len,rootfs_offset)
|
||||
wifi_fw_cmd += "ubi part rootfs\n"
|
||||
img_size = self.__get_img_size(fw_filename)
|
||||
wifi_fw_cmd += "ubi write $fileaddr wifi_fw %x" % img_size
|
||||
script.append(wifi_fw_cmd, fatal=False)
|
||||
|
||||
#Enable the below lines for debugging purpose
|
||||
"""
|
||||
script.append("mtdparts", fatal=False)
|
||||
script.append("ubi info layout", fatal=False)
|
||||
"""
|
||||
|
||||
script.finish_activity()
|
||||
script.end_if()
|
||||
|
|
@ -1903,7 +1919,7 @@ class Pack(object):
|
|||
|
||||
its_fp.write(its_data)
|
||||
its_fp.close()
|
||||
|
||||
|
||||
try:
|
||||
cmd = [SRC_DIR + "/mkimage", "-f", self.its_fname, self.img_fname]
|
||||
ret = subprocess.call(cmd)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue