msm: mdss: fix NV12 UBWC format configuration
Fix NV12 UBWC buffer support by setting YUV format bit in format register and correct plane address. Change-Id: I013e0855ae6c2f990d0d5d6386b9949f475c0ad1 Signed-off-by: Dhaval Patel <pdhaval@codeaurora.org>
This commit is contained in:
parent
06511bea72
commit
11f814f19a
3 changed files with 11 additions and 3 deletions
|
@ -201,6 +201,7 @@ enum mdss_mdp_sspp_chroma_samp_type {
|
|||
#define MDSS_MDP_REG_SSPP_REQPRIO_FIFO_WM_1 0x054
|
||||
#define MDSS_MDP_REG_SSPP_REQPRIO_FIFO_WM_2 0x058
|
||||
#define MDSS_MDP_REG_SSPP_QOS_CTRL 0x06C
|
||||
#define MDSS_MDP_REG_SSPP_UBWC_ERROR_STATUS 0x138
|
||||
|
||||
#define MDSS_MDP_REG_SSPP_SRC_OP_MODE 0x038
|
||||
#define MDSS_MDP_OP_DEINTERLACE BIT(22)
|
||||
|
|
|
@ -1601,6 +1601,10 @@ static int mdss_mdp_format_setup(struct mdss_mdp_pipe *pipe)
|
|||
src_format |= BIT(31);
|
||||
}
|
||||
|
||||
/* This bit is only valid for thulium target; noop for other targets */
|
||||
if (fmt->is_yuv)
|
||||
src_format |= BIT(15);
|
||||
|
||||
mdss_mdp_pipe_sspp_setup(pipe, &opmode);
|
||||
|
||||
if (mdss_mdp_is_tile_format(fmt) && mdata->highest_bank_bit) {
|
||||
|
@ -1615,6 +1619,9 @@ static int mdss_mdp_format_setup(struct mdss_mdp_pipe *pipe)
|
|||
mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_OP_MODE, opmode);
|
||||
mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_SRC_ADDR_SW_STATUS, secure);
|
||||
|
||||
/* clear UBWC error */
|
||||
mdss_mdp_pipe_write(pipe, MDSS_MDP_REG_SSPP_UBWC_ERROR_STATUS, BIT(31));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
@ -534,10 +534,10 @@ static int mdss_mdp_ubwc_data_check(struct mdss_mdp_data *data,
|
|||
/* | Y meta | ** | Y bitstream | */
|
||||
/* | data | ** | plane | */
|
||||
/* ------------------- ** -------------------- */
|
||||
/* | CbCr meta | ** | CbCr bitstream | */
|
||||
/* | Y bitstream | ** | CbCr bitstream | */
|
||||
/* | data | ** | plane | */
|
||||
/* ------------------- ** -------------------- */
|
||||
/* | Y bitstream | ** | Y meta | */
|
||||
/* | Cbcr metadata | ** | Y meta | */
|
||||
/* | data | ** | plane | */
|
||||
/* ------------------- ** -------------------- */
|
||||
/* | CbCr bitstream | ** | CbCr meta | */
|
||||
|
@ -551,7 +551,7 @@ static int mdss_mdp_ubwc_data_check(struct mdss_mdp_data *data,
|
|||
|
||||
/* configure CbCr bitstream plane */
|
||||
data->p[1].addr = base_addr + ps->plane_size[0]
|
||||
+ ps->plane_size[1] + ps->plane_size[2];
|
||||
+ ps->plane_size[2] + ps->plane_size[3];
|
||||
data->p[1].len = ps->plane_size[1];
|
||||
|
||||
/* configure Y metadata plane */
|
||||
|
|
Loading…
Add table
Reference in a new issue