BootControl exposes DynamicPartitionControl.

Add BootControlInterface::GetDynamicPartitionControl, which
exposes the internal DynamicPartitionControlInterface object.

BootControlStub / FakeBootControl / BootControlChromeOS uses
DynamicPartitionControlStub (all functions succeeds).

BootControlAndroid uses DynamicPartitionControlAndroid.
GetPartitionDevice is exposed so that BootControlAndroid can use it.

Follow-up CLs delete duplicated PreparePartitionsForUpdate
and Cleanup from BootControlInterface so that BootControlAndroid remains
a thin wrapper of the HAL (+GetPartitionDevice, which exists before
dynamic partitions.)

Test: update_engine_unittests

Change-Id: Ifc2aa2ee8a63ef581c8ebc562ec158794ac51dfd
diff --git a/boot_control_chromeos.h b/boot_control_chromeos.h
index 29841c9..9519fb7 100644
--- a/boot_control_chromeos.h
+++ b/boot_control_chromeos.h
@@ -17,12 +17,14 @@
 #ifndef UPDATE_ENGINE_BOOT_CONTROL_CHROMEOS_H_
 #define UPDATE_ENGINE_BOOT_CONTROL_CHROMEOS_H_
 
+#include <memory>
 #include <string>
 
 #include <base/callback.h>
 #include <gtest/gtest_prod.h>  // for FRIEND_TEST
 
 #include "update_engine/common/boot_control_interface.h"
+#include "update_engine/common/dynamic_partition_control_interface.h"
 
 namespace chromeos_update_engine {
 
@@ -54,6 +56,7 @@
                                   const DeltaArchiveManifest& manifest,
                                   bool update_metadata) override;
   void Cleanup() override;
+  DynamicPartitionControlInterface* GetDynamicPartitionControl() override;
 
  private:
   friend class BootControlChromeOSTest;
@@ -81,6 +84,8 @@
   // The block device of the disk we booted from, without the partition number.
   std::string boot_disk_name_;
 
+  std::unique_ptr<DynamicPartitionControlInterface> dynamic_partition_control_;
+
   DISALLOW_COPY_AND_ASSIGN(BootControlChromeOS);
 };