linux/drivers/media/pci/zoran/zr36060.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 * Zoran ZR36060 basic configuration functions - header file
 *
 * Copyright (C) 2002 Laurent Pinchart <[email protected]>
 */

#ifndef ZR36060_H
#define ZR36060_H

#include "videocodec.h"

/* data stored for each zoran jpeg codec chip */
struct zr36060 {};

/* ZR36060 register addresses */
#define ZR060_LOAD
#define ZR060_CFSR
#define ZR060_CIR
#define ZR060_CMR
#define ZR060_MBZ
#define ZR060_MBCVR
#define ZR060_MER
#define ZR060_IMR
#define ZR060_ISR
#define ZR060_TCV_NET_HI
#define ZR060_TCV_NET_MH
#define ZR060_TCV_NET_ML
#define ZR060_TCV_NET_LO
#define ZR060_TCV_DATA_HI
#define ZR060_TCV_DATA_MH
#define ZR060_TCV_DATA_ML
#define ZR060_TCV_DATA_LO
#define ZR060_SF_HI
#define ZR060_SF_LO
#define ZR060_AF_HI
#define ZR060_AF_M
#define ZR060_AF_LO
#define ZR060_ACV_HI
#define ZR060_ACV_MH
#define ZR060_ACV_ML
#define ZR060_ACV_LO
#define ZR060_ACT_HI
#define ZR060_ACT_MH
#define ZR060_ACT_ML
#define ZR060_ACT_LO
#define ZR060_ACV_TURN_HI
#define ZR060_ACV_TURN_MH
#define ZR060_ACV_TURN_ML
#define ZR060_ACV_TURN_LO
#define ZR060_IDR_DEV
#define ZR060_IDR_REV
#define ZR060_TCR_HI
#define ZR060_TCR_LO
#define ZR060_VCR
#define ZR060_VPR
#define ZR060_SR
#define ZR060_BCR_Y
#define ZR060_BCR_U
#define ZR060_BCR_V
#define ZR060_SGR_VTOTAL_HI
#define ZR060_SGR_VTOTAL_LO
#define ZR060_SGR_HTOTAL_HI
#define ZR060_SGR_HTOTAL_LO
#define ZR060_SGR_VSYNC
#define ZR060_SGR_HSYNC
#define ZR060_SGR_BVSTART
#define ZR060_SGR_BHSTART
#define ZR060_SGR_BVEND_HI
#define ZR060_SGR_BVEND_LO
#define ZR060_SGR_BHEND_HI
#define ZR060_SGR_BHEND_LO
#define ZR060_AAR_VSTART_HI
#define ZR060_AAR_VSTART_LO
#define ZR060_AAR_VEND_HI
#define ZR060_AAR_VEND_LO
#define ZR060_AAR_HSTART_HI
#define ZR060_AAR_HSTART_LO
#define ZR060_AAR_HEND_HI
#define ZR060_AAR_HEND_LO
#define ZR060_SWR_VSTART_HI
#define ZR060_SWR_VSTART_LO
#define ZR060_SWR_VEND_HI
#define ZR060_SWR_VEND_LO
#define ZR060_SWR_HSTART_HI
#define ZR060_SWR_HSTART_LO
#define ZR060_SWR_HEND_HI
#define ZR060_SWR_HEND_LO

#define ZR060_SOF_IDX
#define ZR060_SOS_IDX
#define ZR060_DRI_IDX
#define ZR060_DQT_IDX
#define ZR060_DHT_IDX
#define ZR060_APP_IDX
#define ZR060_COM_IDX

/* ZR36060 LOAD register bits */

#define ZR060_LOAD_LOAD
#define ZR060_LOAD_SYNC_RST

/* ZR36060 Code FIFO Status register bits */

#define ZR060_CFSR_BUSY
#define ZR060_CFSR_C_BUSY
#define ZR060_CFSR_CFIFO

/* ZR36060 Code Interface register */

#define ZR060_CIR_CODE16
#define ZR060_CIR_ENDIAN
#define ZR060_CIR_CFIS
#define ZR060_CIR_CODE_MSTR

/* ZR36060 Codec Mode register */

#define ZR060_CMR_COMP
#define ZR060_CMR_ATP
#define ZR060_CMR_PASS2
#define ZR060_CMR_TLM
#define ZR060_CMR_BRB
#define ZR060_CMR_FSF

/* ZR36060 Markers Enable register */

#define ZR060_MER_APP
#define ZR060_MER_COM
#define ZR060_MER_DRI
#define ZR060_MER_DQT
#define ZR060_MER_DHT

/* ZR36060 Interrupt Mask register */

#define ZR060_IMR_EOAV
#define ZR060_IMR_EOI
#define ZR060_IMR_END
#define ZR060_IMR_DATA_ERR

/* ZR36060 Interrupt Status register */

#define ZR060_ISR_PRO_CNT
#define ZR060_ISR_EOAV
#define ZR060_ISR_EOI
#define ZR060_ISR_END
#define ZR060_ISR_DATA_ERR

/* ZR36060 Video Control register */

#define ZR060_VCR_VIDEO8
#define ZR060_VCR_RANGE
#define ZR060_VCR_FI_DET
#define ZR060_VCR_FI_VEDGE
#define ZR060_VCR_FI_EXT
#define ZR060_VCR_SYNC_MSTR

/* ZR36060 Video Polarity register */

#define ZR060_VPR_VCLK_POL
#define ZR060_VPR_P_VAL_POL
#define ZR060_VPR_POE_POL
#define ZR060_VPR_S_IMG_POL
#define ZR060_VPR_BL_POL
#define ZR060_VPR_FI_POL
#define ZR060_VPR_HS_POL
#define ZR060_VPR_VS_POL

/* ZR36060 Scaling register */

#define ZR060_SR_V_SCALE
#define ZR060_SR_H_SCALE2
#define ZR060_SR_H_SCALE4

int zr36060_init_module(void);
void zr36060_cleanup_module(void);
#endif				/*fndef ZR36060_H */