partitionmanager: Symlink dynamic partitions to /dev/block/boot/device/by-name/
Signed-off-by: Mohd Faraz <androiabledroid@gmail.com>
Change-Id: Iebebe9234723bcda863098cdff6ed41e7b410e78
diff --git a/partitionmanager.cpp b/partitionmanager.cpp
index a4652c6..852209b 100755
--- a/partitionmanager.cpp
+++ b/partitionmanager.cpp
@@ -3341,6 +3341,9 @@
twrpPart->Change_Mount_Read_Only(true);
twrpPart->Set_Can_Be_Backed_Up(false);
twrpPart->Set_Can_Be_Wiped(false);
+ LOGINFO("Symlinking %s => /dev/block/bootdevice/by-name/%s \n", fstabEntry.blk_device.c_str(), bare_partition_name.c_str());
+ symlink(fstabEntry.blk_device.c_str(), ("/dev/block/bootdevice/by-name/" + bare_partition_name).c_str());
+
return true;
}