linux/drivers/media/platform/ti/vpe/vpe_regs.h

/* SPDX-License-Identifier: GPL-2.0-only */
/*
 * Copyright (c) 2013 Texas Instruments Inc.
 *
 * David Griego, <[email protected]>
 * Dale Farnsworth, <[email protected]>
 * Archit Taneja, <[email protected]>
 */

#ifndef __TI_VPE_REGS_H
#define __TI_VPE_REGS_H

/* VPE register offsets and field selectors */

/* VPE top level regs */
#define VPE_PID
#define VPE_PID_MINOR_MASK
#define VPE_PID_MINOR_SHIFT
#define VPE_PID_CUSTOM_MASK
#define VPE_PID_CUSTOM_SHIFT
#define VPE_PID_MAJOR_MASK
#define VPE_PID_MAJOR_SHIFT
#define VPE_PID_RTL_MASK
#define VPE_PID_RTL_SHIFT
#define VPE_PID_FUNC_MASK
#define VPE_PID_FUNC_SHIFT
#define VPE_PID_SCHEME_MASK
#define VPE_PID_SCHEME_SHIFT

#define VPE_SYSCONFIG
#define VPE_SYSCONFIG_IDLE_MASK
#define VPE_SYSCONFIG_IDLE_SHIFT
#define VPE_SYSCONFIG_STANDBY_MASK
#define VPE_SYSCONFIG_STANDBY_SHIFT
#define VPE_FORCE_IDLE_MODE
#define VPE_NO_IDLE_MODE
#define VPE_SMART_IDLE_MODE
#define VPE_SMART_IDLE_WAKEUP_MODE
#define VPE_FORCE_STANDBY_MODE
#define VPE_NO_STANDBY_MODE
#define VPE_SMART_STANDBY_MODE
#define VPE_SMART_STANDBY_WAKEUP_MODE

#define VPE_INT0_STATUS0_RAW_SET
#define VPE_INT0_STATUS0_RAW
#define VPE_INT0_STATUS0_CLR
#define VPE_INT0_STATUS0
#define VPE_INT0_ENABLE0_SET
#define VPE_INT0_ENABLE0
#define VPE_INT0_ENABLE0_CLR
#define VPE_INT0_LIST0_COMPLETE
#define VPE_INT0_LIST0_NOTIFY
#define VPE_INT0_LIST1_COMPLETE
#define VPE_INT0_LIST1_NOTIFY
#define VPE_INT0_LIST2_COMPLETE
#define VPE_INT0_LIST2_NOTIFY
#define VPE_INT0_LIST3_COMPLETE
#define VPE_INT0_LIST3_NOTIFY
#define VPE_INT0_LIST4_COMPLETE
#define VPE_INT0_LIST4_NOTIFY
#define VPE_INT0_LIST5_COMPLETE
#define VPE_INT0_LIST5_NOTIFY
#define VPE_INT0_LIST6_COMPLETE
#define VPE_INT0_LIST6_NOTIFY
#define VPE_INT0_LIST7_COMPLETE
#define VPE_INT0_LIST7_NOTIFY
#define VPE_INT0_DESCRIPTOR
#define VPE_DEI_FMD_INT

#define VPE_INT0_STATUS1_RAW_SET
#define VPE_INT0_STATUS1_RAW
#define VPE_INT0_STATUS1_CLR
#define VPE_INT0_STATUS1
#define VPE_INT0_ENABLE1_SET
#define VPE_INT0_ENABLE1
#define VPE_INT0_ENABLE1_CLR
#define VPE_INT0_CHANNEL_GROUP0
#define VPE_INT0_CHANNEL_GROUP1
#define VPE_INT0_CHANNEL_GROUP2
#define VPE_INT0_CHANNEL_GROUP3
#define VPE_INT0_CHANNEL_GROUP4
#define VPE_INT0_CHANNEL_GROUP5
#define VPE_INT0_CLIENT
#define VPE_DEI_ERROR_INT
#define VPE_DS1_UV_ERROR_INT

#define VPE_INTC_EOI

#define VPE_CLK_ENABLE
#define VPE_VPEDMA_CLK_ENABLE
#define VPE_DATA_PATH_CLK_ENABLE

#define VPE_CLK_RESET
#define VPE_VPDMA_CLK_RESET_MASK
#define VPE_VPDMA_CLK_RESET_SHIFT
#define VPE_DATA_PATH_CLK_RESET_MASK
#define VPE_DATA_PATH_CLK_RESET_SHIFT
#define VPE_MAIN_RESET_MASK
#define VPE_MAIN_RESET_SHIFT

