display: Fix warnings
Treat warnings as errors again
Change-Id: Ibd7f484d31ad420b85e82fd5183d70bf7dce4bfa
diff --git a/libhwcomposer/hwc_ad.cpp b/libhwcomposer/hwc_ad.cpp
index f849450..679e6d6 100644
--- a/libhwcomposer/hwc_ad.cpp
+++ b/libhwcomposer/hwc_ad.cpp
@@ -135,7 +135,7 @@
const hwc_layer_1_t* layer = &list->hwLayers[nYuvIndex];
private_handle_t *hnd = (private_handle_t *)layer->handle;
qdutils::MDPVersion& mdpHw = qdutils::MDPVersion::getInstance();
- if(hnd && hnd->width <= mdpHw.getMaxMixerWidth()) {
+ if(hnd && hnd->width <= (int) mdpHw.getMaxMixerWidth()) {
mDoable = true;
}
}
diff --git a/libhwcomposer/hwc_dump_layers.cpp b/libhwcomposer/hwc_dump_layers.cpp
index c8ebac9..0a92def 100644
--- a/libhwcomposer/hwc_dump_layers.cpp
+++ b/libhwcomposer/hwc_dump_layers.cpp
@@ -37,8 +37,12 @@
#include <sys/stat.h>
#include <comptype.h>
#ifdef QCOM_BSP
+// Ignore Wconversion errors for external headers
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wconversion"
#include <SkBitmap.h>
#include <SkImageEncoder.h>
+#pragma GCC diagnostic pop
#endif
#ifdef STDC_FORMAT_MACROS
#include <inttypes.h>
diff --git a/libhwcomposer/hwc_mdpcomp.cpp b/libhwcomposer/hwc_mdpcomp.cpp
index 08cfbde..072eda3 100644
--- a/libhwcomposer/hwc_mdpcomp.cpp
+++ b/libhwcomposer/hwc_mdpcomp.cpp
@@ -372,7 +372,7 @@
/* On targets that doesnt support Decimation (eg.,8x26)
* maximum downscale support is overlay pipe downscale.
*/
- if(crop_w > mdpHw.getMaxMixerWidth() ||
+ if(crop_w > (int) mdpHw.getMaxMixerWidth() ||
w_dscale > maxMDPDownscale ||
h_dscale > maxMDPDownscale)
return false;
@@ -383,7 +383,7 @@
* 1. Src crop > Mixer limit on nonsplit MDPComp
* 2. exceeds maximum downscale limit
*/
- if(((crop_w > mdpHw.getMaxMixerWidth()) &&
+ if(((crop_w > (int) mdpHw.getMaxMixerWidth()) &&
!sSrcSplitEnabled) ||
w_dscale > maxMDPDownscale ||
h_dscale > maxMDPDownscale) {
@@ -712,7 +712,7 @@
MDPVersion& mdpHw = MDPVersion::getInstance();
if(mDpy > HWC_DISPLAY_PRIMARY &&
- (priDispW > mdpHw.getMaxMixerWidth()) &&
+ (priDispW > (int) mdpHw.getMaxMixerWidth()) &&
(ctx->dpyAttr[mDpy].xres < mdpHw.getMaxMixerWidth())) {
// Disable MDP comp on Secondary when the primary is highres panel and
// the secondary is a normal 1080p, because, MDP comp on secondary under
@@ -2475,8 +2475,8 @@
//pipe line length, we are still using 2 pipes. This is fine just because
//this is source split where destination doesn't matter. Evaluate later to
//see if going through all the calcs to save a pipe is worth it
- if(dstWidth > mdpHw.getMaxMixerWidth() or
- cropWidth > mdpHw.getMaxMixerWidth() or
+ if(dstWidth > (int) mdpHw.getMaxMixerWidth() or
+ cropWidth > (int) mdpHw.getMaxMixerWidth() or
(primarySplitAlways and (cropWidth > lSplit))) {
pipe_info.rIndex = ctx->mOverlay->getPipe(pipeSpecs);
if(pipe_info.rIndex == ovutils::OV_INVALID) {
diff --git a/libhwcomposer/hwc_utils.cpp b/libhwcomposer/hwc_utils.cpp
index a11baa9..03639ee 100644
--- a/libhwcomposer/hwc_utils.cpp
+++ b/libhwcomposer/hwc_utils.cpp
@@ -2309,7 +2309,7 @@
swap(src_w, src_h);
}
//src width > MAX mixer supported dim
- if(src_w > qdutils::MDPVersion::getInstance().getMaxMixerWidth()) {
+ if(src_w > (int) qdutils::MDPVersion::getInstance().getMaxMixerWidth()) {
return;
}
//Decimation necessary, cannot use BWC. H/W requirement.
diff --git a/libhwcomposer/hwc_virtual.cpp b/libhwcomposer/hwc_virtual.cpp
index 146d671..b8be712 100644
--- a/libhwcomposer/hwc_virtual.cpp
+++ b/libhwcomposer/hwc_virtual.cpp
@@ -21,7 +21,6 @@
#include <errno.h>
#include <cutils/log.h>
-#include <utils/Trace.h>
#include <overlayWriteback.h>
#include "hwc_utils.h"
#include "hwc_fbupdate.h"
@@ -30,6 +29,7 @@
#include "hwc_copybit.h"
#include "hwc_virtual.h"
#include "sync/sync.h"
+#include <utils/Trace.h>
#define HWCVIRTUAL_LOG 0