135 lines · c
1/* SPDX-License-Identifier: GPL-2.0-or-later */2/******************************************************************************3 *4 * (C)Copyright 1998,1999 SysKonnect,5 * a business unit of Schneider & Koch & Co. Datensysteme GmbH.6 *7 * The information in this file is provided "AS IS" without warranty.8 *9 ******************************************************************************/10 11#ifndef _TARGETHW_12#define _TARGETHW_13 14 /*15 * PCI Watermark definition16 */17#ifdef PCI18#define RX_WATERMARK 2419#define TX_WATERMARK 2420#define SK_ML_ID_1 0x2021#define SK_ML_ID_2 0x3022#endif23 24#include "skfbi.h"25#ifndef TAG_MODE 26#include "fplus.h"27#else28#include "fplustm.h"29#endif30 31#ifndef HW_PTR32#define HW_PTR void __iomem *33#endif34 35#ifdef MULT_OEM36#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 */41 42/* Memory representation of IDs must match representation in adapter. */43struct 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 PCI49 u_char oi_sub_id[4] ; /* sub id bytes, representation as */50 /* defined by hardware, */51#endif52} ;53#endif /* MULT_OEM */54 55 56struct s_smt_hw {57 /*58 * global59 */60 HW_PTR iop ; /* IO base address */61 short dma ; /* DMA channel */62 short irq ; /* IRQ level */63 short eprom ; /* FLASH prom */64 65#ifndef SYNC66 u_short n_a_send ; /* pending send requests */67#endif68 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#endif74 75#ifdef PCI76 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 */ 80 /*81 * state of the hardware82 */83 u_short hw_state ; /* started or stopped */84 85#define STARTED 186#define STOPPED 087 88 int hw_is_64bit ; /* does we have a 64 bit adapter */89#endif90 91#ifdef TAG_MODE92 u_long pci_fix_value ; /* value parsed by PCIFIX */93#endif94 95 /*96 * hwt.c97 */98 u_long t_start ; /* HWT start */99 u_long t_stop ; /* HWT stop */100 u_short timer_activ ; /* HWT timer active */101 102 /*103 * PIC104 */105 u_char pic_a1 ;106 u_char pic_21 ;107 108 /*109 * GENERIC ; do not modify beyond this line110 */111 112 /*113 * physical and canonical address114 */115 struct fddi_addr fddi_home_addr ;116 struct fddi_addr fddi_canon_addr ;117 struct fddi_addr fddi_phys_addr ;118 119 /*120 * mac variables121 */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 */125 126 struct s_smt_fp fp ; /* formac+ */127 128#ifdef MULT_OEM129 struct s_oem_ids *oem_id ; /* pointer to selected id */130 int oem_min_status ; /* IDs to take care of */131#endif /* MULT_OEM */132 133} ;134#endif135