linux/drivers/media/platform/nuvoton/npcm-regs.h

/* SPDX-License-Identifier: GPL-2.0 */
/*
 * Register definition header for NPCM video driver
 *
 * Copyright (C) 2022 Nuvoton Technologies
 */

#ifndef _NPCM_REGS_H
#define _NPCM_REGS_H

/* VCD Registers */
#define VCD_DIFF_TBL
#define VCD_FBA_ADR
#define VCD_FBB_ADR

#define VCD_FB_LP
#define VCD_FBA_LP
#define VCD_FBB_LP

#define VCD_CAP_RES
#define VCD_CAP_RES_VERT_RES
#define VCD_CAP_RES_HOR_RES

#define VCD_MODE
#define VCD_MODE_VCDE
#define VCD_MODE_CM565
#define VCD_MODE_IDBC
#define VCD_MODE_KVM_BW_SET

#define VCD_CMD
#define VCD_CMD_GO
#define VCD_CMD_RST
#define VCD_CMD_OPERATION
#define VCD_CMD_OPERATION_CAPTURE
#define VCD_CMD_OPERATION_COMPARE

#define VCD_STAT
#define VCD_STAT_DONE
#define VCD_STAT_IFOT
#define VCD_STAT_IFOR
#define VCD_STAT_VHT_CHG
#define VCD_STAT_HAC_CHG
#define VCD_STAT_BUSY
#define VCD_STAT_CLEAR

#define VCD_INTE
#define VCD_INTE_DONE_IE
#define VCD_INTE_IFOT_IE
#define VCD_INTE_IFOR_IE
#define VCD_INTE_VHT_IE
#define VCD_INTE_HAC_IE

#define VCD_RCHG
#define VCD_RCHG_IG_CHG0
#define VCD_RCHG_TIM_PRSCL

#define VCD_VER_HI_TIM
#define VCD_VER_HI_TIME

#define VCD_VER_HI_LST
#define VCD_VER_HI_LAST

#define VCD_HOR_AC_TIM
#define VCD_HOR_AC_TIME

#define VCD_HOR_AC_LST
#define VCD_HOR_AC_LAST

#define VCD_FIFO
#define VCD_FIFO_TH

#define VCD_FB_SIZE
#define VCD_KVM_BW_PCLK
#define VCD_TIMEOUT_US

/* ECE Registers */
#define ECE_DDA_CTRL
#define ECE_DDA_CTRL_ECEEN
#define ECE_DDA_CTRL_INTEN

#define ECE_DDA_STS
#define ECE_DDA_STS_CDREADY
#define ECE_DDA_STS_ACDRDY

#define ECE_FBR_BA
#define ECE_ED_BA
#define ECE_RECT_XY

#define ECE_RECT_DIMEN
#define ECE_RECT_DIMEN_WR
#define ECE_RECT_DIMEN_WLTR
#define ECE_RECT_DIMEN_HR
#define ECE_RECT_DIMEN_HLTR

#define ECE_RESOL
#define ECE_RESOL_FB_LP_512
#define ECE_RESOL_FB_LP_1024
#define ECE_RESOL_FB_LP_2048
#define ECE_RESOL_FB_LP_2560
#define ECE_RESOL_FB_LP_4096

#define ECE_HEX_CTRL
#define ECE_HEX_CTRL_ENCDIS
#define ECE_HEX_CTRL_ENC_GAP

#define ECE_HEX_RECT_OFFSET
#define ECE_HEX_RECT_OFFSET_MASK

#define ECE_TILE_W
#define ECE_TILE_H
#define ECE_POLL_TIMEOUT_US

/* GCR Registers */
#define INTCR
#define INTCR_GFXIFDIS
#define INTCR_DEHS

#define INTCR2
#define INTCR2_GIRST2
#define INTCR2_GIHCRST
#define INTCR2_GIVCRST

/* GFXI Register */
#define DISPST
#define DISPST_HSCROFF
#define DISPST_MGAMODE

#define HVCNTL
#define HVCNTL_MASK

#define HVCNTH
#define HVCNTH_MASK

#define VVCNTL
#define VVCNTL_MASK

#define VVCNTH
#define VVCNTH_MASK

#define GPLLINDIV
#define GPLLINDIV_MASK
#define GPLLINDIV_GPLLFBDV8

#define GPLLFBDIV
#define GPLLFBDIV_MASK

#define GPLLST
#define GPLLST_PLLOTDIV1
#define GPLLST_PLLOTDIV2
#define GPLLST_GPLLFBDV109

#endif /* _NPCM_REGS_H */