linux/drivers/media/platform/microchip/microchip-isc-regs.h

/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __MICROCHIP_ISC_REGS_H
#define __MICROCHIP_ISC_REGS_H

#include <linux/bitops.h>

/* ISC Control Enable Register 0 */
#define ISC_CTRLEN

/* ISC Control Disable Register 0 */
#define ISC_CTRLDIS

/* ISC Control Status Register 0 */
#define ISC_CTRLSR

#define ISC_CTRL_CAPTURE
#define ISC_CTRL_UPPRO
#define ISC_CTRL_HISREQ
#define ISC_CTRL_HISCLR

/* ISC Parallel Front End Configuration 0 Register */
#define ISC_PFE_CFG0

#define ISC_PFE_CFG0_HPOL_LOW
#define ISC_PFE_CFG0_VPOL_LOW
#define ISC_PFE_CFG0_PPOL_LOW
#define ISC_PFE_CFG0_CCIR656
#define ISC_PFE_CFG0_CCIR_CRC
#define ISC_PFE_CFG0_MIPI

#define ISC_PFE_CFG0_MODE_PROGRESSIVE
#define ISC_PFE_CFG0_MODE_MASK

#define ISC_PFE_CFG0_BPS_EIGHT
#define ISC_PFG_CFG0_BPS_NINE
#define ISC_PFG_CFG0_BPS_TEN
#define ISC_PFG_CFG0_BPS_ELEVEN
#define ISC_PFG_CFG0_BPS_TWELVE
#define ISC_PFE_CFG0_BPS_MASK

#define ISC_PFE_CFG0_COLEN
#define ISC_PFE_CFG0_ROWEN

/* ISC Parallel Front End Configuration 1 Register */
#define ISC_PFE_CFG1

#define ISC_PFE_CFG1_COLMIN(v)
#define ISC_PFE_CFG1_COLMIN_MASK
#define ISC_PFE_CFG1_COLMAX(v)
#define ISC_PFE_CFG1_COLMAX_MASK

/* ISC Parallel Front End Configuration 2 Register */
#define ISC_PFE_CFG2

#define ISC_PFE_CFG2_ROWMIN(v)
#define ISC_PFE_CFG2_ROWMIN_MASK
#define ISC_PFE_CFG2_ROWMAX(v)
#define ISC_PFE_CFG2_ROWMAX_MASK

/* ISC Clock Enable Register */
#define ISC_CLKEN

/* ISC Clock Disable Register */
#define ISC_CLKDIS

/* ISC Clock Status Register */
#define ISC_CLKSR
#define ISC_CLKSR_SIP

#define ISC_CLK(n)

/* ISC Clock Configuration Register */
#define ISC_CLKCFG
#define ISC_CLKCFG_DIV_SHIFT(n)
#define ISC_CLKCFG_DIV_MASK(n)
#define ISC_CLKCFG_SEL_SHIFT(n)
#define ISC_CLKCFG_SEL_MASK(n)

/* ISC Interrupt Enable Register */
#define ISC_INTEN

/* ISC Interrupt Disable Register */
#define ISC_INTDIS

/* ISC Interrupt Mask Register */
#define ISC_INTMASK

/* ISC Interrupt Status Register */
#define ISC_INTSR

#define ISC_INT_DDONE
#define ISC_INT_HISDONE

/* ISC DPC Control Register */
#define ISC_DPC_CTRL

#define ISC_DPC_CTRL_DPCEN
#define ISC_DPC_CTRL_GDCEN
#define ISC_DPC_CTRL_BLCEN

/* ISC DPC Config Register */
#define ISC_DPC_CFG

#define ISC_DPC_CFG_BAYSEL_SHIFT

#define ISC_DPC_CFG_EITPOL

#define ISC_DPC_CFG_TA_ENABLE
#define ISC_DPC_CFG_TC_ENABLE
#define ISC_DPC_CFG_TM_ENABLE

#define ISC_DPC_CFG_RE_MODE

#define ISC_DPC_CFG_GDCCLP_SHIFT
#define ISC_DPC_CFG_GDCCLP_MASK

#define ISC_DPC_CFG_BLOFF_SHIFT
#define ISC_DPC_CFG_BLOFF_MASK

#define ISC_DPC_CFG_BAYCFG_SHIFT
#define ISC_DPC_CFG_BAYCFG_MASK
/* ISC DPC Threshold Median Register */
#define ISC_DPC_THRESHM

/* ISC DPC Threshold Closest Register */
#define ISC_DPC_THRESHC

/* ISC DPC Threshold Average Register */
#define ISC_DPC_THRESHA

/* ISC DPC STatus Register */
#define ISC_DPC_SR

/* ISC White Balance Control Register */
#define ISC_WB_CTRL

/* ISC White Balance Configuration Register */
#define ISC_WB_CFG

/* ISC White Balance Offset for R, GR Register */
#define ISC_WB_O_RGR

