treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / drivers / net / fddi / skfp / h / targethw.h
blob40f86007bc47abea61f86626d3a5975c93f81e22
1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /******************************************************************************
4 * (C)Copyright 1998,1999 SysKonnect,
5 * a business unit of Schneider & Koch & Co. Datensysteme GmbH.
7 * The information in this file is provided "AS IS" without warranty.
9 ******************************************************************************/
11 #ifndef _TARGETHW_
12 #define _TARGETHW_
15 * PCI Watermark definition
17 #ifdef PCI
18 #define RX_WATERMARK 24
19 #define TX_WATERMARK 24
20 #define SK_ML_ID_1 0x20
21 #define SK_ML_ID_2 0x30
22 #endif
24 #include "skfbi.h"
25 #ifndef TAG_MODE
26 #include "fplus.h"
27 #else
28 #include "fplustm.h"
29 #endif
31 #ifndef HW_PTR
32 #define HW_PTR void __iomem *
33 #endif
35 #ifdef MULT_OEM
36 #define OI_STAT_LAST 0 /* end of OEM data base */
37 #define OI_STAT_PRESENT 1 /* entry present but not empty */
38 #define OI_STAT_VALID 2 /* holds valid ID, but is not active */
39 #define OI_STAT_ACTIVE 3 /* holds valid ID, entry is active */
40 /* active = adapter is supported */
42 /* Memory representation of IDs must match representation in adapter. */
43 struct s_oem_ids {
44 u_char oi_status ; /* Stat: last, present, valid, active */
45 u_char oi_mark[5] ; /* "PID00" .. "PID07" .. */
46 u_char oi_id[4] ; /* id bytes, representation as */
47 /* defined by hardware, */
48 #ifdef PCI
49 u_char oi_sub_id[4] ; /* sub id bytes, representation as */
50 /* defined by hardware, */
51 #endif
52 } ;
53 #endif /* MULT_OEM */
56 struct s_smt_hw {
58 * global
60 HW_PTR iop ; /* IO base address */
61 short dma ; /* DMA channel */
62 short irq ; /* IRQ level */
63 short eprom ; /* FLASH prom */
65 #ifndef SYNC
66 u_short n_a_send ; /* pending send requests */
67 #endif
69 #if defined(PCI)
70 short slot ; /* slot number */
71 short max_slots ; /* maximum number of slots */
72 short wdog_used ; /* TRUE if the watch dog is used */
73 #endif
75 #ifdef PCI
76 u_short pci_handle ; /* handle to access the BIOS func */
77 u_long is_imask ; /* int maske for the int source reg */
78 u_long phys_mem_addr ; /* physical memory address */
79 u_short mc_dummy ; /* work around for MC compiler bug */
81 * state of the hardware
83 u_short hw_state ; /* started or stopped */
85 #define STARTED 1
86 #define STOPPED 0
88 int hw_is_64bit ; /* does we have a 64 bit adapter */
89 #endif
91 #ifdef TAG_MODE
92 u_long pci_fix_value ; /* value parsed by PCIFIX */
93 #endif
96 * hwt.c
98 u_long t_start ; /* HWT start */
99 u_long t_stop ; /* HWT stop */
100 u_short timer_activ ; /* HWT timer active */
103 * PIC
105 u_char pic_a1 ;
106 u_char pic_21 ;
109 * GENERIC ; do not modify beyond this line
113 * physical and canonical address
115 struct fddi_addr fddi_home_addr ;
116 struct fddi_addr fddi_canon_addr ;
117 struct fddi_addr fddi_phys_addr ;
120 * mac variables
122 struct mac_parameter mac_pa ; /* tmin, tmax, tvx, treq .. */
123 struct mac_counter mac_ct ; /* recv., lost, error */
124 u_short mac_ring_is_up ; /* ring is up flag */
126 struct s_smt_fp fp ; /* formac+ */
128 #ifdef MULT_OEM
129 struct s_oem_ids *oem_id ; /* pointer to selected id */
130 int oem_min_status ; /* IDs to take care of */
131 #endif /* MULT_OEM */
134 #endif