vold: implement resetCheckpoint

It will be used by userspace reboot to reset checkpoint state, to make
sure that when /data is remounted, it will be remounted in checkpointing
if a checkpoint was requested beforee userspace reboot.

Test: /system/bin/vdc startCheckpoint 1
      /system/bin/vdc needsCheckpoint (returns 0)
      /system/bin/vdc resetCheckpoint
      /system/bin/vdc needsCheckpoint (returns 1)

Bug: 135984674
Change-Id: Ia29238686289b4eed93e2fb936a8b3d894b94dc9
diff --git a/VoldNativeService.cpp b/VoldNativeService.cpp
index 7f7f289..0afbab9 100644
--- a/VoldNativeService.cpp
+++ b/VoldNativeService.cpp
@@ -907,5 +907,13 @@
     return cp_supportsFileCheckpoint(*_aidl_return);
 }
 
+binder::Status VoldNativeService::resetCheckpoint() {
+    ENFORCE_UID(AID_SYSTEM);
+    ACQUIRE_LOCK;
+
+    cp_resetCheckpoint();
+    return ok();
+}
+
 }  // namespace vold
 }  // namespace android