Specify cmdline property in autogen (vendor_)boot.img

Value of the `--(vendor_)cmdline` is `INTERNAL_KERNEL_CMDLINE` in make.
This is passed as an argument to mkbootimg invocation of boot.img when
vendor_boot.img is not created, and always passed as an argument to
vendor_boot.img.

Test: inspect autogen vendor_boot.img ninja command
Bug: 379945468
Change-Id: Id25d33b970e028c2fe66c73d66c2091a91f56666
diff --git a/fsgen/boot_imgs.go b/fsgen/boot_imgs.go
index 4ccc90a..799dbc9 100644
--- a/fsgen/boot_imgs.go
+++ b/fsgen/boot_imgs.go
@@ -61,6 +61,11 @@
 		dtbPrebuilt = proptools.StringPtr(":" + dtbImg.name)
 	}
 
+	var cmdline []string
+	if !buildingVendorBootImage(partitionVariables) {
+		cmdline = partitionVariables.InternalKernelCmdline
+	}
+
 	ctx.CreateModule(
 		filesystem.BootimgFactory,
 		&filesystem.BootimgProperties{
@@ -74,6 +79,7 @@
 			Avb_algorithm:      avbInfo.avbAlgorithm,
 			Security_patch:     securityPatch,
 			Dtb_prebuilt:       dtbPrebuilt,
+			Cmdline:            cmdline,
 		},
 		&struct {
 			Name *string
@@ -96,6 +102,8 @@
 		dtbPrebuilt = proptools.StringPtr(":" + dtbImg.name)
 	}
 
+	cmdline := partitionVariables.InternalKernelCmdline
+
 	ctx.CreateModule(
 		filesystem.BootimgFactory,
 		&filesystem.BootimgProperties{
@@ -108,6 +116,7 @@
 			Avb_rollback_index: avbInfo.avbRollbackIndex,
 			Avb_algorithm:      avbInfo.avbAlgorithm,
 			Dtb_prebuilt:       dtbPrebuilt,
+			Cmdline:            cmdline,
 		},
 		&struct {
 			Name *string