diff options
| author | Dhaval Patel <pdhaval@quicinc.com> | 2016-09-27 17:54:52 -0700 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2016-09-27 17:54:52 -0700 |
| commit | 8501c7460fdef855be63f0b60aab05e9902bb23a (patch) | |
| tree | cfb70cb2bda206d2411fe8172ddbbdb847a85d98 /drivers | |
| parent | faf1c485f7f8a629c0acbe01b12aa9a02f37b7fe (diff) | |
| parent | 31401d3de9c83b356d616ce07eac7435aeb293f5 (diff) | |
Merge "drm/msm/sde: use const alpha for wb if pipe alpha not supported" into dev/msm-4.4-drm_kms
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/gpu/drm/msm/sde/sde_hw_catalog.h | 2 | ||||
| -rw-r--r-- | drivers/gpu/drm/msm/sde/sde_hw_wb.c | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/msm/sde/sde_hw_catalog.h b/drivers/gpu/drm/msm/sde/sde_hw_catalog.h index 85aa6b671258..91e7b90cbc76 100644 --- a/drivers/gpu/drm/msm/sde/sde_hw_catalog.h +++ b/drivers/gpu/drm/msm/sde/sde_hw_catalog.h @@ -174,6 +174,7 @@ enum { * support * @SDE_WB_WBWC_1_5 UBWC 1.5 support * @SDE_WB_YUV_CONFIG Writeback supports output of YUV colorspace + * @SDE_WB_PIPE_ALPHA Writeback supports pipe alpha * @SDE_WB_MAX maximum value */ enum { @@ -187,6 +188,7 @@ enum { SDE_WB_TRAFFIC_SHAPER, SDE_WB_UBWC_1_0, SDE_WB_YUV_CONFIG, + SDE_WB_PIPE_ALPHA, SDE_WB_MAX }; diff --git a/drivers/gpu/drm/msm/sde/sde_hw_wb.c b/drivers/gpu/drm/msm/sde/sde_hw_wb.c index a776d5538d83..60141dcf9be5 100644 --- a/drivers/gpu/drm/msm/sde/sde_hw_wb.c +++ b/drivers/gpu/drm/msm/sde/sde_hw_wb.c @@ -96,7 +96,8 @@ static void sde_hw_wb_setup_format(struct sde_hw_wb *ctx, if (fmt->bits[C3_ALPHA] || fmt->alpha_enable) { dst_format |= BIT(8); /* DSTC3_EN */ - if (!fmt->alpha_enable) + if (!fmt->alpha_enable || + !(ctx->caps->features & BIT(SDE_WB_PIPE_ALPHA))) dst_format |= BIT(14); /* DST_ALPHA_X */ } |
