summaryrefslogtreecommitdiff
path: root/fsgen/filesystem_creator.go
diff options
context:
space:
mode:
author Jihoon Kang <jihoonkang@google.com> 2024-11-26 23:11:07 +0000
committer Jihoon Kang <jihoonkang@google.com> 2024-11-26 23:13:05 +0000
commita8fa07111598a537d401332c82f110f9fa209275 (patch)
tree293accfa9fd43e7a2a5495f8975fd77a2b97f0c3 /fsgen/filesystem_creator.go
parent60c23299f02ab9268c7957dc9315fe79f7a8b23b (diff)
Create prebuilt kernel module for vendor_ramdisk partition
To correctly install *.ko files to the vendor_ramdisk partition. Test: m soong_generated_vendor_ramdisk_filesystem_test Bug: 381104942 Change-Id: Ib058a0f6893eaa273dfd609749a6417982cf057e
Diffstat (limited to 'fsgen/filesystem_creator.go')
-rw-r--r--fsgen/filesystem_creator.go9
1 files changed, 8 insertions, 1 deletions
diff --git a/fsgen/filesystem_creator.go b/fsgen/filesystem_creator.go
index e8b0a4fb7..edf7d8672 100644
--- a/fsgen/filesystem_creator.go
+++ b/fsgen/filesystem_creator.go
@@ -321,7 +321,7 @@ func (f *filesystemCreator) createPartition(ctx android.LoadHookContext, partiti
}
}
- if android.InList(partitionType, dlkmPartitions) {
+ if android.InList(partitionType, append(dlkmPartitions, "vendor_ramdisk")) {
f.createPrebuiltKernelModules(ctx, partitionType)
}
@@ -398,6 +398,7 @@ func (f *filesystemCreator) createPrebuiltKernelModules(ctx android.LoadHookCont
System_dlkm_specific *bool
Vendor_dlkm_specific *bool
Odm_dlkm_specific *bool
+ Vendor_ramdisk *bool
Load_by_default *bool
Blocklist_file *string
}{
@@ -430,6 +431,12 @@ func (f *filesystemCreator) createPrebuiltKernelModules(ctx android.LoadHookCont
if blocklistFile := ctx.Config().ProductVariables().PartitionVarsForSoongMigrationOnlyDoNotUse.OdmKernelBlocklistFile; blocklistFile != "" {
props.Blocklist_file = proptools.StringPtr(blocklistFile)
}
+ case "vendor_ramdisk":
+ props.Srcs = android.ExistentPathsForSources(ctx, ctx.Config().ProductVariables().PartitionVarsForSoongMigrationOnlyDoNotUse.VendorRamdiskKernelModules).Strings()
+ props.Vendor_ramdisk = proptools.BoolPtr(true)
+ if blocklistFile := ctx.Config().ProductVariables().PartitionVarsForSoongMigrationOnlyDoNotUse.VendorRamdiskKernelBlocklistFile; blocklistFile != "" {
+ props.Blocklist_file = proptools.StringPtr(blocklistFile)
+ }
default:
ctx.ModuleErrorf("DLKM is not supported for %s\n", partitionType)
}