Merge tag 'riscv-for-linus-4.15-rc2_cleanups' of git://git.kernel.org/pub/scm/linux...
[linux/fpc-iii.git] / drivers / isdn / hardware / eicon / xdi_msg.h
blob0646079bf466bff44593ef2f4fe9f2aabd47d489
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /* $Id: xdi_msg.h,v 1.1.2.2 2001/02/16 08:40:36 armin Exp $ */
4 #ifndef __DIVA_XDI_UM_CFG_MESSAGE_H__
5 #define __DIVA_XDI_UM_CFG_MESSAGE_H__
7 /*
8 Definition of messages used to communicate between
9 XDI device driver and user mode configuration utility
13 As acknowledge one DWORD - card ordinal will be read from the card
15 #define DIVA_XDI_UM_CMD_GET_CARD_ORDINAL 0
18 no acknowledge will be generated, memory block will be written in the
19 memory at given offset
21 #define DIVA_XDI_UM_CMD_WRITE_SDRAM_BLOCK 1
24 no acknowledge will be genatated, FPGA will be programmed
26 #define DIVA_XDI_UM_CMD_WRITE_FPGA 2
29 As acknowledge block of SDRAM will be read in the user buffer
31 #define DIVA_XDI_UM_CMD_READ_SDRAM 3
34 As acknowledge dword with serial number will be read in the user buffer
36 #define DIVA_XDI_UM_CMD_GET_SERIAL_NR 4
39 As acknowledge struct consisting from 9 dwords with PCI info.
40 dword[0...7] = 8 PCI BARS
41 dword[9] = IRQ
43 #define DIVA_XDI_UM_CMD_GET_PCI_HW_CONFIG 5
46 Reset of the board + activation of primary
47 boot loader
49 #define DIVA_XDI_UM_CMD_RESET_ADAPTER 6
52 Called after code download to start adapter
53 at specified address
54 Start does set new set of features due to fact that we not know
55 if protocol features have changed
57 #define DIVA_XDI_UM_CMD_START_ADAPTER 7
60 Stop adapter, called if user
61 wishes to stop adapter without unload
62 of the driver, to reload adapter with
63 different protocol
65 #define DIVA_XDI_UM_CMD_STOP_ADAPTER 8
68 Get state of current adapter
69 Acknowledge is one dword with following values:
70 0 - adapter ready for download
71 1 - adapter running
72 2 - adapter dead
73 3 - out of service, driver should be restarted or hardware problem
75 #define DIVA_XDI_UM_CMD_GET_CARD_STATE 9
78 Reads XLOG entry from the card
80 #define DIVA_XDI_UM_CMD_READ_XLOG_ENTRY 10
83 Set untranslated protocol code features
85 #define DIVA_XDI_UM_CMD_SET_PROTOCOL_FEATURES 11
87 typedef struct _diva_xdi_um_cfg_cmd_data_set_features {
88 dword features;
89 } diva_xdi_um_cfg_cmd_data_set_features_t;
91 typedef struct _diva_xdi_um_cfg_cmd_data_start {
92 dword offset;
93 dword features;
94 } diva_xdi_um_cfg_cmd_data_start_t;
96 typedef struct _diva_xdi_um_cfg_cmd_data_write_sdram {
97 dword ram_number;
98 dword offset;
99 dword length;
100 } diva_xdi_um_cfg_cmd_data_write_sdram_t;
102 typedef struct _diva_xdi_um_cfg_cmd_data_write_fpga {
103 dword fpga_number;
104 dword image_length;
105 } diva_xdi_um_cfg_cmd_data_write_fpga_t;
107 typedef struct _diva_xdi_um_cfg_cmd_data_read_sdram {
108 dword ram_number;
109 dword offset;
110 dword length;
111 } diva_xdi_um_cfg_cmd_data_read_sdram_t;
113 typedef union _diva_xdi_um_cfg_cmd_data {
114 diva_xdi_um_cfg_cmd_data_write_sdram_t write_sdram;
115 diva_xdi_um_cfg_cmd_data_write_fpga_t write_fpga;
116 diva_xdi_um_cfg_cmd_data_read_sdram_t read_sdram;
117 diva_xdi_um_cfg_cmd_data_start_t start;
118 diva_xdi_um_cfg_cmd_data_set_features_t features;
119 } diva_xdi_um_cfg_cmd_data_t;
121 typedef struct _diva_xdi_um_cfg_cmd {
122 dword adapter; /* Adapter number 1...N */
123 dword command;
124 diva_xdi_um_cfg_cmd_data_t command_data;
125 dword data_length; /* Plain binary data will follow */
126 } diva_xdi_um_cfg_cmd_t;
128 #endif