Add vdc checkpoint supportsBlockCheckpoint
Also add vdc checkpoint supportsFileCheckpoint
This is to allow tests to be specific to supported checkpoint mode.
Test: Built on Taimen and Crosshatch, made sure both new functions work
as expected
Change-Id: I0eab7453b13c0a2e31840ef9ad24a692cec55b00
diff --git a/vdc.cpp b/vdc.cpp
index d01fb49..1ec46c8 100644
--- a/vdc.cpp
+++ b/vdc.cpp
@@ -109,6 +109,14 @@
bool supported = false;
checkStatus(vold->supportsCheckpoint(&supported));
return supported ? 1 : 0;
+ } else if (args[0] == "checkpoint" && args[1] == "supportsBlockCheckpoint" && args.size() == 2) {
+ bool supported = false;
+ checkStatus(vold->supportsBlockCheckpoint(&supported));
+ return supported ? 1 : 0;
+ } else if (args[0] == "checkpoint" && args[1] == "supportsFileCheckpoint" && args.size() == 2) {
+ bool supported = false;
+ checkStatus(vold->supportsFileCheckpoint(&supported));
+ return supported ? 1 : 0;
} else if (args[0] == "checkpoint" && args[1] == "startCheckpoint" && args.size() == 3) {
int retry;
if (!android::base::ParseInt(args[2], &retry)) exit(EINVAL);