/* ISC White Balance Offset for B, GB Register */
#define ISC_WB_O_BGB

/* ISC White Balance Gain for R, GR Register */
#define ISC_WB_G_RGR

/* ISC White Balance Gain for B, GB Register */
#define ISC_WB_G_BGB

/* ISC Color Filter Array Control Register */
#define ISC_CFA_CTRL

/* ISC Color Filter Array Configuration Register */
#define ISC_CFA_CFG
#define ISC_CFA_CFG_EITPOL

#define ISC_BAY_CFG_GRGR
#define ISC_BAY_CFG_RGRG
#define ISC_BAY_CFG_GBGB
#define ISC_BAY_CFG_BGBG

/* ISC Color Correction Control Register */
#define ISC_CC_CTRL

/* ISC Color Correction RR RG Register */
#define ISC_CC_RR_RG

/* ISC Color Correction RB OR Register */
#define ISC_CC_RB_OR

/* ISC Color Correction GR GG Register */
#define ISC_CC_GR_GG

/* ISC Color Correction GB OG Register */
#define ISC_CC_GB_OG

/* ISC Color Correction BR BG Register */
#define ISC_CC_BR_BG

/* ISC Color Correction BB OB Register */
#define ISC_CC_BB_OB

/* ISC Gamma Correction Control Register */
#define ISC_GAM_CTRL

#define ISC_GAM_CTRL_BIPART

/* ISC_Gamma Correction Blue Entry Register */
#define ISC_GAM_BENTRY

/* ISC_Gamma Correction Green Entry Register */
#define ISC_GAM_GENTRY

/* ISC_Gamma Correction Green Entry Register */
#define ISC_GAM_RENTRY

/* ISC VHXS Control Register */
#define ISC_VHXS_CTRL

/* ISC VHXS Source Size Register */
#define ISC_VHXS_SS

/* ISC VHXS Destination Size Register */
#define ISC_VHXS_DS

/* ISC Vertical Factor Register */
#define ISC_VXS_FACT

/* ISC Horizontal Factor Register */
#define ISC_HXS_FACT

/* ISC Vertical Config Register */
#define ISC_VXS_CFG

/* ISC Horizontal Config Register */
#define ISC_HXS_CFG

/* ISC Vertical Tap Register */
#define ISC_VXS_TAP

/* ISC Horizontal Tap Register */
#define ISC_HXS_TAP

/* Offset for CSC register specific to sama5d2 product */
#define ISC_SAMA5D2_CSC_OFFSET
/* Offset for CSC register specific to sama7g5 product */
#define ISC_SAMA7G5_CSC_OFFSET

/* Color Space Conversion Control Register */
#define ISC_CSC_CTRL

/* Color Space Conversion YR YG Register */
#define ISC_CSC_YR_YG

/* Color Space Conversion YB OY Register */
#define ISC_CSC_YB_OY

/* Color Space Conversion CBR CBG Register */
#define ISC_CSC_CBR_CBG

/* Color Space Conversion CBB OCB Register */
#define ISC_CSC_CBB_OCB

/* Color Space Conversion CRR CRG Register */
#define ISC_CSC_CRR_CRG

/* Color Space Conversion CRB OCR Register */
#define ISC_CSC_CRB_OCR

/* Offset for CBC register specific to sama5d2 product */
#define ISC_SAMA5D2_CBC_OFFSET
/* Offset for CBC register specific to sama7g5 product */
#define ISC_SAMA7G5_CBC_OFFSET

/* Contrast And Brightness Control Register */
#define ISC_CBC_CTRL

/* Contrast And Brightness Configuration Register */
#define ISC_CBC_CFG

/* Brightness Register */
#define ISC_CBC_BRIGHT
#define ISC_CBC_BRIGHT_MASK

/* Contrast Register */
#define ISC_CBC_CONTRAST
#define ISC_CBC_CONTRAST_MASK

/* Hue Register */
#define ISC_CBCHS_HUE
/* Saturation Register */
#define ISC_CBCHS_SAT

/* Offset for SUB422 register specific to sama5d2 product */
#define ISC_SAMA5D2_SUB422_OFFSET
/* Offset for SUB422 register specific to sama7g5 product */
#define ISC_SAMA7G5_SUB422_OFFSET

/* Subsampling 4:4:4 to 4:2:2 Control Register */
#define ISC_SUB422_CTRL

/* Offset for SUB420 register specific to sama5d2 product */
#define ISC_SAMA5D2_SUB420_OFFSET
/* Offset for SUB420 register specific to sama7g5 product */
#define ISC_SAMA7G5_SUB420_OFFSET
/* Subsampling 4:2:2 to 4:2:0 Control Register */
#define ISC_SUB420_CTRL

/* Offset for RLP register specific to sama5d2 product */
#define ISC_SAMA5D2_RLP_OFFSET
/* Offset for RLP register specific to sama7g5 product */
#define ISC_SAMA7G5_RLP_OFFSET
/* Rounding, Limiting and Packing Configuration Register */
#define ISC_RLP_CFG

