Merge "msm: mdss: Fix scaler enable flag setting"
This commit is contained in:
commit
21fb3a4b62
2 changed files with 11 additions and 4 deletions
|
@ -4258,6 +4258,7 @@ static void __mdss_fb_copy_pixel_ext(struct mdp_scale_data *src,
|
|||
{
|
||||
if (!src || !dest)
|
||||
return;
|
||||
dest->enable = true;
|
||||
memcpy(dest->init_phase_x, src->init_phase_x,
|
||||
sizeof(src->init_phase_x));
|
||||
memcpy(dest->phase_step_x, src->phase_step_x,
|
||||
|
|
|
@ -1040,7 +1040,6 @@ static int __configure_pipe_params(struct msm_fb_data_type *mfd,
|
|||
if (layer->flags & MDP_LAYER_SECURE_CAMERA_SESSION)
|
||||
pipe->flags |= MDP_SECURE_CAMERA_OVERLAY_SESSION;
|
||||
|
||||
pipe->scaler.enable = (layer->flags & SCALER_ENABLED);
|
||||
pipe->is_fg = layer->flags & MDP_LAYER_FORGROUND;
|
||||
pipe->img_width = layer->buffer.width & 0x3fff;
|
||||
pipe->img_height = layer->buffer.height & 0x3fff;
|
||||
|
@ -1073,6 +1072,16 @@ static int __configure_pipe_params(struct msm_fb_data_type *mfd,
|
|||
pipe->src.x, pipe->src.y, pipe->src.w, pipe->src.h,
|
||||
pipe->dst.x, pipe->dst.y, pipe->dst.w, pipe->dst.h);
|
||||
|
||||
if (layer->flags & SCALER_ENABLED) {
|
||||
memcpy(&pipe->scaler, layer->scale,
|
||||
sizeof(struct mdp_scale_data_v2));
|
||||
/* Sanitize enable flag */
|
||||
pipe->scaler.enable &= (ENABLE_SCALE | ENABLE_DETAIL_ENHANCE |
|
||||
ENABLE_DIRECTION_DETECTION);
|
||||
} else {
|
||||
pipe->scaler.enable = 0;
|
||||
}
|
||||
|
||||
flags = pipe->flags;
|
||||
if (is_single_layer)
|
||||
flags |= PERF_CALC_PIPE_SINGLE_LAYER;
|
||||
|
@ -1195,9 +1204,6 @@ static int __configure_pipe_params(struct msm_fb_data_type *mfd,
|
|||
}
|
||||
}
|
||||
|
||||
if (layer->flags & SCALER_ENABLED)
|
||||
memcpy(&pipe->scaler, layer->scale,
|
||||
sizeof(struct mdp_scale_data_v2));
|
||||
ret = mdss_mdp_overlay_setup_scaling(pipe);
|
||||
if (ret) {
|
||||
pr_err("scaling setup failed %d\n", ret);
|
||||
|
|
Loading…
Add table
Reference in a new issue