linux/drivers/media/pci/netup_unidvb/netup_unidvb.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 * netup_unidvb.h
 *
 * Data type definitions for NetUP Universal Dual DVB-CI
 *
 * Copyright (C) 2014 NetUP Inc.
 * Copyright (C) 2014 Sergey Kozlov <[email protected]>
 * Copyright (C) 2014 Abylay Ospan <[email protected]>
 */

#include <linux/pci.h>
#include <linux/i2c.h>
#include <linux/workqueue.h>
#include <media/v4l2-common.h>
#include <media/v4l2-device.h>
#include <media/videobuf2-dvb.h>
#include <media/dvb_ca_en50221.h>

#define NETUP_UNIDVB_NAME
#define NETUP_UNIDVB_VERSION
#define NETUP_VENDOR_ID
#define NETUP_PCI_DEV_REVISION

/* IRQ-related regisers */
#define REG_ISR
#define REG_ISR_MASKED
#define REG_IMASK_SET
#define REG_IMASK_CLEAR
/* REG_ISR register bits */
#define NETUP_UNIDVB_IRQ_SPI
#define NETUP_UNIDVB_IRQ_I2C0
#define NETUP_UNIDVB_IRQ_I2C1
#define NETUP_UNIDVB_IRQ_FRA0
#define NETUP_UNIDVB_IRQ_FRA1
#define NETUP_UNIDVB_IRQ_FRB0
#define NETUP_UNIDVB_IRQ_FRB1
#define NETUP_UNIDVB_IRQ_DMA1
#define NETUP_UNIDVB_IRQ_DMA2
#define NETUP_UNIDVB_IRQ_CI
#define NETUP_UNIDVB_IRQ_CAM0
#define NETUP_UNIDVB_IRQ_CAM1

/* NetUP Universal DVB card hardware revisions and it's PCI device id's:
 * 1.3 - CXD2841ER demod, ASCOT2E and HORUS3A tuners
 * 1.4 - CXD2854ER demod, HELENE tuner
*/
enum netup_hw_rev {};

struct netup_dma {};

enum netup_i2c_state {};

struct netup_i2c_regs;

struct netup_i2c {};

struct netup_ci_state {};

struct netup_spi;

struct netup_unidvb_dev {};

int netup_i2c_register(struct netup_unidvb_dev *ndev);
void netup_i2c_unregister(struct netup_unidvb_dev *ndev);
irqreturn_t netup_ci_interrupt(struct netup_unidvb_dev *ndev);
irqreturn_t netup_i2c_interrupt(struct netup_i2c *i2c);
irqreturn_t netup_spi_interrupt(struct netup_spi *spi);
int netup_unidvb_ci_register(struct netup_unidvb_dev *dev,
			     int num, struct pci_dev *pci_dev);
void netup_unidvb_ci_unregister(struct netup_unidvb_dev *dev, int num);
int netup_spi_init(struct netup_unidvb_dev *ndev);
void netup_spi_release(struct netup_unidvb_dev *ndev);