#define ISC_RLP_CFG_MODE_DAT8
#define ISC_RLP_CFG_MODE_DAT9
#define ISC_RLP_CFG_MODE_DAT10
#define ISC_RLP_CFG_MODE_DAT11
#define ISC_RLP_CFG_MODE_DAT12
#define ISC_RLP_CFG_MODE_DATY8
#define ISC_RLP_CFG_MODE_DATY10
#define ISC_RLP_CFG_MODE_ARGB444
#define ISC_RLP_CFG_MODE_ARGB555
#define ISC_RLP_CFG_MODE_RGB565
#define ISC_RLP_CFG_MODE_ARGB32
#define ISC_RLP_CFG_MODE_YYCC
#define ISC_RLP_CFG_MODE_YYCC_LIMITED
#define ISC_RLP_CFG_MODE_YCYC
#define ISC_RLP_CFG_MODE_MASK

#define ISC_RLP_CFG_LSH

#define ISC_RLP_CFG_YMODE_YUYV
#define ISC_RLP_CFG_YMODE_YVYU
#define ISC_RLP_CFG_YMODE_VYUY
#define ISC_RLP_CFG_YMODE_UYVY

#define ISC_RLP_CFG_YMODE_MASK

/* Offset for HIS register specific to sama5d2 product */
#define ISC_SAMA5D2_HIS_OFFSET
/* Offset for HIS register specific to sama7g5 product */
#define ISC_SAMA7G5_HIS_OFFSET
/* Histogram Control Register */
#define ISC_HIS_CTRL

#define ISC_HIS_CTRL_EN
#define ISC_HIS_CTRL_DIS

/* Histogram Configuration Register */
#define ISC_HIS_CFG

#define ISC_HIS_CFG_MODE_GR
#define ISC_HIS_CFG_MODE_R
#define ISC_HIS_CFG_MODE_GB
#define ISC_HIS_CFG_MODE_B
#define ISC_HIS_CFG_MODE_Y
#define ISC_HIS_CFG_MODE_RAW
#define ISC_HIS_CFG_MODE_YCCIR656

#define ISC_HIS_CFG_BAYSEL_SHIFT

#define ISC_HIS_CFG_RAR

/* Offset for DMA register specific to sama5d2 product */
#define ISC_SAMA5D2_DMA_OFFSET
/* Offset for DMA register specific to sama7g5 product */
#define ISC_SAMA7G5_DMA_OFFSET

/* DMA Configuration Register */
#define ISC_DCFG
#define ISC_DCFG_IMODE_PACKED8
#define ISC_DCFG_IMODE_PACKED16
#define ISC_DCFG_IMODE_PACKED32
#define ISC_DCFG_IMODE_YC422SP
#define ISC_DCFG_IMODE_YC422P
#define ISC_DCFG_IMODE_YC420SP
#define ISC_DCFG_IMODE_YC420P
#define ISC_DCFG_IMODE_MASK

#define ISC_DCFG_YMBSIZE_SINGLE
#define ISC_DCFG_YMBSIZE_BEATS4
#define ISC_DCFG_YMBSIZE_BEATS8
#define ISC_DCFG_YMBSIZE_BEATS16
#define ISC_DCFG_YMBSIZE_BEATS32
#define ISC_DCFG_YMBSIZE_MASK

#define ISC_DCFG_CMBSIZE_SINGLE
#define ISC_DCFG_CMBSIZE_BEATS4
#define ISC_DCFG_CMBSIZE_BEATS8
#define ISC_DCFG_CMBSIZE_BEATS16
#define ISC_DCFG_CMBSIZE_BEATS32
#define ISC_DCFG_CMBSIZE_MASK

/* DMA Control Register */
#define ISC_DCTRL

#define ISC_DCTRL_DVIEW_PACKED
#define ISC_DCTRL_DVIEW_SEMIPLANAR
#define ISC_DCTRL_DVIEW_PLANAR
#define ISC_DCTRL_DVIEW_MASK

#define ISC_DCTRL_IE_IS

/* DMA Descriptor Address Register */
#define ISC_DNDA

/* DMA Address 0 Register */
#define ISC_DAD0

/* DMA Address 1 Register */
#define ISC_DAD1

/* DMA Address 2 Register */
#define ISC_DAD2

/* Offset for version register specific to sama5d2 product */
#define ISC_SAMA5D2_VERSION_OFFSET
#define ISC_SAMA7G5_VERSION_OFFSET
/* Version Register */
#define ISC_VERSION

/* Offset for version register specific to sama5d2 product */
#define ISC_SAMA5D2_HIS_ENTRY_OFFSET
/* Offset for version register specific to sama7g5 product */
#define ISC_SAMA7G5_HIS_ENTRY_OFFSET
/* Histogram Entry */
#define ISC_HIS_ENTRY

#endif