Revert "Add modules partition."

Revert submission 1413808-modules_partition

Reason for revert: modules partition no longer needed
Reverted Changes:
Iceafebd85:Add modules partition
I2fa96199a:rootdir: Add modules directory
Ie397b9ec6:Add modules partition.
I4200d0cf5:fastboot: add modules partition

Bug: 163543381

Change-Id: Iec1d9421bbfeb114fb705f85d910c6def1f211b6
This commit is contained in:
Yifan Hong
2020-09-15 19:07:39 +00:00
parent c0f187f5f9
commit c08cbf0f4a
10 changed files with 5 additions and 225 deletions

View File

@@ -296,7 +296,6 @@ def AddVendorDlkm(output_zip):
block_list=block_list)
return img.name
def AddOdmDlkm(output_zip):
"""Turn the contents of OdmDlkm into an odm_dlkm image and store it in output_zip."""
@@ -313,22 +312,6 @@ def AddOdmDlkm(output_zip):
return img.name
def AddModules(output_zip):
"""Turn the contents of Modules into an modules image and store it in output_zip."""
img = OutputFile(output_zip, OPTIONS.input_tmp, "IMAGES", "modules.img")
if os.path.exists(img.name):
logger.info("modules.img already exists; no need to rebuild...")
return img.name
block_list = OutputFile(
output_zip, OPTIONS.input_tmp, "IMAGES", "modules.map")
CreateImage(
OPTIONS.input_tmp, OPTIONS.info_dict, "modules", img,
block_list=block_list)
return img.name
def AddDtbo(output_zip):
"""Adds the DTBO image.
@@ -437,9 +420,7 @@ def CreateImage(input_dir, info_dict, what, output_file, block_list=None):
# Use repeatable ext4 FS UUID and hash_seed UUID (based on partition name and
# build fingerprint).
build_info = common.BuildInfo(info_dict)
uuid_seed = what
if what != "modules":
uuid_seed += "-" + build_info.GetPartitionFingerprint(what)
uuid_seed = what + "-" + build_info.GetPartitionFingerprint(what)
image_props["uuid"] = str(uuid.uuid5(uuid.NAMESPACE_URL, uuid_seed))
hash_seed = "hash_seed-" + uuid_seed
image_props["hash_seed"] = str(uuid.uuid5(uuid.NAMESPACE_URL, hash_seed))
@@ -817,12 +798,6 @@ def AddImagesToTargetFiles(filename):
OPTIONS.info_dict.get("building_product_image") == "true") or
os.path.exists(
os.path.join(OPTIONS.input_tmp, "IMAGES", "product.img")))
has_modules = ((os.path.isdir(os.path.join(OPTIONS.input_tmp,
"MODULES")) and
OPTIONS.info_dict.get("building_modules_image")
== "true") or
os.path.exists(os.path.join(OPTIONS.input_tmp, "IMAGES",
"modules.img")))
has_system_ext = (
(os.path.isdir(os.path.join(OPTIONS.input_tmp, "SYSTEM_EXT")) and
OPTIONS.info_dict.get("building_system_ext_image") == "true") or
@@ -952,10 +927,6 @@ def AddImagesToTargetFiles(filename):
banner("odm_dlkm")
partitions['odm_dlkm'] = AddOdmDlkm(output_zip)
if has_modules:
banner("modules")
partitions['modules'] = AddModules(output_zip)
if has_system_other:
banner("system_other")
AddSystemOther(output_zip)