Implement display blank function.

Bug: 37908039
BZ: 51478
Test: netflix, youtube, play movies

Regardless of the early_suspend system call.

Change-Id: Ib72396260b7532482923c33c890573dbfd40aa00
Signed-off-by: Austin Hu <austin.hu@intel.com>
(cherry picked from commit 89ee4ad98fb679a8b69c31b6034c229e05716d5c)
diff --git a/moorefield_hdmi/common/base/Drm.cpp b/moorefield_hdmi/common/base/Drm.cpp
index 3e5138a..e1c7a46 100755
--- a/moorefield_hdmi/common/base/Drm.cpp
+++ b/moorefield_hdmi/common/base/Drm.cpp
@@ -509,6 +509,10 @@
 {
     Mutex::Autolock _l(mLock);
 
+#ifdef INTEL_SUPPORT_HDMI_PRIMARY
+    device = IDisplayDevice::DEVICE_EXTERNAL;
+#endif
+
     int output = getOutputIndex(device);
     if (output < 0 ) {
         return false;
diff --git a/moorefield_hdmi/ips/common/BlankControl.cpp b/moorefield_hdmi/ips/common/BlankControl.cpp
index 53e2bc7..4d7c197 100644
--- a/moorefield_hdmi/ips/common/BlankControl.cpp
+++ b/moorefield_hdmi/ips/common/BlankControl.cpp
@@ -33,10 +33,8 @@
 
 bool BlankControl::blank(int disp, bool blank)
 {
-    // current do nothing but return true
-    // use PM to trigger screen blank/unblank
-    VLOGTRACE("blank is not supported yet, disp %d, blank %d", disp, blank);
-    return true;
+    Drm *drm = Hwcomposer::getInstance().getDrm();
+    return drm->setDpmsMode(disp, !blank);
 }
 
 } // namespace intel