linux/drivers/gpu/drm/renesas/rcar-du/rcar_mipi_dsi_regs.h

/* SPDX-License-Identifier: GPL-2.0 */
/*
 * R-Car MIPI DSI Interface Registers Definitions
 *
 * Copyright (C) 2020 Renesas Electronics Corporation
 */

#ifndef __RCAR_MIPI_DSI_REGS_H__
#define __RCAR_MIPI_DSI_REGS_H__

#define LINKSR
#define LINKSR_LPBUSY
#define LINKSR_HSBUSY

/*
 * Video Mode Register
 */
#define TXVMSETR
#define TXVMSETR_SYNSEQ_PULSES
#define TXVMSETR_SYNSEQ_EVENTS
#define TXVMSETR_VSTPM
#define TXVMSETR_PIXWDTH
#define TXVMSETR_VSEN_EN
#define TXVMSETR_VSEN_DIS
#define TXVMSETR_HFPBPEN_EN
#define TXVMSETR_HFPBPEN_DIS
#define TXVMSETR_HBPBPEN_EN
#define TXVMSETR_HBPBPEN_DIS
#define TXVMSETR_HSABPEN_EN
#define TXVMSETR_HSABPEN_DIS

#define TXVMCR
#define TXVMCR_VFCLR
#define TXVMCR_EN_VIDEO

#define TXVMSR
#define TXVMSR_STR
#define TXVMSR_VFRDY
#define TXVMSR_ACT
#define TXVMSR_RDY

#define TXVMSCR
#define TXVMSCR_STR

#define TXVMPSPHSETR
#define TXVMPSPHSETR_DT_RGB16
#define TXVMPSPHSETR_DT_RGB18
#define TXVMPSPHSETR_DT_RGB18_LS
#define TXVMPSPHSETR_DT_RGB24
#define TXVMPSPHSETR_DT_YCBCR16

#define TXVMVPRMSET0R
#define TXVMVPRMSET0R_HSPOL_HIG
#define TXVMVPRMSET0R_HSPOL_LOW
#define TXVMVPRMSET0R_VSPOL_HIG
#define TXVMVPRMSET0R_VSPOL_LOW
#define TXVMVPRMSET0R_CSPC_RGB
#define TXVMVPRMSET0R_CSPC_YCbCr
#define TXVMVPRMSET0R_BPP_16
#define TXVMVPRMSET0R_BPP_18
#define TXVMVPRMSET0R_BPP_24

#define TXVMVPRMSET1R
#define TXVMVPRMSET1R_VACTIVE(x)
#define TXVMVPRMSET1R_VSA(x)

#define TXVMVPRMSET2R
#define TXVMVPRMSET2R_VFP(x)
#define TXVMVPRMSET2R_VBP(x)

#define TXVMVPRMSET3R
#define TXVMVPRMSET3R_HACTIVE(x)
#define TXVMVPRMSET3R_HSA(x)

#define TXVMVPRMSET4R
#define TXVMVPRMSET4R_HFP(x)
#define TXVMVPRMSET4R_HBP(x)

/*
 * PHY-Protocol Interface (PPI) Registers
 */
#define PPISETR
#define PPISETR_DLEN_0
#define PPISETR_DLEN_1
#define PPISETR_DLEN_2
#define PPISETR_DLEN_3
#define PPISETR_CLEN

#define PPICLCR
#define PPICLCR_TXREQHS
#define PPICLCR_TXULPSEXT
#define PPICLCR_TXULPSCLK

#define PPICLSR
#define PPICLSR_HSTOLP
#define PPICLSR_TOHS
#define PPICLSR_STPST

#define PPICLSCR
#define PPICLSCR_HSTOLP
#define PPICLSCR_TOHS

#define PPIDLSR
#define PPIDLSR_STPST

/*
 * Clocks registers
 */
#define LPCLKSET
#define LPCLKSET_CKEN
#define LPCLKSET_LPCLKDIV(x)

#define CFGCLKSET
#define CFGCLKSET_CKEN
#define CFGCLKSET_CFGCLKDIV(x)

#define DOTCLKDIV
#define DOTCLKDIV_CKEN
#define DOTCLKDIV_DOTCLKDIV(x)

#define VCLKSET
#define VCLKSET_CKEN
#define VCLKSET_COLOR_RGB
#define VCLKSET_COLOR_YCC
#define VCLKSET_DIV_V3U(x)
#define VCLKSET_DIV_V4H(x)
#define VCLKSET_BPP_16
#define VCLKSET_BPP_18
#define VCLKSET_BPP_18L
#define VCLKSET_BPP_24
#define VCLKSET_LANE(x)

#define VCLKEN
#define VCLKEN_CKEN

#define PHYSETUP
#define PHYSETUP_HSFREQRANGE(x)
#define PHYSETUP_HSFREQRANGE_MASK
#define PHYSETUP_CFGCLKFREQRANGE(x)
#define PHYSETUP_SHUTDOWNZ
#define PHYSETUP_RSTZ

#define CLOCKSET1
#define CLOCKSET1_LOCK_PHY
#define CLOCKSET1_LOCK
#define CLOCKSET1_CLKSEL
#define CLOCKSET1_CLKINSEL_EXTAL
#define CLOCKSET1_CLKINSEL_DIG
#define CLOCKSET1_CLKINSEL_DU
#define CLOCKSET1_SHADOW_CLEAR
#define CLOCKSET1_UPDATEPLL

#define CLOCKSET2
#define CLOCKSET2_M(x)
#define CLOCKSET2_VCO_CNTRL(x)
#define CLOCKSET2_N(x)

#define CLOCKSET3
#define CLOCKSET3_PROP_CNTRL(x)
#define CLOCKSET3_INT_CNTRL(x)
#define CLOCKSET3_CPBIAS_CNTRL(x)
#define CLOCKSET3_GMP_CNTRL(x)

#define PHTW
#define PHTW_DWEN
#define PHTW_TESTDIN_DATA(x)
#define PHTW_CWEN
#define PHTW_TESTDIN_CODE(x)

#define PHTR
#define PHTR_TEST

#define PHTC
#define PHTC_TESTCLR

#endif /* __RCAR_MIPI_DSI_REGS_H__ */