diff options
author | Dmitry Baryshkov <dmitry.baryshkov@linaro.org> | 2024-04-20 07:01:04 +0300 |
---|---|---|
committer | Dmitry Baryshkov <dmitry.baryshkov@linaro.org> | 2024-04-23 12:56:30 +0300 |
commit | f4f392074fc5ada8d19a865fcaf30e50b19eb328 (patch) | |
tree | f0361ace4cf1d6d80f9dbf94bea09dd444c6cef8 /drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c | |
parent | e09251486b946d5630f481965e5251dd620eed35 (diff) | |
download | linux-stable-f4f392074fc5ada8d19a865fcaf30e50b19eb328.tar.gz linux-stable-f4f392074fc5ada8d19a865fcaf30e50b19eb328.tar.bz2 linux-stable-f4f392074fc5ada8d19a865fcaf30e50b19eb328.zip |
drm/msm: convert msm_format::unpack_align_msb to the flag
Instead of having a u8 or bool field unpack_align_msb, convert it to the
flag, this save space in the tables and allows us to handle all booleans
in the same way.
Reviewed-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Patchwork: https://patchwork.freedesktop.org/patch/590427/
Link: https://lore.kernel.org/r/20240420-dpu-format-v2-7-9e93226cbffd@linaro.org
Diffstat (limited to 'drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c')
-rw-r--r-- | drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c index 19163634855f..93ff01c889b5 100644 --- a/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c +++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c @@ -97,7 +97,7 @@ static void dpu_hw_wb_setup_format(struct dpu_hw_wb *ctx, (fmt->element[1] << 8) | (fmt->element[0] << 0); - dst_format |= (fmt->unpack_align_msb << 18) | + dst_format |= ((fmt->flags & MSM_FORMAT_FLAG_UNPACK_ALIGN_MSB ? 1 : 0) << 18) | ((fmt->flags & MSM_FORMAT_FLAG_UNPACK_TIGHT ? 1 : 0) << 17) | ((fmt->unpack_count - 1) << 12) | ((fmt->bpp - 1) << 9); |