Re: [PATCH v15 16/16] drm/mediatek: dpi: Add dp_intf support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi, Bo-Chen:

On Fri, 2022-07-01 at 11:58 +0800, Bo-Chen Chen wrote:
> From: Guillaume Ranquet <granquet@xxxxxxxxxxxx>
> 
> Dpintf is the displayport interface hardware unit. This unit is
> similar
> to dpi and can reuse most of the code.
> 
> This patch adds support for mt8195-dpintf to this dpi driver. Main
> differences are:
>  - 4 pixels for one iteration for dp_intf while dpi is 1 pixel for
> one
>    iteration. Therefore, we add a new config "pixels_per_iter" to
> control
>    quantity of transferred pixels per iteration.
>  - Input of dp_intf is two pixels per iteration, so we add a new
> config
>    "input_2pixel" to control this.
>  - Some register contents differ slightly between the two components.
> To
>    work around this I added register bits/masks with a DPINTF_ prefix
>    and use them where different.
> 
> Based on a separate driver for dpintf created by
> Jitao shi <jitao.shi@xxxxxxxxxxxx>.
> 
> Signed-off-by: Markus Schneider-Pargmann <msp@xxxxxxxxxxxx>
> Signed-off-by: Guillaume Ranquet <granquet@xxxxxxxxxxxx>
> Signed-off-by: Bo-Chen Chen <rex-bc.chen@xxxxxxxxxxxx>
> Reviewed-by: AngeloGioacchino Del Regno <
> angelogioacchino.delregno@xxxxxxxxxxxxx>
> ---
>  drivers/gpu/drm/mediatek/mtk_dpi.c          | 65
> ++++++++++++++++++++-
>  drivers/gpu/drm/mediatek/mtk_dpi_regs.h     | 12 ++++
>  drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.c |  4 ++
>  drivers/gpu/drm/mediatek/mtk_drm_ddp_comp.h |  1 +
>  drivers/gpu/drm/mediatek/mtk_drm_drv.c      |  3 +
>  5 files changed, 82 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/mediatek/mtk_dpi.c
> b/drivers/gpu/drm/mediatek/mtk_dpi.c
> index be039474cf26..1072e94d2f2f 100644
> --- a/drivers/gpu/drm/mediatek/mtk_dpi.c
> +++ b/drivers/gpu/drm/mediatek/mtk_dpi.c
> @@ -125,12 +125,15 @@ struct mtk_dpi_yc_limit {
>   * @swap_input_support: Support input swap function.
>   * @color_fmt_trans_support: Enable color format transfer.
>   * @support_direct_pin: IP supports direct connection to dpi panels.
> + * @input_2pixel: Input pixel of dp_intf is 2 pixel per round, so
> enable this
> + *		  config to enable this feature.
>   * @dimension_mask: Mask used for HWIDTH, HPORCH, VSYNC_WIDTH and
> VSYNC_PORCH
>   *		    (no shift).
>   * @hvsize_mask: Mask of HSIZE and VSIZE mask (no shift).
>   * @channel_swap_shift: Shift value of channel swap.
>   * @yuv422_en_bit: Enable bit of yuv422.
>   * @csc_enable_bit: Enable bit of CSC.
> + * @pixels_per_iter: Quantity of transferred pixels per iteration.
>   */
>  struct mtk_dpi_conf {
>  	unsigned int (*cal_factor)(int clock);
> @@ -143,11 +146,13 @@ struct mtk_dpi_conf {
>  	bool swap_input_support;
>  	bool color_fmt_trans_support;
>  	bool support_direct_pin;
> +	bool input_2pixel;

Separate input_2pixel to an independent patch.

>  	u32 dimension_mask;
>  	u32 hvsize_mask;
>  	u32 channel_swap_shift;
>  	u32 yuv422_en_bit;
>  	u32 csc_enable_bit;
> +	u32 pixels_per_iter;

Separate pixels_per_iter to an independent patch.

Regards,
CK

>  };
>  
> 




[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux