Merge "hwc: Add msm8x09 version checks in HAL."
This commit is contained in:
committed by
Gerrit - the friendly Code Review server
commit
4850bd8a11
@@ -352,7 +352,8 @@ bool CopyBit::prepare(hwc_context_t *ctx, hwc_display_contents_1_t *list,
|
|||||||
}
|
}
|
||||||
|
|
||||||
//Allocate render buffers if they're not allocated
|
//Allocate render buffers if they're not allocated
|
||||||
if (ctx->mMDP.version != qdutils::MDP_V3_0_4 &&
|
if ((ctx->mMDP.version != qdutils::MDP_V3_0_4 &&
|
||||||
|
ctx->mMDP.version != qdutils::MDP_V3_0_5) &&
|
||||||
(useCopybitForYUV || useCopybitForRGB)) {
|
(useCopybitForYUV || useCopybitForRGB)) {
|
||||||
int ret = allocRenderBuffers(mAlignedWidth,
|
int ret = allocRenderBuffers(mAlignedWidth,
|
||||||
mAlignedHeight,
|
mAlignedHeight,
|
||||||
@@ -378,7 +379,8 @@ bool CopyBit::prepare(hwc_context_t *ctx, hwc_display_contents_1_t *list,
|
|||||||
for (int i = ctx->listStats[dpy].numAppLayers-1; i >= 0 ; i--) {
|
for (int i = ctx->listStats[dpy].numAppLayers-1; i >= 0 ; i--) {
|
||||||
layerProp[i].mFlags |= HWC_COPYBIT;
|
layerProp[i].mFlags |= HWC_COPYBIT;
|
||||||
#ifdef QCOM_BSP
|
#ifdef QCOM_BSP
|
||||||
if (ctx->mMDP.version == qdutils::MDP_V3_0_4)
|
if (ctx->mMDP.version == qdutils::MDP_V3_0_4 ||
|
||||||
|
ctx->mMDP.version == qdutils::MDP_V3_0_5)
|
||||||
list->hwLayers[i].compositionType = HWC_BLIT;
|
list->hwLayers[i].compositionType = HWC_BLIT;
|
||||||
else
|
else
|
||||||
#endif
|
#endif
|
||||||
@@ -499,7 +501,8 @@ bool CopyBit::draw(hwc_context_t *ctx, hwc_display_contents_1_t *list,
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
//render buffer
|
//render buffer
|
||||||
if (ctx->mMDP.version == qdutils::MDP_V3_0_4) {
|
if (ctx->mMDP.version == qdutils::MDP_V3_0_4 ||
|
||||||
|
ctx->mMDP.version == qdutils::MDP_V3_0_5) {
|
||||||
last = (uint32_t)list->numHwLayers - 1;
|
last = (uint32_t)list->numHwLayers - 1;
|
||||||
renderBuffer = (private_handle_t *)list->hwLayers[last].handle;
|
renderBuffer = (private_handle_t *)list->hwLayers[last].handle;
|
||||||
} else {
|
} else {
|
||||||
@@ -574,7 +577,8 @@ bool CopyBit::draw(hwc_context_t *ctx, hwc_display_contents_1_t *list,
|
|||||||
copybit_device_t *copybit = getCopyBitDevice();
|
copybit_device_t *copybit = getCopyBitDevice();
|
||||||
// Async mode
|
// Async mode
|
||||||
copybit->flush_get_fence(copybit, fd);
|
copybit->flush_get_fence(copybit, fd);
|
||||||
if(ctx->mMDP.version == qdutils::MDP_V3_0_4 &&
|
if((ctx->mMDP.version == qdutils::MDP_V3_0_4 ||
|
||||||
|
ctx->mMDP.version == qdutils::MDP_V3_0_5) &&
|
||||||
list->hwLayers[last].acquireFenceFd >= 0) {
|
list->hwLayers[last].acquireFenceFd >= 0) {
|
||||||
close(list->hwLayers[last].acquireFenceFd);
|
close(list->hwLayers[last].acquireFenceFd);
|
||||||
list->hwLayers[last].acquireFenceFd = -1;
|
list->hwLayers[last].acquireFenceFd = -1;
|
||||||
|
|||||||
@@ -283,8 +283,10 @@ void initContext(hwc_context_t *ctx)
|
|||||||
// Only MDP copybit is used
|
// Only MDP copybit is used
|
||||||
if ((compositionType & (qdutils::COMPOSITION_TYPE_DYN |
|
if ((compositionType & (qdutils::COMPOSITION_TYPE_DYN |
|
||||||
qdutils::COMPOSITION_TYPE_MDP)) &&
|
qdutils::COMPOSITION_TYPE_MDP)) &&
|
||||||
|
((qdutils::MDPVersion::getInstance().getMDPVersion() ==
|
||||||
|
qdutils::MDP_V3_0_4) ||
|
||||||
(qdutils::MDPVersion::getInstance().getMDPVersion() ==
|
(qdutils::MDPVersion::getInstance().getMDPVersion() ==
|
||||||
qdutils::MDP_V3_0_4)) {
|
qdutils::MDP_V3_0_5))) {
|
||||||
ctx->mCopyBit[HWC_DISPLAY_PRIMARY] = new CopyBit(ctx,
|
ctx->mCopyBit[HWC_DISPLAY_PRIMARY] = new CopyBit(ctx,
|
||||||
HWC_DISPLAY_PRIMARY);
|
HWC_DISPLAY_PRIMARY);
|
||||||
}
|
}
|
||||||
@@ -2189,7 +2191,8 @@ bool canUseRotator(hwc_context_t *ctx, int dpy) {
|
|||||||
if(dpy == HWC_DISPLAY_PRIMARY)
|
if(dpy == HWC_DISPLAY_PRIMARY)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if(ctx->mMDP.version == qdutils::MDP_V3_0_4)
|
if((ctx->mMDP.version == qdutils::MDP_V3_0_4)
|
||||||
|
||(ctx->mMDP.version == qdutils::MDP_V3_0_5))
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (c) 2011-2013, The Linux Foundation. All rights reserved.
|
* Copyright (c) 2011-2014, The Linux Foundation. All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* Redistribution and use in source and binary forms, with or without
|
||||||
* modification, are permitted provided that the following conditions are
|
* modification, are permitted provided that the following conditions are
|
||||||
@@ -387,7 +387,7 @@ int Overlay::initOverlay() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mdpVersion < qdutils::MDSS_V5 && mdpVersion != qdutils::MDP_V3_0_4) {
|
if (mdpVersion < qdutils::MDSS_V5 && mdpVersion > qdutils::MDP_V3_0_5) {
|
||||||
msmfb_mixer_info_req req;
|
msmfb_mixer_info_req req;
|
||||||
mdp_mixer_info *minfo = NULL;
|
mdp_mixer_info *minfo = NULL;
|
||||||
char name[64];
|
char name[64];
|
||||||
|
|||||||
Reference in New Issue
Block a user