#define VPE_CLK_FORMAT_SELECT
#define VPE_CSC_SRC_SELECT_MASK
#define VPE_CSC_SRC_SELECT_SHIFT
#define VPE_RGB_OUT_SELECT
#define VPE_DS_SRC_SELECT_MASK
#define VPE_DS_SRC_SELECT_SHIFT
#define VPE_DS_BYPASS
#define VPE_COLOR_SEPARATE_422

#define VPE_DS_SRC_DEI_SCALER
#define VPE_CSC_SRC_DEI_SCALER

#define VPE_CLK_RANGE_MAP
#define VPE_RANGE_RANGE_MAP_Y_MASK
#define VPE_RANGE_RANGE_MAP_Y_SHIFT
#define VPE_RANGE_RANGE_MAP_UV_MASK
#define VPE_RANGE_RANGE_MAP_UV_SHIFT
#define VPE_RANGE_MAP_ON
#define VPE_RANGE_REDUCTION_ON

/* VPE chrominance upsampler regs */
#define VPE_US1_R0
#define VPE_US2_R0
#define VPE_US3_R0
#define VPE_US_C1_MASK
#define VPE_US_C1_SHIFT
#define VPE_US_C0_MASK
#define VPE_US_C0_SHIFT
#define VPE_US_MODE_MASK
#define VPE_US_MODE_SHIFT
#define VPE_ANCHOR_FID0_C1_MASK
#define VPE_ANCHOR_FID0_C1_SHIFT
#define VPE_ANCHOR_FID0_C0_MASK
#define VPE_ANCHOR_FID0_C0_SHIFT

#define VPE_US1_R1
#define VPE_US2_R1
#define VPE_US3_R1
#define VPE_ANCHOR_FID0_C3_MASK
#define VPE_ANCHOR_FID0_C3_SHIFT
#define VPE_ANCHOR_FID0_C2_MASK
#define VPE_ANCHOR_FID0_C2_SHIFT

#define VPE_US1_R2
#define VPE_US2_R2
#define VPE_US3_R2
#define VPE_INTERP_FID0_C1_MASK
#define VPE_INTERP_FID0_C1_SHIFT
#define VPE_INTERP_FID0_C0_MASK
#define VPE_INTERP_FID0_C0_SHIFT

#define VPE_US1_R3
#define VPE_US2_R3
#define VPE_US3_R3
#define VPE_INTERP_FID0_C3_MASK
#define VPE_INTERP_FID0_C3_SHIFT
#define VPE_INTERP_FID0_C2_MASK
#define VPE_INTERP_FID0_C2_SHIFT

#define VPE_US1_R4
#define VPE_US2_R4
#define VPE_US3_R4
#define VPE_ANCHOR_FID1_C1_MASK
#define VPE_ANCHOR_FID1_C1_SHIFT
#define VPE_ANCHOR_FID1_C0_MASK
#define VPE_ANCHOR_FID1_C0_SHIFT

#define VPE_US1_R5
#define VPE_US2_R5
#define VPE_US3_R5
#define VPE_ANCHOR_FID1_C3_MASK
#define VPE_ANCHOR_FID1_C3_SHIFT
#define VPE_ANCHOR_FID1_C2_MASK
#define VPE_ANCHOR_FID1_C2_SHIFT

#define VPE_US1_R6
#define VPE_US2_R6
#define VPE_US3_R6
#define VPE_INTERP_FID1_C1_MASK
#define VPE_INTERP_FID1_C1_SHIFT
#define VPE_INTERP_FID1_C0_MASK
#define VPE_INTERP_FID1_C0_SHIFT

#define VPE_US1_R7
#define VPE_US2_R7
#define VPE_US3_R7
#define VPE_INTERP_FID0_C3_MASK
#define VPE_INTERP_FID0_C3_SHIFT
#define VPE_INTERP_FID0_C2_MASK
#define VPE_INTERP_FID0_C2_SHIFT

/* VPE de-interlacer regs */
#define VPE_DEI_FRAME_SIZE
#define VPE_DEI_WIDTH_MASK
#define VPE_DEI_WIDTH_SHIFT
#define VPE_DEI_HEIGHT_MASK
#define VPE_DEI_HEIGHT_SHIFT
#define VPE_DEI_INTERLACE_BYPASS
#define VPE_DEI_FIELD_FLUSH
#define VPE_DEI_PROGRESSIVE

#define VPE_MDT_BYPASS
#define VPE_MDT_TEMPMAX_BYPASS
#define VPE_MDT_SPATMAX_BYPASS

#define VPE_MDT_SF_THRESHOLD
#define VPE_MDT_SF_SC_THR1_MASK
#define VPE_MDT_SF_SC_THR1_SHIFT
#define VPE_MDT_SF_SC_THR2_MASK
#define VPE_MDT_SF_SC_THR2_SHIFT
#define VPE_MDT_SF_SC_THR3_MASK
#define VPE_MDT_SF_SC_THR3_SHIFT

#define VPE_EDI_CONFIG
#define VPE_EDI_INP_MODE_MASK
#define VPE_EDI_INP_MODE_SHIFT
#define VPE_EDI_ENABLE_3D
#define VPE_EDI_ENABLE_CHROMA_3D
#define VPE_EDI_CHROMA3D_COR_THR_MASK
#define VPE_EDI_CHROMA3D_COR_THR_SHIFT
#define VPE_EDI_DIR_COR_LOWER_THR_MASK
#define VPE_EDI_DIR_COR_LOWER_THR_SHIFT
#define VPE_EDI_COR_SCALE_FACTOR_MASK
#define VPE_EDI_COR_SCALE_FACTOR_SHIFT

#define VPE_DEI_EDI_LUT_R0
#define VPE_EDI_LUT0_MASK
#define VPE_EDI_LUT0_SHIFT
#define VPE_EDI_LUT1_MASK
#define VPE_EDI_LUT1_SHIFT
#define VPE_EDI_LUT2_MASK
#define VPE_EDI_LUT2_SHIFT
#define VPE_EDI_LUT3_MASK
#define VPE_EDI_LUT3_SHIFT

#define VPE_DEI_EDI_LUT_R1
#define VPE_EDI_LUT0_MASK
#define VPE_EDI_LUT0_SHIFT
#define VPE_EDI_LUT1_MASK
#define VPE_EDI_LUT1_SHIFT
#define VPE_EDI_LUT2_MASK
#define VPE_EDI_LUT2_SHIFT
#define VPE_EDI_LUT3_MASK
#define VPE_EDI_LUT3_SHIFT

#define VPE_DEI_EDI_LUT_R2
#define VPE_EDI_LUT4_MASK
#define VPE_EDI_LUT4_SHIFT
#define VPE_EDI_LUT5_MASK
#define VPE_EDI_LUT5_SHIFT
#define VPE_EDI_LUT6_MASK
#define VPE_EDI_LUT6_SHIFT
#define VPE_EDI_LUT7_MASK
#define VPE_EDI_LUT7_SHIFT

#define VPE_DEI_EDI_LUT_R3
#define VPE_EDI_LUT8_MASK
#define VPE_EDI_LUT8_SHIFT
#define VPE_EDI_LUT9_MASK
#define VPE_EDI_LUT9_SHIFT
#define VPE_EDI_LUT10_MASK
#define VPE_EDI_LUT10_SHIFT
#define VPE_EDI_LUT11_MASK
#define VPE_EDI_LUT11_SHIFT

#define VPE_DEI_FMD_WINDOW_R0
#define VPE_FMD_WINDOW_MINX_MASK
#define VPE_FMD_WINDOW_MINX_SHIFT
#define VPE_FMD_WINDOW_MAXX_MASK
#define VPE_FMD_WINDOW_MAXX_SHIFT
#define VPE_FMD_WINDOW_ENABLE

#define VPE_DEI_FMD_WINDOW_R1
#define VPE_FMD_WINDOW_MINY_MASK
#define VPE_FMD_WINDOW_MINY_SHIFT
#define VPE_FMD_WINDOW_MAXY_MASK
#define VPE_FMD_WINDOW_MAXY_SHIFT

#define VPE_DEI_FMD_CONTROL_R0
#define VPE_FMD_ENABLE
#define VPE_FMD_LOCK
#define VPE_FMD_JAM_DIR
#define VPE_FMD_BED_ENABLE
#define VPE_FMD_CAF_FIELD_THR_MASK
#define VPE_FMD_CAF_FIELD_THR_SHIFT
#define VPE_FMD_CAF_LINE_THR_MASK
#define VPE_FMD_CAF_LINE_THR_SHIFT

#define VPE_DEI_FMD_CONTROL_R1
#define VPE_FMD_CAF_THR_MASK
#define VPE_FMD_CAF_THR_SHIFT

#define VPE_DEI_FMD_STATUS_R0
#define VPE_FMD_CAF_MASK
#define VPE_FMD_CAF_SHIFT
#define VPE_FMD_RESET

#define VPE_DEI_FMD_STATUS_R1
#define VPE_FMD_FIELD_DIFF_MASK
#define VPE_FMD_FIELD_DIFF_SHIFT

#define VPE_DEI_FMD_STATUS_R2
#define VPE_FMD_FRAME_DIFF_MASK
#define VPE_FMD_FRAME_DIFF_SHIFT

#endif