Home | History | Annotate | Line # | Download | only in pci
hifn7751var.h revision 1.2.2.5
      1  1.2.2.5   skrll /*	$NetBSD: hifn7751var.h,v 1.2.2.5 2005/11/10 14:06:01 skrll Exp $	*/
      2      1.1  itojun /*	$OpenBSD: hifn7751var.h,v 1.18 2000/06/02 22:36:45 deraadt Exp $	*/
      3      1.1  itojun 
      4      1.1  itojun /*
      5  1.2.2.1   skrll  * Invertex AEON / Hifn 7751 driver
      6      1.1  itojun  * Copyright (c) 1999 Invertex Inc. All rights reserved.
      7      1.1  itojun  * Copyright (c) 1999 Theo de Raadt
      8  1.2.2.1   skrll  * Copyright (c) 2000-2001 Network Security Technologies, Inc.
      9      1.1  itojun  *			http://www.netsec.net
     10      1.1  itojun  *
     11      1.1  itojun  * Please send any comments, feedback, bug-fixes, or feature requests to
     12      1.1  itojun  * software (at) invertex.com.
     13      1.1  itojun  *
     14      1.1  itojun  * Redistribution and use in source and binary forms, with or without
     15      1.1  itojun  * modification, are permitted provided that the following conditions
     16      1.1  itojun  * are met:
     17      1.1  itojun  *
     18      1.1  itojun  * 1. Redistributions of source code must retain the above copyright
     19      1.1  itojun  *    notice, this list of conditions and the following disclaimer.
     20      1.1  itojun  * 2. Redistributions in binary form must reproduce the above copyright
     21      1.1  itojun  *    notice, this list of conditions and the following disclaimer in the
     22      1.1  itojun  *    documentation and/or other materials provided with the distribution.
     23      1.1  itojun  * 3. The name of the author may not be used to endorse or promote products
     24      1.1  itojun  *    derived from this software without specific prior written permission.
     25      1.1  itojun  *
     26      1.1  itojun  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
     27      1.1  itojun  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
     28      1.1  itojun  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
     29      1.1  itojun  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
     30      1.1  itojun  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
     31      1.1  itojun  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
     32      1.1  itojun  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
     33      1.1  itojun  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
     34      1.1  itojun  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
     35      1.1  itojun  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
     36      1.1  itojun  *
     37  1.2.2.1   skrll  * Effort sponsored in part by the Defense Advanced Research Projects
     38  1.2.2.1   skrll  * Agency (DARPA) and Air Force Research Laboratory, Air Force
     39  1.2.2.1   skrll  * Materiel Command, USAF, under agreement number F30602-01-2-0537.
     40  1.2.2.1   skrll  *
     41      1.1  itojun  */
     42      1.1  itojun 
     43      1.1  itojun #ifndef __DEV_PCI_HIFN7751VAR_H__
     44      1.1  itojun #define __DEV_PCI_HIFN7751VAR_H__
     45      1.1  itojun 
     46  1.2.2.1   skrll #ifdef _KERNEL
     47  1.2.2.1   skrll 
     48  1.2.2.1   skrll /*
     49  1.2.2.1   skrll  *  Some configurable values for the driver
     50  1.2.2.1   skrll  */
     51  1.2.2.1   skrll #define	HIFN_D_CMD_RSIZE	24	/* command descriptors */
     52  1.2.2.1   skrll #define	HIFN_D_SRC_RSIZE	80	/* source descriptors */
     53  1.2.2.1   skrll #define	HIFN_D_DST_RSIZE	80	/* destination descriptors */
     54  1.2.2.1   skrll #define	HIFN_D_RES_RSIZE	24	/* result descriptors */
     55  1.2.2.1   skrll 
     56      1.1  itojun /*
     57      1.1  itojun  *  Length values for cryptography
     58      1.1  itojun  */
     59      1.1  itojun #define HIFN_DES_KEY_LENGTH		8
     60      1.1  itojun #define HIFN_3DES_KEY_LENGTH		24
     61      1.1  itojun #define HIFN_MAX_CRYPT_KEY_LENGTH	HIFN_3DES_KEY_LENGTH
     62      1.1  itojun #define HIFN_IV_LENGTH			8
     63  1.2.2.1   skrll #define	HIFN_AES_IV_LENGTH		16
     64  1.2.2.1   skrll #define HIFN_MAX_IV_LENGTH		HIFN_AES_IV_LENGTH
     65      1.1  itojun 
     66      1.1  itojun /*
     67      1.1  itojun  *  Length values for authentication
     68      1.1  itojun  */
     69      1.1  itojun #define HIFN_MAC_KEY_LENGTH		64
     70      1.1  itojun #define HIFN_MD5_LENGTH			16
     71      1.1  itojun #define HIFN_SHA1_LENGTH		20
     72      1.1  itojun #define HIFN_MAC_TRUNC_LENGTH		12
     73      1.1  itojun 
     74      1.1  itojun #define MAX_SCATTER 64
     75      1.1  itojun 
     76      1.1  itojun /*
     77  1.2.2.1   skrll  * Data structure to hold all 4 rings and any other ring related data.
     78  1.2.2.1   skrll  */
     79  1.2.2.1   skrll struct hifn_dma {
     80  1.2.2.1   skrll 	/*
     81  1.2.2.1   skrll 	 *  Descriptor rings.  We add +1 to the size to accommodate the
     82  1.2.2.1   skrll 	 *  jump descriptor.
     83  1.2.2.1   skrll 	 */
     84  1.2.2.1   skrll 	struct hifn_desc	cmdr[HIFN_D_CMD_RSIZE+1];
     85  1.2.2.1   skrll 	struct hifn_desc	srcr[HIFN_D_SRC_RSIZE+1];
     86  1.2.2.1   skrll 	struct hifn_desc	dstr[HIFN_D_DST_RSIZE+1];
     87  1.2.2.1   skrll 	struct hifn_desc	resr[HIFN_D_RES_RSIZE+1];
     88  1.2.2.1   skrll 
     89  1.2.2.1   skrll 	struct hifn_command	*hifn_commands[HIFN_D_RES_RSIZE];
     90  1.2.2.1   skrll 
     91  1.2.2.1   skrll 	u_char			command_bufs[HIFN_D_CMD_RSIZE][HIFN_MAX_COMMAND];
     92  1.2.2.1   skrll 	u_char			result_bufs[HIFN_D_CMD_RSIZE][HIFN_MAX_RESULT];
     93  1.2.2.1   skrll 	u_int32_t		slop[HIFN_D_CMD_RSIZE];
     94  1.2.2.1   skrll 
     95  1.2.2.1   skrll 	u_int64_t		test_src, test_dst;
     96  1.2.2.1   skrll 
     97  1.2.2.1   skrll 	/*
     98  1.2.2.1   skrll 	 *  Our current positions for insertion and removal from the descriptor
     99  1.2.2.4   skrll 	 *  rings.
    100  1.2.2.1   skrll 	 */
    101  1.2.2.1   skrll 	int			cmdi, srci, dsti, resi;
    102  1.2.2.1   skrll 	volatile int		cmdu, srcu, dstu, resu;
    103  1.2.2.1   skrll 	int			cmdk, srck, dstk, resk;
    104  1.2.2.1   skrll };
    105  1.2.2.1   skrll 
    106  1.2.2.1   skrll struct hifn_session {
    107  1.2.2.1   skrll 	int hs_state;
    108  1.2.2.1   skrll 	int hs_prev_op; /* XXX collapse into hs_flags? */
    109  1.2.2.1   skrll 	u_int8_t hs_iv[HIFN_MAX_IV_LENGTH];
    110  1.2.2.1   skrll };
    111  1.2.2.1   skrll 
    112  1.2.2.1   skrll /* We use a state machine on sessions */
    113  1.2.2.1   skrll #define	HS_STATE_FREE	0		/* unused session entry */
    114  1.2.2.1   skrll #define	HS_STATE_USED	1		/* allocated, but key not on card */
    115  1.2.2.1   skrll #define	HS_STATE_KEY	2		/* allocated and key is on card */
    116  1.2.2.1   skrll 
    117  1.2.2.1   skrll #define	HIFN_RING_SYNC(sc, r, i, f)					\
    118  1.2.2.1   skrll 	bus_dmamap_sync((sc)->sc_dmat, (sc)->sc_dmamap,		\
    119  1.2.2.1   skrll 	    offsetof(struct hifn_dma, r[i]), sizeof(struct hifn_desc), (f))
    120  1.2.2.1   skrll 
    121  1.2.2.1   skrll #define	HIFN_CMDR_SYNC(sc, i, f)	HIFN_RING_SYNC((sc), cmdr, (i), (f))
    122  1.2.2.1   skrll #define	HIFN_RESR_SYNC(sc, i, f)	HIFN_RING_SYNC((sc), resr, (i), (f))
    123  1.2.2.1   skrll #define	HIFN_SRCR_SYNC(sc, i, f)	HIFN_RING_SYNC((sc), srcr, (i), (f))
    124  1.2.2.1   skrll #define	HIFN_DSTR_SYNC(sc, i, f)	HIFN_RING_SYNC((sc), dstr, (i), (f))
    125  1.2.2.1   skrll 
    126  1.2.2.1   skrll #define	HIFN_CMD_SYNC(sc, i, f)						\
    127  1.2.2.1   skrll 	bus_dmamap_sync((sc)->sc_dmat, (sc)->sc_dmamap,		\
    128  1.2.2.1   skrll 	    offsetof(struct hifn_dma, command_bufs[(i)][0]),		\
    129  1.2.2.1   skrll 	    HIFN_MAX_COMMAND, (f))
    130  1.2.2.1   skrll 
    131  1.2.2.1   skrll #define	HIFN_RES_SYNC(sc, i, f)						\
    132  1.2.2.1   skrll 	bus_dmamap_sync((sc)->sc_dmat, (sc)->sc_dmamap,		\
    133  1.2.2.1   skrll 	    offsetof(struct hifn_dma, result_bufs[(i)][0]),		\
    134  1.2.2.1   skrll 	    HIFN_MAX_RESULT, (f))
    135  1.2.2.1   skrll 
    136  1.2.2.1   skrll /*
    137  1.2.2.1   skrll  * Holds data specific to a single HIFN board.
    138  1.2.2.1   skrll  */
    139  1.2.2.1   skrll struct hifn_softc {
    140  1.2.2.1   skrll 	struct device	sc_dv;		/* generic device */
    141  1.2.2.1   skrll 	void *		sc_ih;		/* interrupt handler cookie */
    142  1.2.2.1   skrll 	u_int32_t	sc_dmaier;
    143  1.2.2.1   skrll 	u_int32_t	sc_drammodel;	/* 1=dram, 0=sram */
    144  1.2.2.1   skrll 
    145  1.2.2.1   skrll 	bus_space_handle_t	sc_sh0, sc_sh1;
    146  1.2.2.1   skrll 	bus_space_tag_t		sc_st0, sc_st1;
    147  1.2.2.1   skrll 	bus_dma_tag_t		sc_dmat;
    148  1.2.2.1   skrll 
    149  1.2.2.1   skrll 	struct hifn_dma *sc_dma;
    150  1.2.2.1   skrll 	bus_dmamap_t sc_dmamap;
    151  1.2.2.1   skrll 	bus_dma_segment_t sc_dmasegs[1];
    152  1.2.2.1   skrll 	int sc_dmansegs;
    153  1.2.2.1   skrll 	int32_t sc_cid;
    154  1.2.2.1   skrll 	int sc_maxses;
    155  1.2.2.1   skrll 	int sc_ramsize;
    156  1.2.2.1   skrll 	int sc_flags;
    157  1.2.2.1   skrll #define	HIFN_HAS_RNG		0x01
    158  1.2.2.1   skrll #define	HIFN_HAS_PUBLIC		0x02
    159  1.2.2.1   skrll #define	HIFN_HAS_AES		0x04	/* includes AES support */
    160  1.2.2.1   skrll #define	HIFN_IS_7811		0x08	/* Hifn 7811 part */
    161  1.2.2.1   skrll #define	HIFN_IS_7956		0x10	/* Hifn 7956/7955 don't have SDRAM */
    162  1.2.2.1   skrll #define	HIFN_NO_BURSTWRITE	0x20
    163  1.2.2.1   skrll #define	HIFN_HAS_LEDS		0x40
    164  1.2.2.5   skrll 
    165  1.2.2.5   skrll #define HIFN_RNG_BITSPER	17	/* From Hifn 6500 paper: 0.06 bits
    166  1.2.2.5   skrll 					   of entropy per RNG register bit
    167  1.2.2.5   skrll 					   worst-case */
    168  1.2.2.5   skrll 
    169  1.2.2.1   skrll 	struct callout		sc_rngto;	/* rng timeout */
    170  1.2.2.1   skrll 	struct callout		sc_tickto;	/* led-clear timeout */
    171  1.2.2.5   skrll 	rndsource_element_t	sc_rnd_source;
    172  1.2.2.1   skrll 	int			sc_rngfirst;
    173  1.2.2.1   skrll 	int			sc_rnghz;
    174  1.2.2.1   skrll 	int			sc_c_busy;	/* command ring busy */
    175  1.2.2.1   skrll 	int			sc_s_busy;	/* source data ring busy */
    176  1.2.2.1   skrll 	int			sc_d_busy;	/* destination data ring busy */
    177  1.2.2.1   skrll 	int			sc_r_busy;	/* result ring busy */
    178  1.2.2.1   skrll 	int			sc_active;	/* for initial countdown */
    179  1.2.2.1   skrll 	int			sc_needwakeup;	/* ops q'd wating on resources */
    180  1.2.2.1   skrll 	int			sc_curbatch;	/* # ops submitted w/o int */
    181  1.2.2.1   skrll 	int			sc_suspended;
    182  1.2.2.1   skrll 	struct hifn_session sc_sessions[2048];
    183  1.2.2.1   skrll 	pci_chipset_tag_t sc_pci_pc;
    184  1.2.2.1   skrll 	pcitag_t sc_pci_tag;
    185  1.2.2.1   skrll 	bus_size_t sc_waw_lastreg;
    186  1.2.2.1   skrll 	int sc_waw_lastgroup;
    187  1.2.2.1   skrll };
    188  1.2.2.1   skrll 
    189  1.2.2.1   skrll #define WRITE_REG_0(sc,reg,val)		hifn_write_4((sc), 0, (reg), (val))
    190  1.2.2.1   skrll #define WRITE_REG_1(sc,reg,val)		hifn_write_4((sc), 1, (reg), (val))
    191  1.2.2.1   skrll #define	READ_REG_0(sc,reg)		hifn_read_4((sc), 0, (reg))
    192  1.2.2.1   skrll #define	READ_REG_1(sc,reg)		hifn_read_4((sc), 1, (reg))
    193  1.2.2.1   skrll 
    194  1.2.2.1   skrll #define	SET_LED(sc,v)							\
    195  1.2.2.1   skrll 	if (sc->sc_flags & HIFN_HAS_LEDS)				\
    196  1.2.2.1   skrll 		WRITE_REG_1(sc, HIFN_1_7811_MIPSRST,			\
    197  1.2.2.1   skrll 		    READ_REG_1(sc, HIFN_1_7811_MIPSRST) | (v))
    198  1.2.2.1   skrll #define	CLR_LED(sc,v)							\
    199  1.2.2.1   skrll 	if (sc->sc_flags & HIFN_HAS_LEDS)				\
    200  1.2.2.1   skrll 		WRITE_REG_1(sc, HIFN_1_7811_MIPSRST,			\
    201  1.2.2.1   skrll 		    READ_REG_1(sc, HIFN_1_7811_MIPSRST) & ~(v))
    202  1.2.2.1   skrll 
    203  1.2.2.1   skrll /*
    204  1.2.2.1   skrll  *  struct hifn_command
    205      1.1  itojun  *
    206      1.1  itojun  *  This is the control structure used to pass commands to hifn_encrypt().
    207      1.1  itojun  *
    208      1.1  itojun  *  flags
    209      1.1  itojun  *  -----
    210      1.1  itojun  *  Flags is the bitwise "or" values for command configuration.  A single
    211      1.1  itojun  *  encrypt direction needs to be set:
    212      1.1  itojun  *
    213      1.1  itojun  *	HIFN_ENCODE or HIFN_DECODE
    214      1.1  itojun  *
    215      1.1  itojun  *  To use cryptography, a single crypto algorithm must be included:
    216      1.1  itojun  *
    217      1.1  itojun  *	HIFN_CRYPT_3DES or HIFN_CRYPT_DES
    218      1.1  itojun  *
    219      1.2     wiz  *  To use authentication, a single MAC algorithm must be included:
    220      1.1  itojun  *
    221      1.1  itojun  *	HIFN_MAC_MD5 or HIFN_MAC_SHA1
    222      1.1  itojun  *
    223      1.1  itojun  *  By default MD5 uses a 16 byte hash and SHA-1 uses a 20 byte hash.
    224      1.1  itojun  *  If the value below is set, hash values are truncated or assumed
    225      1.1  itojun  *  truncated to 12 bytes:
    226      1.1  itojun  *
    227      1.1  itojun  *	HIFN_MAC_TRUNC
    228      1.1  itojun  *
    229      1.1  itojun  *  Keys for encryption and authentication can be sent as part of a command,
    230      1.1  itojun  *  or the last key value used with a particular session can be retrieved
    231      1.1  itojun  *  and used again if either of these flags are not specified.
    232      1.1  itojun  *
    233      1.1  itojun  *	HIFN_CRYPT_NEW_KEY, HIFN_MAC_NEW_KEY
    234      1.1  itojun  *
    235      1.1  itojun  *  session_num
    236      1.1  itojun  *  -----------
    237  1.2.2.4   skrll  *  A number between 0 and 2048 (for DRAM models) or a number between
    238      1.1  itojun  *  0 and 768 (for SRAM models).  Those who don't want to use session
    239      1.1  itojun  *  numbers should leave value at zero and send a new crypt key and/or
    240      1.1  itojun  *  new MAC key on every command.  If you use session numbers and
    241      1.1  itojun  *  don't send a key with a command, the last key sent for that same
    242      1.1  itojun  *  session number will be used.
    243      1.1  itojun  *
    244      1.1  itojun  *  Warning:  Using session numbers and multiboard at the same time
    245      1.1  itojun  *            is currently broken.
    246      1.1  itojun  *
    247      1.1  itojun  *  mbuf
    248      1.1  itojun  *  ----
    249      1.1  itojun  *  Either fill in the mbuf pointer and npa=0 or
    250      1.1  itojun  *	 fill packp[] and packl[] and set npa to > 0
    251  1.2.2.4   skrll  *
    252      1.1  itojun  *  mac_header_skip
    253      1.1  itojun  *  ---------------
    254      1.1  itojun  *  The number of bytes of the source_buf that are skipped over before
    255      1.1  itojun  *  authentication begins.  This must be a number between 0 and 2^16-1
    256  1.2.2.1   skrll  *  and can be used by IPsec implementers to skip over IP headers.
    257      1.1  itojun  *  *** Value ignored if authentication not used ***
    258      1.1  itojun  *
    259      1.1  itojun  *  crypt_header_skip
    260      1.1  itojun  *  -----------------
    261      1.1  itojun  *  The number of bytes of the source_buf that are skipped over before
    262      1.1  itojun  *  the cryptographic operation begins.  This must be a number between 0
    263  1.2.2.1   skrll  *  and 2^16-1.  For IPsec, this number will always be 8 bytes larger
    264      1.1  itojun  *  than the auth_header_skip (to skip over the ESP header).
    265      1.1  itojun  *  *** Value ignored if cryptography not used ***
    266      1.1  itojun  *
    267  1.2.2.1   skrll  */
    268  1.2.2.1   skrll struct hifn_command {
    269  1.2.2.1   skrll 	u_int16_t session_num;
    270  1.2.2.1   skrll 	u_int16_t base_masks, cry_masks, mac_masks, comp_masks;
    271  1.2.2.1   skrll 	u_int8_t iv[HIFN_MAX_IV_LENGTH], *ck, mac[HIFN_MAC_KEY_LENGTH];
    272  1.2.2.1   skrll 	int cklen;
    273  1.2.2.1   skrll 	int sloplen, slopidx;
    274  1.2.2.1   skrll 
    275  1.2.2.1   skrll 	union {
    276  1.2.2.1   skrll 		struct mbuf *src_m;
    277  1.2.2.1   skrll 		struct uio *src_io;
    278  1.2.2.1   skrll 	} srcu;
    279  1.2.2.1   skrll 	bus_dmamap_t src_map;
    280  1.2.2.4   skrll 
    281  1.2.2.1   skrll 	union {
    282  1.2.2.1   skrll 		struct mbuf *dst_m;
    283  1.2.2.1   skrll 		struct uio *dst_io;
    284  1.2.2.1   skrll 	} dstu;
    285  1.2.2.1   skrll 	bus_dmamap_t dst_map;
    286      1.1  itojun 
    287      1.1  itojun 	u_short mac_header_skip, mac_process_len;
    288      1.1  itojun 	u_short crypt_header_skip, crypt_process_len;
    289      1.1  itojun 
    290      1.1  itojun 	struct hifn_softc *softc;
    291  1.2.2.1   skrll 	struct cryptop *crp;
    292  1.2.2.1   skrll 	struct cryptodesc *enccrd, *maccrd,  *compcrd;
    293  1.2.2.1   skrll 
    294  1.2.2.1   skrll };
    295      1.1  itojun 
    296      1.1  itojun /*
    297      1.1  itojun  *  Return values for hifn_crypto()
    298      1.1  itojun  */
    299      1.1  itojun #define HIFN_CRYPTO_SUCCESS	0
    300      1.1  itojun #define HIFN_CRYPTO_BAD_INPUT	(-1)
    301      1.1  itojun #define HIFN_CRYPTO_RINGS_FULL	(-2)
    302      1.1  itojun 
    303      1.1  itojun 
    304      1.1  itojun /**************************************************************************
    305      1.1  itojun  *
    306      1.1  itojun  *  Function:  hifn_crypto
    307      1.1  itojun  *
    308      1.1  itojun  *  Purpose:   Called by external drivers to begin an encryption on the
    309      1.1  itojun  *             HIFN board.
    310      1.1  itojun  *
    311      1.1  itojun  *  Blocking/Non-blocking Issues
    312      1.1  itojun  *  ============================
    313      1.1  itojun  *  The driver cannot block in hifn_crypto (no calls to tsleep) currently.
    314      1.1  itojun  *  hifn_crypto() returns HIFN_CRYPTO_RINGS_FULL if there is not enough
    315      1.1  itojun  *  room in any of the rings for the request to proceed.
    316      1.1  itojun  *
    317      1.1  itojun  *  Return Values
    318      1.1  itojun  *  =============
    319      1.1  itojun  *  0 for success, negative values on error
    320      1.1  itojun  *
    321      1.1  itojun  *  Defines for negative error codes are:
    322  1.2.2.4   skrll  *
    323      1.1  itojun  *    HIFN_CRYPTO_BAD_INPUT  :  The passed in command had invalid settings.
    324      1.1  itojun  *    HIFN_CRYPTO_RINGS_FULL :  All DMA rings were full and non-blocking
    325      1.1  itojun  *                              behaviour was requested.
    326      1.1  itojun  *
    327      1.1  itojun  *************************************************************************/
    328      1.1  itojun 
    329      1.1  itojun /*
    330      1.1  itojun  * Convert back and forth from 'sid' to 'card' and 'session'
    331      1.1  itojun  */
    332      1.1  itojun #define HIFN_CARD(sid)		(((sid) & 0xf0000000) >> 28)
    333      1.1  itojun #define HIFN_SESSION(sid)	((sid) & 0x000007ff)
    334      1.1  itojun #define HIFN_SID(crd,ses)	(((crd) << 28) | ((ses) & 0x7ff))
    335      1.1  itojun 
    336      1.1  itojun #endif /* _KERNEL */
    337      1.1  itojun 
    338  1.2.2.1   skrll struct hifn_stats {
    339  1.2.2.1   skrll 	u_int64_t hst_ibytes;
    340  1.2.2.1   skrll 	u_int64_t hst_obytes;
    341  1.2.2.1   skrll 	u_int32_t hst_ipackets;
    342  1.2.2.1   skrll 	u_int32_t hst_opackets;
    343  1.2.2.1   skrll 	u_int32_t hst_invalid;
    344  1.2.2.1   skrll 	u_int32_t hst_nomem;
    345  1.2.2.1   skrll 	u_int32_t hst_abort;
    346  1.2.2.1   skrll };
    347  1.2.2.1   skrll 
    348      1.1  itojun #endif /* __DEV_PCI_HIFN7751VAR_H__ */
    349