treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 118
[linux-block.git] / drivers / media / usb / as102 / as10x_handle.h
CommitLineData
3e0a4e85 1/* SPDX-License-Identifier: GPL-2.0-or-later */
41b44e04
PH
2/*
3 * Abilis Systems Single DVB-T Receiver
4 * Copyright (C) 2008 Pierrick Hascoet <pierrick.hascoet@abilis.com>
41b44e04 5 */
47f79129
MCC
6#ifndef _AS10X_HANDLE_H
7#define _AS10X_HANDLE_H
34490a0a 8struct as10x_bus_adapter_t;
41b44e04
PH
9struct as102_dev_t;
10
41b44e04
PH
11#include "as10x_cmd.h"
12
13/* values for "mode" field */
14e0e4bf
SN
14#define REGMODE8 8
15#define REGMODE16 16
16#define REGMODE32 32
41b44e04
PH
17
18struct as102_priv_ops_t {
8e3a3ce6 19 int (*upload_fw_pkt)(struct as10x_bus_adapter_t *bus_adap,
41b44e04
PH
20 unsigned char *buf, int buflen, int swap32);
21
8e3a3ce6 22 int (*send_cmd)(struct as10x_bus_adapter_t *bus_adap,
41b44e04
PH
23 unsigned char *buf, int buflen);
24
8e3a3ce6 25 int (*xfer_cmd)(struct as10x_bus_adapter_t *bus_adap,
41b44e04
PH
26 unsigned char *send_buf, int send_buf_len,
27 unsigned char *recv_buf, int recv_buf_len);
34490a0a 28
8e3a3ce6
AO
29 int (*start_stream)(struct as102_dev_t *dev);
30 void (*stop_stream)(struct as102_dev_t *dev);
41b44e04 31
8e3a3ce6 32 int (*reset_target)(struct as10x_bus_adapter_t *bus_adap);
41b44e04 33
34490a0a 34 int (*read_write)(struct as10x_bus_adapter_t *bus_adap, uint8_t mode,
41b44e04
PH
35 uint32_t rd_addr, uint16_t rd_len,
36 uint32_t wr_addr, uint16_t wr_len);
37
8e3a3ce6 38 int (*as102_read_ep2)(struct as10x_bus_adapter_t *bus_adap,
41b44e04
PH
39 unsigned char *recv_buf,
40 int recv_buf_len);
41};
42#endif