linux/drivers/media/usb/au0828/au0828.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 *  Driver for the Auvitek AU0828 USB bridge
 *
 *  Copyright (c) 2008 Steven Toth <[email protected]>
 */

#define pr_fmt(fmt)

#include <linux/bitops.h>
#include <linux/usb.h>
#include <linux/i2c.h>
#include <linux/i2c-algo-bit.h>
#include <media/tveeprom.h>

/* Analog */
#include <linux/videodev2.h>
#include <media/videobuf2-v4l2.h>
#include <media/videobuf2-vmalloc.h>
#include <media/v4l2-device.h>
#include <media/v4l2-ctrls.h>
#include <media/v4l2-fh.h>
#include <media/media-device.h>
#include <media/media-dev-allocator.h>

/* DVB */
#include <media/demux.h>
#include <media/dmxdev.h>
#include <media/dvb_demux.h>
#include <media/dvb_frontend.h>
#include <media/dvb_net.h>
#include <media/dvbdev.h>

#include "au0828-reg.h"
#include "au0828-cards.h"

#define URB_COUNT
#define URB_BUFSIZE

/* Analog constants */
#define NTSC_STD_W
#define NTSC_STD_H

#define AU0828_INTERLACED_DEFAULT

/* Definition for AU0828 USB transfer */
#define AU0828_MAX_ISO_BUFS
#define AU0828_ISO_PACKETS_PER_URB

#define AU0828_MIN_BUF
#define AU0828_DEF_BUF

#define AU0828_MAX_INPUT

/* au0828 resource types (used for res_get/res_lock etc */
#define AU0828_RESOURCE_VIDEO
#define AU0828_RESOURCE_VBI

enum au0828_itype {};

struct au0828_input {};

struct au0828_board {};

struct au0828_dvb {};

enum au0828_stream_state {};

#define AUVI_INPUT(nr)

/* device state */
enum au0828_dev_state {};

struct au0828_dev;

struct au0828_usb_isoc_ctl {};

/* buffer for one video frame */
struct au0828_buffer {};

struct au0828_dmaqueue {};

struct au0828_dev {};


/* ----------------------------------------------------------- */
#define au0828_read(dev, reg)
#define au0828_write(dev, reg, value)
#define au0828_andor(dev, reg, mask, value)

#define au0828_set(dev, reg, bit)
#define au0828_clear(dev, reg, bit)

/* ----------------------------------------------------------- */
/* au0828-core.c */
extern u32 au0828_read(struct au0828_dev *dev, u16 reg);
extern u32 au0828_write(struct au0828_dev *dev, u16 reg, u32 val);
extern void au0828_usb_release(struct au0828_dev *dev);
extern int au0828_debug;

/* ----------------------------------------------------------- */
/* au0828-cards.c */
extern struct au0828_board au0828_boards[];
extern struct usb_device_id au0828_usb_id_table[];
extern void au0828_gpio_setup(struct au0828_dev *dev);
extern int au0828_tuner_callback(void *priv, int component,
				 int command, int arg);
extern void au0828_card_setup(struct au0828_dev *dev);

/* ----------------------------------------------------------- */
/* au0828-i2c.c */
extern int au0828_i2c_register(struct au0828_dev *dev);
extern int au0828_i2c_unregister(struct au0828_dev *dev);

/* ----------------------------------------------------------- */
/* au0828-video.c */
extern int au0828_start_analog_streaming(struct vb2_queue *vq,
						unsigned int count);
extern void au0828_stop_vbi_streaming(struct vb2_queue *vq);
#ifdef CONFIG_VIDEO_AU0828_V4L2
extern int au0828_v4l2_device_register(struct usb_interface *interface,
				      struct au0828_dev *dev);

extern int au0828_analog_register(struct au0828_dev *dev,
			   struct usb_interface *interface);
extern int au0828_analog_unregister(struct au0828_dev *dev);
extern void au0828_usb_v4l2_media_release(struct au0828_dev *dev);
extern void au0828_v4l2_suspend(struct au0828_dev *dev);
extern void au0828_v4l2_resume(struct au0828_dev *dev);
#else
static inline int au0828_v4l2_device_register(struct usb_interface *interface,
					      struct au0828_dev *dev)
{ return 0; };
static inline int au0828_analog_register(struct au0828_dev *dev,
				     struct usb_interface *interface)
{ return 0; };
static inline int au0828_analog_unregister(struct au0828_dev *dev)
{ return 0; };
static inline void au0828_usb_v4l2_media_release(struct au0828_dev *dev) { };
static inline void au0828_v4l2_suspend(struct au0828_dev *dev) { };
static inline void au0828_v4l2_resume(struct au0828_dev *dev) { };
#endif

/* ----------------------------------------------------------- */
/* au0828-dvb.c */
extern int au0828_dvb_register(struct au0828_dev *dev);
extern void au0828_dvb_unregister(struct au0828_dev *dev);
void au0828_dvb_suspend(struct au0828_dev *dev);
void au0828_dvb_resume(struct au0828_dev *dev);

/* au0828-vbi.c */
extern const struct vb2_ops au0828_vbi_qops;

#define dprintk(level, fmt, arg...)

/* au0828-input.c */
#ifdef CONFIG_VIDEO_AU0828_RC
extern int au0828_rc_register(struct au0828_dev *dev);
extern void au0828_rc_unregister(struct au0828_dev *dev);
extern int au0828_rc_suspend(struct au0828_dev *dev);
extern int au0828_rc_resume(struct au0828_dev *dev);
#else
static inline int au0828_rc_register(struct au0828_dev *dev) { return 0; }
static inline void au0828_rc_unregister(struct au0828_dev *dev) { }
static inline int au0828_rc_suspend(struct au0828_dev *dev) { return 0; }
static inline int au0828_rc_resume(struct au0828_dev *dev) { return 0; }
#endif