xref: /titanic_44/usr/src/uts/common/sys/nxge/nxge_hio.h (revision 0dc2366f7b9f9f36e10909b1e95edbf2a261c2ac)
1678453a8Sspeer /*
2678453a8Sspeer  * CDDL HEADER START
3678453a8Sspeer  *
4678453a8Sspeer  * The contents of this file are subject to the terms of the
5678453a8Sspeer  * Common Development and Distribution License (the "License").
6678453a8Sspeer  * You may not use this file except in compliance with the License.
7678453a8Sspeer  *
8678453a8Sspeer  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9678453a8Sspeer  * or http://www.opensolaris.org/os/licensing.
10678453a8Sspeer  * See the License for the specific language governing permissions
11678453a8Sspeer  * and limitations under the License.
12678453a8Sspeer  *
13678453a8Sspeer  * When distributing Covered Code, include this CDDL HEADER in each
14678453a8Sspeer  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15678453a8Sspeer  * If applicable, add the following below this CDDL HEADER, with the
16678453a8Sspeer  * fields enclosed by brackets "[]" replaced with your own identifying
17678453a8Sspeer  * information: Portions Copyright [yyyy] [name of copyright owner]
18678453a8Sspeer  *
19678453a8Sspeer  * CDDL HEADER END
20678453a8Sspeer  */
21678453a8Sspeer 
22678453a8Sspeer /*
23*0dc2366fSVenugopal Iyer  * Copyright 2010 Sun Microsystems, Inc.  All rights reserved.
24678453a8Sspeer  * Use is subject to license terms.
25678453a8Sspeer  */
26678453a8Sspeer 
27678453a8Sspeer #ifndef	_SYS_NXGE_NXGE_HIO_H
28678453a8Sspeer #define	_SYS_NXGE_NXGE_HIO_H
29678453a8Sspeer 
30678453a8Sspeer #ifdef	__cplusplus
31678453a8Sspeer extern "C" {
32678453a8Sspeer #endif
33678453a8Sspeer 
34678453a8Sspeer #include <nxge_mac.h>
35678453a8Sspeer #include <nxge_ipp.h>
36678453a8Sspeer #include <nxge_fflp.h>
37da14cebeSEric Cheng #include <sys/mac_provider.h>
38678453a8Sspeer 
39678453a8Sspeer #define	isLDOMservice(nxge) \
40678453a8Sspeer 	(nxge->environs == SOLARIS_SERVICE_DOMAIN)
41678453a8Sspeer #define	isLDOMguest(nxge) \
42678453a8Sspeer 	(nxge->environs == SOLARIS_GUEST_DOMAIN)
43678453a8Sspeer #define	isLDOMs(nxge) \
44678453a8Sspeer 	(isLDOMservice(nxge) || isLDOMguest(nxge))
45678453a8Sspeer 
4663f531d1SSriharsha Basavapatna #define	NXGE_HIO_SHARE_MIN_CHANNELS	2
4763f531d1SSriharsha Basavapatna #define	NXGE_HIO_SHARE_MAX_CHANNELS	2
4863f531d1SSriharsha Basavapatna 
49678453a8Sspeer /* ------------------------------------------------------------------ */
50678453a8Sspeer typedef uint8_t nx_rdc_t;
51678453a8Sspeer typedef uint8_t nx_tdc_t;
52678453a8Sspeer 
53678453a8Sspeer typedef uint64_t res_map_t;
54678453a8Sspeer 
55678453a8Sspeer typedef uint64_t hv_rv_t;
56678453a8Sspeer 
57678453a8Sspeer typedef hv_rv_t (*vr_assign)(uint64_t, uint64_t, uint32_t *);
58678453a8Sspeer typedef hv_rv_t (*vr_unassign)(uint32_t);
59678453a8Sspeer typedef hv_rv_t (*vr_getinfo)(uint32_t, uint64_t *, uint64_t *);
60678453a8Sspeer 
614df55fdeSJanie Lu /* HV 2.0 API group functions */
624df55fdeSJanie Lu typedef hv_rv_t (*vr_cfgh_assign)(uint64_t, uint64_t, uint64_t, uint32_t *);
634df55fdeSJanie Lu typedef hv_rv_t (*vrlp_cfgh_conf)(uint64_t, uint64_t, uint64_t, uint64_t,
644df55fdeSJanie Lu     uint64_t);
654df55fdeSJanie Lu typedef hv_rv_t (*vrlp_cfgh_info)(uint64_t, uint64_t, uint64_t, uint64_t *,
664df55fdeSJanie Lu     uint64_t *);
674df55fdeSJanie Lu 
68678453a8Sspeer 
69678453a8Sspeer typedef struct {
704df55fdeSJanie Lu 	vr_assign	assign;		/* HV Major 1 interface */
714df55fdeSJanie Lu 	vr_cfgh_assign	cfgh_assign;	/* HV Major 2 interface */
72678453a8Sspeer 	vr_unassign	unassign;
73678453a8Sspeer 	vr_getinfo	getinfo;
74678453a8Sspeer } nxhv_vr_fp_t;
75678453a8Sspeer 
76678453a8Sspeer typedef hv_rv_t (*vrlp_conf)(uint64_t, uint64_t, uint64_t, uint64_t);
77678453a8Sspeer typedef hv_rv_t (*vrlp_info)(uint64_t, uint64_t, uint64_t *, uint64_t *);
78678453a8Sspeer 
79678453a8Sspeer typedef hv_rv_t (*dc_assign)(uint32_t, uint64_t, uint64_t *);
80678453a8Sspeer typedef hv_rv_t (*dc_unassign)(uint32_t, uint64_t);
81678453a8Sspeer typedef hv_rv_t (*dc_getstate)(uint32_t, uint64_t, uint64_t *);
82678453a8Sspeer typedef hv_rv_t (*dc_get_map)(uint32_t, uint64_t *);
83678453a8Sspeer 
84678453a8Sspeer typedef hv_rv_t (*dc_getinfo)(uint32_t, uint64_t, uint64_t *, uint64_t *);
85678453a8Sspeer 
86678453a8Sspeer typedef struct {
87678453a8Sspeer 	dc_assign	assign;
88678453a8Sspeer 	dc_unassign	unassign;
89678453a8Sspeer 	dc_getstate	getstate;
90678453a8Sspeer 	dc_get_map	get_map;
91678453a8Sspeer 
924df55fdeSJanie Lu 	vrlp_conf	lp_conf;	/* HV Major 1 interface */
934df55fdeSJanie Lu 	vrlp_info	lp_info;	/* HV Major 1 interface */
944df55fdeSJanie Lu 	vrlp_cfgh_conf	lp_cfgh_conf;	/* HV Major 2 interface */
954df55fdeSJanie Lu 	vrlp_cfgh_info	lp_cfgh_info;	/* HV Major 2 interface */
96678453a8Sspeer 	dc_getinfo	getinfo;
97678453a8Sspeer } nxhv_dc_fp_t;
98678453a8Sspeer 
99678453a8Sspeer typedef struct {
100678453a8Sspeer 	boolean_t	ldoms;
101678453a8Sspeer 	nxhv_vr_fp_t	vr;
102678453a8Sspeer 	nxhv_dc_fp_t	tx;
103678453a8Sspeer 	nxhv_dc_fp_t	rx;
104678453a8Sspeer } nxhv_fp_t;
105678453a8Sspeer 
106678453a8Sspeer /* ------------------------------------------------------------------ */
107678453a8Sspeer #define	NXGE_VR_SR_MAX		8 /* There are 8 subregions (SR). */
108678453a8Sspeer 
109678453a8Sspeer typedef enum {
110ef523517SMichael Speer 	NXGE_HIO_TYPE_SERVICE = 0x80,	/* We are a service domain driver. */
111678453a8Sspeer 	NXGE_HIO_TYPE_GUEST		/* We are a guest domain driver. */
112678453a8Sspeer } nxge_hio_type_t;
113678453a8Sspeer 
114678453a8Sspeer typedef enum {
115678453a8Sspeer 	FUNC0_MNT,
116678453a8Sspeer 	FUNC0_VIR = 0x1000000,
117678453a8Sspeer 	FUNC1_MNT = 0x2000000,
118678453a8Sspeer 	FUNC1_VIR = 0x3000000,
119678453a8Sspeer 	FUNC2_MNT = 0x4000000,
120678453a8Sspeer 	FUNC2_VIR = 0x5000000,
121678453a8Sspeer 	FUNC3_MNT = 0x6000000,
122678453a8Sspeer 	FUNC3_VIR = 0x7000000
123678453a8Sspeer } vr_base_address_t;
124678453a8Sspeer 
125678453a8Sspeer #define	VR_STEP		0x2000000
126678453a8Sspeer #define	VR_VC_STEP	0x0004000
127678453a8Sspeer 
128678453a8Sspeer typedef enum {			/* 0-8 */
129678453a8Sspeer 	FUNC0_VIR0,
130678453a8Sspeer 	FUNC0_VIR1,
131678453a8Sspeer 	FUNC1_VIR0,
132678453a8Sspeer 	FUNC1_VIR1,
133678453a8Sspeer 	FUNC2_VIR0,
134678453a8Sspeer 	FUNC2_VIR1,
135678453a8Sspeer 	FUNC3_VIR0,
136678453a8Sspeer 	FUNC3_VIR1,
137678453a8Sspeer 	FUNC_VIR_MAX
138678453a8Sspeer } vr_region_t;
139678453a8Sspeer 
140678453a8Sspeer typedef enum {
141678453a8Sspeer 	VP_CHANNEL_0,
142678453a8Sspeer 	VP_CHANNEL_1,
143678453a8Sspeer 	VP_CHANNEL_2,
144678453a8Sspeer 	VP_CHANNEL_3,
145678453a8Sspeer 	VP_CHANNEL_4,
146678453a8Sspeer 	VP_CHANNEL_5,
147678453a8Sspeer 	VP_CHANNEL_6,
148678453a8Sspeer 	VP_CHANNEL_7,
149678453a8Sspeer 	VP_CHANNEL_MAX
150678453a8Sspeer } vp_channel_t;
151678453a8Sspeer 
152678453a8Sspeer typedef enum {
153e11f0814SMichael Speer 	VP_BOUND_TX = 1,
154678453a8Sspeer 	VP_BOUND_RX
155678453a8Sspeer } vpc_type_t;
156678453a8Sspeer 
157678453a8Sspeer #define	VP_VC_OFFSET(channel)	(channel << 10)
158678453a8Sspeer #define	VP_RDC_OFFSET		(1 << 9)
159678453a8Sspeer 
160678453a8Sspeer typedef enum {
161678453a8Sspeer 	RXDMA_CFIG1		= 0,
162678453a8Sspeer 	RXDMA_CFIG2		= 8,
163678453a8Sspeer 	RBR_CFIG_A		= 0x10,
164678453a8Sspeer 	RBR_CFIG_B		= 0x18,
165678453a8Sspeer 	RBR_KICK		= 0x20,
166678453a8Sspeer 	RBR_STAT		= 0x28,
167678453a8Sspeer 	RBR_HDH			= 0x30,
168678453a8Sspeer 	RBR_HDL			= 0x38,
169678453a8Sspeer 	RCRCFIG_A		= 0x40,
170678453a8Sspeer 	RCRCFIG_B		= 0x48,
171678453a8Sspeer 	RCRSTAT_A		= 0x50,
172678453a8Sspeer 	RCRSTAT_B		= 0x58,
173678453a8Sspeer 	RCRSTAT_C		= 0x60,
174678453a8Sspeer 	RX_DMA_ENT_MSK		= 0x68,
175678453a8Sspeer 	RX_DMA_CTL_STAT		= 0x70,
176678453a8Sspeer 	RCR_FLSH		= 0x78,
177678453a8Sspeer 	RXMISC			= 0x90,
178678453a8Sspeer 	RX_DMA_CTL_STAT_DBG	= 0x98
179678453a8Sspeer 
180678453a8Sspeer } rdc_csr_offset_t;
181678453a8Sspeer 
182678453a8Sspeer typedef enum {
183678453a8Sspeer 	Tx_RNG_CFIG		= 0,
184678453a8Sspeer 	Tx_RNG_HDL		= 0x10,
185678453a8Sspeer 	Tx_RNG_KICK		= 0x18,
186678453a8Sspeer 	Tx_ENT_MASK		= 0x20,
187678453a8Sspeer 	Tx_CS			= 0x28,
188678453a8Sspeer 	TxDMA_MBH		= 0x30,
189678453a8Sspeer 	TxDMA_MBL		= 0x38,
190678453a8Sspeer 	TxDMA_PRE_ST		= 0x40,
191678453a8Sspeer 	Tx_RNG_ERR_LOGH		= 0x48,
192678453a8Sspeer 	Tx_RNG_ERR_LOGL		= 0x50,
193678453a8Sspeer 	TDMC_INTR_DBG		= 0x60,
194678453a8Sspeer 	Tx_CS_DBG		= 0x68
195678453a8Sspeer 
196678453a8Sspeer } tdc_csr_offset_t;
197678453a8Sspeer 
198678453a8Sspeer /*
199678453a8Sspeer  * -------------------------------------------------------------
200678453a8Sspeer  * These definitions are used to handle the virtual PIO_LDSV
201678453a8Sspeer  * space of a VR.
202678453a8Sspeer  * -------------------------------------------------------------
203678453a8Sspeer  */
204678453a8Sspeer #define	VLDG_OFFSET		0x2000
205678453a8Sspeer #define	VLDG_SLL		5
206678453a8Sspeer 
207678453a8Sspeer typedef enum {
208678453a8Sspeer 	PIO_LDSV0,		/* ldf_0, 0-63 */
209678453a8Sspeer 	PIO_LDSV1,		/* ldf_1, 0-63 */
210678453a8Sspeer 	PIO_LDSV2,		/* ldf_0 & ldf_1, 64-69 */
211678453a8Sspeer 	PIO_LDGIMGN		/* arm/timer */
212678453a8Sspeer 
213678453a8Sspeer } pio_ld_op_t;
214678453a8Sspeer 
215678453a8Sspeer #define	VR_INTR_BLOCK_SIZE	8
216678453a8Sspeer #define	HIO_INTR_BLOCK_SIZE	4
217678453a8Sspeer 
218678453a8Sspeer /* ------------------------------------------------------------------ */
219678453a8Sspeer typedef struct {
220678453a8Sspeer 	const char	*name;
221678453a8Sspeer 	int		offset;
222678453a8Sspeer } dmc_reg_name_t;
223678453a8Sspeer 
224678453a8Sspeer typedef struct {
225678453a8Sspeer 	uintptr_t	nxge;
226678453a8Sspeer 	dc_map_t	map;
227678453a8Sspeer 
228678453a8Sspeer } nx_rdc_tbl_t;
229678453a8Sspeer 
230678453a8Sspeer typedef struct nxge_hio_vr {
231678453a8Sspeer 	uintptr_t	nxge;
232678453a8Sspeer 
233678453a8Sspeer 	uint32_t	cookie;	/* The HV cookie. */
234678453a8Sspeer 	uintptr_t	address;
235678453a8Sspeer 	size_t		size;
236678453a8Sspeer 	vr_region_t	region;	/* 1 of 8 regions. */
237678453a8Sspeer 
238da14cebeSEric Cheng 	int		rdc_tbl; /* 1 of 8 RDC tables. */
239da14cebeSEric Cheng 	int		tdc_tbl; /* 1 of 8 TDC tables. */
240678453a8Sspeer 	ether_addr_t	altmac;	/* The alternate MAC address. */
241da14cebeSEric Cheng 	int		slot;	/* According to nxge_m_mmac_add(). */
242678453a8Sspeer 
243678453a8Sspeer 	nxge_grp_t	rx_group;
244678453a8Sspeer 	nxge_grp_t	tx_group;
245678453a8Sspeer 
246678453a8Sspeer } nxge_hio_vr_t;
247678453a8Sspeer 
248678453a8Sspeer typedef nxge_status_t (*dc_init_t)(nxge_t *, int);
249678453a8Sspeer typedef void (*dc_uninit_t)(nxge_t *, int);
250678453a8Sspeer 
251678453a8Sspeer typedef struct {
252678453a8Sspeer 	uint32_t	number;	/* The LDG number assigned to this DC. */
253678453a8Sspeer 	uint64_t	index;	/* Bits 7:5 of the (virtual) PIO_LDSV. */
254678453a8Sspeer 
255678453a8Sspeer 	uint64_t	ldsv;	/* The logical device number */
256678453a8Sspeer 	uint64_t	map;	/* Currently unused */
257678453a8Sspeer 
258678453a8Sspeer 	int		vector;	/* The DDI vector number (index) */
259678453a8Sspeer } hio_ldg_t;
260678453a8Sspeer 
261678453a8Sspeer /*
262678453a8Sspeer  * -------------------------------------------------------------
263678453a8Sspeer  * The service domain driver makes use of both <index>, the index
264678453a8Sspeer  * into a VR's virtual page, and <channel>, the absolute channel
265678453a8Sspeer  * number, what we will call here the physical channel number.
266678453a8Sspeer  *
267678453a8Sspeer  * The guest domain will set both fields to the same value, since
268678453a8Sspeer  * it doesn't know any better.  And if a service domain owns a
269678453a8Sspeer  * DMA channel, it will also set both fields to the same value,
270678453a8Sspeer  * since it is not using a VR per se.
271678453a8Sspeer  * -------------------------------------------------------------
272678453a8Sspeer  */
273678453a8Sspeer typedef struct nx_dc {
274678453a8Sspeer 
275678453a8Sspeer 	struct nx_dc	*next;
276678453a8Sspeer 
277678453a8Sspeer 	nxge_hio_vr_t	*vr;	/* The VR belonged to. */
278678453a8Sspeer 
279678453a8Sspeer 	vp_channel_t	page;	/* VP_CHANNEL_0 - VP_CHANNEL_7 */
280678453a8Sspeer 	nxge_channel_t	channel; /* 1 of 16/24 channels */
281678453a8Sspeer 	/*
282678453a8Sspeer 	 * <channel> has its normal meaning. <page> refers to the
283678453a8Sspeer 	 * virtual page of the VR that <channel> has been bound to.
284678453a8Sspeer 	 * Therefore, in the service domain, <page> & <channel>
285678453a8Sspeer 	 * are almost always different. While in a guest domain,
286678453a8Sspeer 	 * they are always the same.
287678453a8Sspeer 	 */
288678453a8Sspeer 	vpc_type_t	type;	/* VP_BOUND_XX */
289678453a8Sspeer 	dc_init_t	init;	/* nxge_init_xxdma_channel() */
290678453a8Sspeer 	dc_uninit_t	uninit;	/* nxge_uninit_xxdma_channel() */
291678453a8Sspeer 
2926920a987SMisaki Miyashita 	nxge_grp_t	*group;	/* The group belonged to. */
293678453a8Sspeer 	uint32_t	cookie;	/* The HV cookie. */
294678453a8Sspeer 
295678453a8Sspeer 	hio_ldg_t	ldg;
296678453a8Sspeer 	boolean_t	interrupting; /* Interrupt enabled? */
297678453a8Sspeer 
298678453a8Sspeer } nxge_hio_dc_t;
299678453a8Sspeer 
300678453a8Sspeer typedef struct {
301678453a8Sspeer 	nxge_hio_type_t		type;
302678453a8Sspeer 
303678453a8Sspeer 	kmutex_t		lock;
3046920a987SMisaki Miyashita 	int			vrs;
305678453a8Sspeer 	unsigned		sequence;
306678453a8Sspeer 
307678453a8Sspeer 	nxhv_fp_t		hio;
308678453a8Sspeer 
309678453a8Sspeer 	/* vr[0] is reserved for the service domain. */
310678453a8Sspeer 	nxge_hio_vr_t		vr[NXGE_VR_SR_MAX]; /* subregion map */
311678453a8Sspeer 	nxge_hio_dc_t		rdc[NXGE_MAX_RDCS];
312678453a8Sspeer 	nxge_hio_dc_t		tdc[NXGE_MAX_TDCS];
313678453a8Sspeer 
314678453a8Sspeer 	nx_rdc_tbl_t		rdc_tbl[NXGE_MAX_RDC_GROUPS];
315678453a8Sspeer 
316678453a8Sspeer } nxge_hio_data_t;
317678453a8Sspeer 
318678453a8Sspeer /*
319678453a8Sspeer  * -------------------------------------------------------------
320678453a8Sspeer  * prototypes
321678453a8Sspeer  * -------------------------------------------------------------
322678453a8Sspeer  */
323678453a8Sspeer extern void nxge_get_environs(nxge_t *);
324678453a8Sspeer extern int nxge_hio_init(nxge_t *);
325678453a8Sspeer extern void nxge_hio_uninit(nxge_t *);
326678453a8Sspeer 
327678453a8Sspeer extern int nxge_dci_map(nxge_t *, vpc_type_t, int);
328678453a8Sspeer 
329678453a8Sspeer /*
330678453a8Sspeer  * ---------------------------------------------------------------------
331678453a8Sspeer  * These are the general-purpose DMA channel group functions.  That is,
332678453a8Sspeer  * these functions are used to manage groups of TDCs or RDCs in an HIO
333678453a8Sspeer  * environment.
334678453a8Sspeer  *
335678453a8Sspeer  * But is also expected that in the future they will be able to manage
336678453a8Sspeer  * Crossbow groups.
337678453a8Sspeer  * ---------------------------------------------------------------------
338678453a8Sspeer  */
3396920a987SMisaki Miyashita extern nxge_grp_t *nxge_grp_add(nxge_t *, nxge_grp_type_t);
3406920a987SMisaki Miyashita extern void nxge_grp_remove(nxge_t *, nxge_grp_t *);
3416920a987SMisaki Miyashita extern int nxge_grp_dc_add(nxge_t *, nxge_grp_t *, vpc_type_t, int);
342678453a8Sspeer extern void nxge_grp_dc_remove(nxge_t *, vpc_type_t, int);
343678453a8Sspeer extern nxge_hio_dc_t *nxge_grp_dc_find(nxge_t *, vpc_type_t, int);
344678453a8Sspeer 
345678453a8Sspeer extern void nxge_delay(int);
346678453a8Sspeer extern const char *nxge_ddi_perror(int);
347678453a8Sspeer 
348678453a8Sspeer /*
349678453a8Sspeer  * ---------------------------------------------------------------------
350678453a8Sspeer  * These are the Sun4v HIO function prototypes.
351678453a8Sspeer  * ---------------------------------------------------------------------
352678453a8Sspeer  */
353678453a8Sspeer extern void nxge_hio_group_get(void *arg, mac_ring_type_t type, int group,
354678453a8Sspeer 	mac_group_info_t *infop, mac_group_handle_t ghdl);
355da14cebeSEric Cheng extern int nxge_hio_share_alloc(void *arg, mac_share_handle_t *shandle);
356678453a8Sspeer extern void nxge_hio_share_free(mac_share_handle_t shandle);
357678453a8Sspeer extern void nxge_hio_share_query(mac_share_handle_t shandle,
358da14cebeSEric Cheng 	mac_ring_type_t type, mac_ring_handle_t *rings, uint_t *n_rings);
359da14cebeSEric Cheng extern int nxge_hio_share_add_group(mac_share_handle_t,
360da14cebeSEric Cheng     mac_group_driver_t);
361da14cebeSEric Cheng extern int nxge_hio_share_rem_group(mac_share_handle_t,
362da14cebeSEric Cheng     mac_group_driver_t);
363da14cebeSEric Cheng extern int nxge_hio_share_bind(mac_share_handle_t, uint64_t cookie,
364da14cebeSEric Cheng     uint64_t *rcookie);
365da14cebeSEric Cheng extern void nxge_hio_share_unbind(mac_share_handle_t);
36608ac1c49SNicolas Droux extern int nxge_hio_rxdma_bind_intr(nxge_t *, rx_rcr_ring_t *, int);
367678453a8Sspeer 
368678453a8Sspeer 				/* nxge_hio_guest.c */
369678453a8Sspeer extern void nxge_hio_unregister(nxge_t *);
370*0dc2366fSVenugopal Iyer extern int nxge_hio_get_dc_htable_idx(nxge_t *nxge, vpc_type_t type,
371*0dc2366fSVenugopal Iyer     uint32_t channel);
372678453a8Sspeer 
373678453a8Sspeer extern int nxge_guest_regs_map(nxge_t *);
374678453a8Sspeer extern void nxge_guest_regs_map_free(nxge_t *);
375678453a8Sspeer 
376678453a8Sspeer extern int nxge_hio_vr_add(nxge_t *nxge);
377678453a8Sspeer extern int nxge_hio_vr_release(nxge_t *nxge);
378678453a8Sspeer 
379678453a8Sspeer extern nxge_status_t nxge_tdc_lp_conf(p_nxge_t, int);
380678453a8Sspeer extern nxge_status_t nxge_rdc_lp_conf(p_nxge_t, int);
381678453a8Sspeer 
382678453a8Sspeer extern void nxge_hio_start_timer(nxge_t *);
383678453a8Sspeer 
384678453a8Sspeer 				/* nxge_intr.c */
385678453a8Sspeer extern nxge_status_t nxge_hio_intr_init(nxge_t *);
386678453a8Sspeer extern void nxge_hio_intr_uninit(nxge_t *);
387678453a8Sspeer 
388678453a8Sspeer extern nxge_status_t nxge_intr_add(nxge_t *, vpc_type_t, int);
389678453a8Sspeer extern nxge_status_t nxge_intr_remove(nxge_t *, vpc_type_t, int);
390678453a8Sspeer 
391678453a8Sspeer extern nxge_status_t nxge_hio_intr_add(nxge_t *, vpc_type_t, int);
392678453a8Sspeer extern nxge_status_t nxge_hio_intr_remove(nxge_t *, vpc_type_t, int);
393678453a8Sspeer 
394678453a8Sspeer extern nxge_status_t nxge_hio_intr_add(nxge_t *, vpc_type_t, int);
395678453a8Sspeer extern nxge_status_t nxge_hio_intr_rem(nxge_t *, int);
396678453a8Sspeer 
397*0dc2366fSVenugopal Iyer extern int nxge_hio_ldsv_add(nxge_t *, nxge_hio_dc_t *);
398678453a8Sspeer 
399678453a8Sspeer extern void nxge_hio_ldsv_im(nxge_t *, nxge_ldg_t *, pio_ld_op_t, uint64_t *);
400678453a8Sspeer extern void nxge_hio_ldgimgn(nxge_t *, nxge_ldg_t *);
401678453a8Sspeer 
402678453a8Sspeer 				/* nxge_hv.c */
403678453a8Sspeer extern void nxge_hio_hv_init(nxge_t *);
404678453a8Sspeer 
405678453a8Sspeer 				/* nxge_mac.c */
406678453a8Sspeer extern int nxge_hio_hostinfo_get_rdc_table(p_nxge_t);
407678453a8Sspeer extern int nxge_hio_hostinfo_init(nxge_t *, nxge_hio_vr_t *, ether_addr_t *);
408678453a8Sspeer extern void nxge_hio_hostinfo_uninit(nxge_t *, nxge_hio_vr_t *);
409678453a8Sspeer 
410678453a8Sspeer #ifdef	__cplusplus
411678453a8Sspeer }
412678453a8Sspeer #endif
413678453a8Sspeer 
414678453a8Sspeer #endif	/* _SYS_NXGE_NXGE_HIO_H */
415