1219820Sjeff/*
2219820Sjeff * Copyright (c) 2004-2008 Voltaire, Inc. All rights reserved.
3219820Sjeff * Copyright (c) 2002-2005 Mellanox Technologies LTD. All rights reserved.
4219820Sjeff * Copyright (c) 1996-2003 Intel Corporation. All rights reserved.
5219820Sjeff *
6219820Sjeff * This software is available to you under a choice of one of two
7219820Sjeff * licenses.  You may choose to be licensed under the terms of the GNU
8219820Sjeff * General Public License (GPL) Version 2, available from the file
9219820Sjeff * COPYING in the main directory of this source tree, or the
10219820Sjeff * OpenIB.org BSD license below:
11219820Sjeff *
12219820Sjeff *     Redistribution and use in source and binary forms, with or
13219820Sjeff *     without modification, are permitted provided that the following
14219820Sjeff *     conditions are met:
15219820Sjeff *
16219820Sjeff *      - Redistributions of source code must retain the above
17219820Sjeff *        copyright notice, this list of conditions and the following
18219820Sjeff *        disclaimer.
19219820Sjeff *
20219820Sjeff *      - Redistributions in binary form must reproduce the above
21219820Sjeff *        copyright notice, this list of conditions and the following
22219820Sjeff *        disclaimer in the documentation and/or other materials
23219820Sjeff *        provided with the distribution.
24219820Sjeff *
25219820Sjeff * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26219820Sjeff * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27219820Sjeff * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
28219820Sjeff * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
29219820Sjeff * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
30219820Sjeff * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
31219820Sjeff * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32219820Sjeff * SOFTWARE.
33219820Sjeff *
34219820Sjeff */
35219820Sjeff
36219820Sjeff/*
37219820Sjeff * Abstract:
38219820Sjeff * 	Declaration of osm_mad_wrapper_t.
39219820Sjeff *	This object represents the context wrapper for OpenSM MAD processing.
40219820Sjeff *	This object is part of the OpenSM family of objects.
41219820Sjeff */
42219820Sjeff
43219820Sjeff#ifndef _OSM_MADW_H_
44219820Sjeff#define _OSM_MADW_H_
45219820Sjeff
46219820Sjeff#include <string.h>
47219820Sjeff#include <iba/ib_types.h>
48219820Sjeff#include <complib/cl_qlist.h>
49219820Sjeff#include <complib/cl_dispatcher.h>
50219820Sjeff#include <opensm/osm_base.h>
51219820Sjeff#include <vendor/osm_vendor.h>
52219820Sjeff
53219820Sjeff#ifdef __cplusplus
54219820Sjeff#  define BEGIN_C_DECLS extern "C" {
55219820Sjeff#  define END_C_DECLS   }
56219820Sjeff#else				/* !__cplusplus */
57219820Sjeff#  define BEGIN_C_DECLS
58219820Sjeff#  define END_C_DECLS
59219820Sjeff#endif				/* __cplusplus */
60219820Sjeff
61219820SjeffBEGIN_C_DECLS
62219820Sjeff/****s* OpenSM: MAD Wrapper/osm_bind_info_t
63219820Sjeff* NAME
64219820Sjeff*   osm_bind_info_t
65219820Sjeff*
66219820Sjeff* DESCRIPTION
67219820Sjeff*
68219820Sjeff* SYNOPSIS
69219820Sjeff*/
70219820Sjefftypedef struct osm_bind_info {
71219820Sjeff	ib_net64_t port_guid;
72219820Sjeff	uint8_t mad_class;
73219820Sjeff	uint8_t class_version;
74219820Sjeff	boolean_t is_responder;
75219820Sjeff	boolean_t is_trap_processor;
76219820Sjeff	boolean_t is_report_processor;
77219820Sjeff	uint32_t send_q_size;
78219820Sjeff	uint32_t recv_q_size;
79219820Sjeff} osm_bind_info_t;
80219820Sjeff/*
81219820Sjeff* FIELDS
82219820Sjeff*	portguid
83219820Sjeff*		PortGuid of local port
84219820Sjeff*
85219820Sjeff*	mad_class
86219820Sjeff*		Mgmt Class ID
87219820Sjeff*
88219820Sjeff*	class_version
89219820Sjeff*		Mgmt Class version
90219820Sjeff*
91219820Sjeff*	is_responder
92219820Sjeff*		True if this is a GSI Agent
93219820Sjeff*
94219820Sjeff*	is_trap_processor
95219820Sjeff*		True if GSI Trap msgs are handled
96219820Sjeff*
97219820Sjeff*	is_report_processor
98219820Sjeff*		True if GSI Report msgs are handled
99219820Sjeff*
100219820Sjeff*	send_q_size
101219820Sjeff*		SendQueueSize
102219820Sjeff*
103219820Sjeff*	recv_q_size
104219820Sjeff*		Receive Queue Size
105219820Sjeff*
106219820Sjeff* SEE ALSO
107219820Sjeff*********/
108219820Sjeff
109219820Sjeff/****h* OpenSM/MAD Wrapper
110219820Sjeff* NAME
111219820Sjeff*	MAD Wrapper
112219820Sjeff*
113219820Sjeff* DESCRIPTION
114219820Sjeff*	The MAD Wrapper object encapsulates the information needed by the
115219820Sjeff*	OpenSM to manage individual MADs.  The OpenSM allocates one MAD Wrapper
116219820Sjeff*	per MAD.
117219820Sjeff*
118219820Sjeff*	The MAD Wrapper is not thread safe, thus callers must provide
119219820Sjeff*	serialization.
120219820Sjeff*
121219820Sjeff*	This object should be treated as opaque and should be
122219820Sjeff*	manipulated only through the provided functions.
123219820Sjeff*
124219820Sjeff* AUTHOR
125219820Sjeff*	Steve King, Intel
126219820Sjeff*
127219820Sjeff*********/
128219820Sjeff
129219820Sjeff/****s* OpenSM: MAD Wrapper/osm_ni_context_t
130219820Sjeff* NAME
131219820Sjeff*	osm_ni_context_t
132219820Sjeff*
133219820Sjeff* DESCRIPTION
134219820Sjeff*	Context needed by recipient of NodeInfo attribute.
135219820Sjeff*
136219820Sjeff* SYNOPSIS
137219820Sjeff*/
138219820Sjefftypedef struct osm_ni_context {
139219820Sjeff	ib_net64_t node_guid;
140219820Sjeff	uint8_t port_num;
141219820Sjeff	ib_net64_t dup_node_guid;
142219820Sjeff	uint8_t dup_port_num;
143219820Sjeff	unsigned dup_count;
144219820Sjeff} osm_ni_context_t;
145219820Sjeff/*
146219820Sjeff* FIELDS
147219820Sjeff*	p_node
148219820Sjeff*		Pointer to the node thru which we got to this node.
149219820Sjeff*
150219820Sjeff*	p_sw
151219820Sjeff*		Pointer to the switch object (if any) of the switch
152219820Sjeff*		thru which we got to this node.
153219820Sjeff*
154219820Sjeff*	port_num
155219820Sjeff*		Port number on the node or switch thru which we got
156219820Sjeff*		to this node.
157219820Sjeff*
158219820Sjeff* SEE ALSO
159219820Sjeff*********/
160219820Sjeff
161219820Sjeff/****s* OpenSM: MAD Wrapper/osm_pi_context_t
162219820Sjeff* NAME
163219820Sjeff*	osm_pi_context_t
164219820Sjeff*
165219820Sjeff* DESCRIPTION
166219820Sjeff*	Context needed by recipient of PortInfo attribute.
167219820Sjeff*
168219820Sjeff* SYNOPSIS
169219820Sjeff*/
170219820Sjefftypedef struct osm_pi_context {
171219820Sjeff	ib_net64_t node_guid;
172219820Sjeff	ib_net64_t port_guid;
173219820Sjeff	boolean_t set_method;
174219820Sjeff	boolean_t light_sweep;
175219820Sjeff	boolean_t active_transition;
176219820Sjeff} osm_pi_context_t;
177219820Sjeff/*********/
178219820Sjeff
179219820Sjeff/****s* OpenSM: MAD Wrapper/osm_nd_context_t
180219820Sjeff* NAME
181219820Sjeff*	osm_nd_context_t
182219820Sjeff*
183219820Sjeff* DESCRIPTION
184219820Sjeff*	Context needed by recipient of NodeDescription attribute.
185219820Sjeff*
186219820Sjeff* SYNOPSIS
187219820Sjeff*/
188219820Sjefftypedef struct osm_nd_context {
189219820Sjeff	ib_net64_t node_guid;
190219820Sjeff} osm_nd_context_t;
191219820Sjeff/*********/
192219820Sjeff
193219820Sjeff/****s* OpenSM: MAD Wrapper/osm_si_context_t
194219820Sjeff* NAME
195219820Sjeff*	osm_si_context_t
196219820Sjeff*
197219820Sjeff* DESCRIPTION
198219820Sjeff*	Context needed by recipient of SwitchInfo attribute.
199219820Sjeff*
200219820Sjeff* SYNOPSIS
201219820Sjeff*/
202219820Sjefftypedef struct osm_si_context {
203219820Sjeff	ib_net64_t node_guid;
204219820Sjeff	boolean_t set_method;
205219820Sjeff	boolean_t light_sweep;
206219820Sjeff} osm_si_context_t;
207219820Sjeff/*********/
208219820Sjeff
209219820Sjeff/****s* OpenSM: MAD Wrapper/osm_lft_context_t
210219820Sjeff* NAME
211219820Sjeff*	osm_lft_context_t
212219820Sjeff*
213219820Sjeff* DESCRIPTION
214219820Sjeff*	Context needed by recipient of LinearForwardingTable attribute.
215219820Sjeff*
216219820Sjeff* SYNOPSIS
217219820Sjeff*/
218219820Sjefftypedef struct osm_lft_context {
219219820Sjeff	ib_net64_t node_guid;
220219820Sjeff	boolean_t set_method;
221219820Sjeff} osm_lft_context_t;
222219820Sjeff/*********/
223219820Sjeff
224219820Sjeff/****s* OpenSM: MAD Wrapper/osm_mft_context_t
225219820Sjeff* NAME
226219820Sjeff*	osm_mft_context_t
227219820Sjeff*
228219820Sjeff* DESCRIPTION
229219820Sjeff*	Context needed by recipient of MulticastForwardingTable attribute.
230219820Sjeff*
231219820Sjeff* SYNOPSIS
232219820Sjeff*/
233219820Sjefftypedef struct osm_mft_context {
234219820Sjeff	ib_net64_t node_guid;
235219820Sjeff	boolean_t set_method;
236219820Sjeff} osm_mft_context_t;
237219820Sjeff/*********/
238219820Sjeff
239219820Sjeff/****s* OpenSM: MAD Wrapper/osm_smi_context_t
240219820Sjeff* NAME
241219820Sjeff*	osm_smi_context_t
242219820Sjeff*
243219820Sjeff* DESCRIPTION
244219820Sjeff*	Context needed by recipient of SMInfo attribute.
245219820Sjeff*
246219820Sjeff* SYNOPSIS
247219820Sjeff*/
248219820Sjefftypedef struct osm_smi_context {
249219820Sjeff	ib_net64_t port_guid;
250219820Sjeff	boolean_t set_method;
251219820Sjeff	boolean_t light_sweep;
252219820Sjeff} osm_smi_context_t;
253219820Sjeff/*********/
254219820Sjeff
255219820Sjeff/****s* OpenSM: MAD Wrapper/osm_pkey_context_t
256219820Sjeff* NAME
257219820Sjeff*	osm_pkey_context_t
258219820Sjeff*
259219820Sjeff* DESCRIPTION
260219820Sjeff*	Context needed by recipient of P_Key attribute.
261219820Sjeff*
262219820Sjeff* SYNOPSIS
263219820Sjeff*/
264219820Sjefftypedef struct osm_pkey_context {
265219820Sjeff	ib_net64_t node_guid;
266219820Sjeff	ib_net64_t port_guid;
267219820Sjeff	boolean_t set_method;
268219820Sjeff} osm_pkey_context_t;
269219820Sjeff/*********/
270219820Sjeff
271219820Sjeff/****s* OpenSM: MAD Wrapper/osm_slvl_context_t
272219820Sjeff* NAME
273219820Sjeff*	osm_slvl_context_t
274219820Sjeff*
275219820Sjeff* DESCRIPTION
276219820Sjeff*	Context needed by recipient of PortInfo attribute.
277219820Sjeff*
278219820Sjeff* SYNOPSIS
279219820Sjeff*/
280219820Sjefftypedef struct osm_slvl_context {
281219820Sjeff	ib_net64_t node_guid;
282219820Sjeff	ib_net64_t port_guid;
283219820Sjeff	boolean_t set_method;
284219820Sjeff} osm_slvl_context_t;
285219820Sjeff/*********/
286219820Sjeff
287219820Sjeff/****s* OpenSM: MAD Wrapper/osm_vla_context_t
288219820Sjeff* NAME
289219820Sjeff*	osm_vla_context_t
290219820Sjeff*
291219820Sjeff* DESCRIPTION
292219820Sjeff*	Context needed by recipient of VL Arb attribute.
293219820Sjeff*
294219820Sjeff* SYNOPSIS
295219820Sjeff*/
296219820Sjefftypedef struct osm_vla_context {
297219820Sjeff	ib_net64_t node_guid;
298219820Sjeff	ib_net64_t port_guid;
299219820Sjeff	boolean_t set_method;
300219820Sjeff} osm_vla_context_t;
301219820Sjeff/*********/
302219820Sjeff
303219820Sjeff/****s* OpenSM: MAD Wrapper/osm_perfmgr_context_t
304219820Sjeff* DESCRIPTION
305219820Sjeff*	Context for Performance manager queries
306219820Sjeff*/
307219820Sjefftypedef struct osm_perfmgr_context {
308219820Sjeff	uint64_t node_guid;
309219820Sjeff	uint16_t port;
310219820Sjeff	uint8_t mad_method;	/* was this a get or a set */
311219820Sjeff#if ENABLE_OSM_PERF_MGR_PROFILE
312219820Sjeff	struct timeval query_start;
313219820Sjeff#endif
314219820Sjeff} osm_perfmgr_context_t;
315219820Sjeff/*********/
316219820Sjeff
317219820Sjeff#ifndef OSM_VENDOR_INTF_OPENIB
318219820Sjeff/****s* OpenSM: MAD Wrapper/osm_arbitrary_context_t
319219820Sjeff* NAME
320219820Sjeff*	osm_arbitrary_context_t
321219820Sjeff*
322219820Sjeff* DESCRIPTION
323219820Sjeff*	Context needed by arbitrary recipient.
324219820Sjeff*
325219820Sjeff* SYNOPSIS
326219820Sjeff*/
327219820Sjefftypedef struct osm_arbitrary_context {
328219820Sjeff	void *context1;
329219820Sjeff	void *context2;
330219820Sjeff} osm_arbitrary_context_t;
331219820Sjeff/*********/
332219820Sjeff#endif
333219820Sjeff
334219820Sjeff/****s* OpenSM: MAD Wrapper/osm_madw_context_t
335219820Sjeff* NAME
336219820Sjeff*	osm_madw_context_t
337219820Sjeff*
338219820Sjeff* DESCRIPTION
339219820Sjeff*	Context needed by recipients of MAD responses.
340219820Sjeff*
341219820Sjeff* SYNOPSIS
342219820Sjeff*/
343219820Sjefftypedef union _osm_madw_context {
344219820Sjeff	osm_ni_context_t ni_context;
345219820Sjeff	osm_pi_context_t pi_context;
346219820Sjeff	osm_nd_context_t nd_context;
347219820Sjeff	osm_si_context_t si_context;
348219820Sjeff	osm_lft_context_t lft_context;
349219820Sjeff	osm_mft_context_t mft_context;
350219820Sjeff	osm_smi_context_t smi_context;
351219820Sjeff	osm_slvl_context_t slvl_context;
352219820Sjeff	osm_pkey_context_t pkey_context;
353219820Sjeff	osm_vla_context_t vla_context;
354219820Sjeff	osm_perfmgr_context_t perfmgr_context;
355219820Sjeff#ifndef OSM_VENDOR_INTF_OPENIB
356219820Sjeff	osm_arbitrary_context_t arb_context;
357219820Sjeff#endif
358219820Sjeff} osm_madw_context_t;
359219820Sjeff/*********/
360219820Sjeff
361219820Sjeff/****s* OpenSM: MAD Wrapper/osm_mad_addr_t
362219820Sjeff* NAME
363219820Sjeff*   osm_mad_addr_t
364219820Sjeff*
365219820Sjeff* DESCRIPTION
366219820Sjeff*
367219820Sjeff* SYNOPSIS
368219820Sjeff*/
369219820Sjefftypedef struct osm_mad_addr {
370219820Sjeff	ib_net16_t dest_lid;
371219820Sjeff	uint8_t path_bits;
372219820Sjeff	uint8_t static_rate;
373219820Sjeff	union addr_type {
374219820Sjeff		struct _smi {
375219820Sjeff			ib_net16_t source_lid;
376219820Sjeff			uint8_t port_num;
377219820Sjeff		} smi;
378219820Sjeff
379219820Sjeff		struct _gsi {
380219820Sjeff			ib_net32_t remote_qp;
381219820Sjeff			ib_net32_t remote_qkey;
382219820Sjeff			uint16_t pkey_ix;
383219820Sjeff			uint8_t service_level;
384219820Sjeff			boolean_t global_route;
385219820Sjeff			ib_grh_t grh_info;
386219820Sjeff		} gsi;
387219820Sjeff	} addr_type;
388219820Sjeff} osm_mad_addr_t;
389219820Sjeff/*
390219820Sjeff* FIELDS
391219820Sjeff*
392219820Sjeff* SEE ALSO
393219820Sjeff*********/
394219820Sjeff
395219820Sjeff/****s* OpenSM: MAD Wrapper/osm_madw_t
396219820Sjeff* NAME
397219820Sjeff*	osm_madw_t
398219820Sjeff*
399219820Sjeff* DESCRIPTION
400219820Sjeff*	Context needed for processing individual MADs
401219820Sjeff*
402219820Sjeff* SYNOPSIS
403219820Sjeff*/
404219820Sjefftypedef struct osm_madw {
405219820Sjeff	cl_list_item_t list_item;
406219820Sjeff	osm_bind_handle_t h_bind;
407219820Sjeff	osm_vend_wrap_t vend_wrap;
408219820Sjeff	osm_mad_addr_t mad_addr;
409219820Sjeff	osm_bind_info_t bind_info;
410219820Sjeff	osm_madw_context_t context;
411219820Sjeff	uint32_t mad_size;
412219820Sjeff	ib_api_status_t status;
413219820Sjeff	cl_disp_msgid_t fail_msg;
414219820Sjeff	boolean_t resp_expected;
415219820Sjeff	const ib_mad_t *p_mad;
416219820Sjeff} osm_madw_t;
417219820Sjeff/*
418219820Sjeff* FIELDS
419219820Sjeff*	list_item
420219820Sjeff*		List linkage for lists.  MUST BE FIRST MEMBER!
421219820Sjeff*
422219820Sjeff*	h_bind
423219820Sjeff*		Bind handle for the port on which this MAD will be sent
424219820Sjeff*		or was received.
425219820Sjeff*
426219820Sjeff*	vend_wrap
427219820Sjeff*		Transport vendor specific context.  This structure is not
428219820Sjeff*		used outside MAD transport vendor specific code.
429219820Sjeff*
430219820Sjeff*	context
431219820Sjeff*		Union of controller specific contexts needed for this MAD.
432219820Sjeff*		This structure allows controllers to indirectly communicate
433219820Sjeff*		with each other through the dispatcher.
434219820Sjeff*
435219820Sjeff*	mad_size
436219820Sjeff*		Size of this MAD in bytes.
437219820Sjeff*
438219820Sjeff*	status
439219820Sjeff*		Status of completed operation on the MAD.
440219820Sjeff*		CL_SUCCESS if the operation was successful.
441219820Sjeff*
442219820Sjeff*	fail_msg
443219820Sjeff*		Dispatcher message with which to post this MAD on failure.
444219820Sjeff*		This value is set by the originator of the MAD.
445219820Sjeff*		If an operation on this MAD fails, for example due to a timeout,
446219820Sjeff*		then the transport layer will dispose of the MAD by sending
447219820Sjeff*		it through the Dispatcher with this message type.  Presumably,
448219820Sjeff*		there is a controller listening for the failure message that can
449219820Sjeff*		properly clean up.
450219820Sjeff*
451219820Sjeff*	resp_expected
452219820Sjeff*		TRUE if a response is expected to this MAD.
453219820Sjeff*		FALSE otherwise.
454219820Sjeff*
455219820Sjeff*	p_mad
456219820Sjeff*		Pointer to the wire MAD.  The MAD itself cannot be part of the
457219820Sjeff*		wrapper, since wire MADs typically reside in special memory
458219820Sjeff*		registered with the local HCA.
459219820Sjeff*
460219820Sjeff* SEE ALSO
461219820Sjeff*********/
462219820Sjeff
463219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_init
464219820Sjeff* NAME
465219820Sjeff*	osm_madw_init
466219820Sjeff*
467219820Sjeff* DESCRIPTION
468219820Sjeff*	Initializes a MAD Wrapper object for use.
469219820Sjeff*
470219820Sjeff* SYNOPSIS
471219820Sjeff*/
472219820Sjeffstatic inline void
473219820Sjeffosm_madw_init(IN osm_madw_t * const p_madw,
474219820Sjeff	      IN osm_bind_handle_t h_bind,
475219820Sjeff	      IN const uint32_t mad_size,
476219820Sjeff	      IN const osm_mad_addr_t * const p_mad_addr)
477219820Sjeff{
478219820Sjeff	memset(p_madw, 0, sizeof(*p_madw));
479219820Sjeff	p_madw->h_bind = h_bind;
480219820Sjeff	p_madw->fail_msg = CL_DISP_MSGID_NONE;
481219820Sjeff	p_madw->mad_size = mad_size;
482219820Sjeff	if (p_mad_addr)
483219820Sjeff		p_madw->mad_addr = *p_mad_addr;
484219820Sjeff	p_madw->resp_expected = FALSE;
485219820Sjeff}
486219820Sjeff
487219820Sjeff/*
488219820Sjeff* PARAMETERS
489219820Sjeff*	p_madw
490219820Sjeff*		[in] Pointer to an osm_madw_t object to initialize.
491219820Sjeff*
492219820Sjeff*	h_bind
493219820Sjeff*		[in] Pointer to the wire MAD.
494219820Sjeff*
495219820Sjeff*	p_mad_addr
496219820Sjeff*		[in] Pointer to the MAD address structure.  This parameter may
497219820Sjeff*		be NULL for directed route MADs.
498219820Sjeff*
499219820Sjeff* RETURN VALUES
500219820Sjeff*	None.
501219820Sjeff*
502219820Sjeff* NOTES
503219820Sjeff*
504219820Sjeff* SEE ALSO
505219820Sjeff*********/
506219820Sjeff
507219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_smp_ptr
508219820Sjeff* NAME
509219820Sjeff*	osm_madw_get_smp_ptr
510219820Sjeff*
511219820Sjeff* DESCRIPTION
512219820Sjeff*	Gets a pointer to the SMP in this MAD.
513219820Sjeff*
514219820Sjeff* SYNOPSIS
515219820Sjeff*/
516219820Sjeffstatic inline ib_smp_t *osm_madw_get_smp_ptr(IN const osm_madw_t * const p_madw)
517219820Sjeff{
518219820Sjeff	return ((ib_smp_t *) p_madw->p_mad);
519219820Sjeff}
520219820Sjeff
521219820Sjeff/*
522219820Sjeff* PARAMETERS
523219820Sjeff*	p_madw
524219820Sjeff*		[in] Pointer to an osm_madw_t object to initialize.
525219820Sjeff*
526219820Sjeff* RETURN VALUES
527219820Sjeff*	Pointer to the start of the SMP MAD.
528219820Sjeff*
529219820Sjeff* NOTES
530219820Sjeff*
531219820Sjeff* SEE ALSO
532219820Sjeff*	MAD Wrapper object
533219820Sjeff*********/
534219820Sjeff
535219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_sa_mad_ptr
536219820Sjeff* NAME
537219820Sjeff*	osm_madw_get_sa_mad_ptr
538219820Sjeff*
539219820Sjeff* DESCRIPTION
540219820Sjeff*	Gets a pointer to the SA MAD in this MAD wrapper.
541219820Sjeff*
542219820Sjeff* SYNOPSIS
543219820Sjeff*/
544219820Sjeffstatic inline ib_sa_mad_t *osm_madw_get_sa_mad_ptr(IN const osm_madw_t *
545219820Sjeff						   const p_madw)
546219820Sjeff{
547219820Sjeff	return ((ib_sa_mad_t *) p_madw->p_mad);
548219820Sjeff}
549219820Sjeff
550219820Sjeff/*
551219820Sjeff* PARAMETERS
552219820Sjeff*	p_madw
553219820Sjeff*		[in] Pointer to an osm_madw_t object.
554219820Sjeff*
555219820Sjeff* RETURN VALUES
556219820Sjeff*	Pointer to the start of the SA MAD.
557219820Sjeff*
558219820Sjeff* NOTES
559219820Sjeff*
560219820Sjeff* SEE ALSO
561219820Sjeff*	MAD Wrapper object
562219820Sjeff*********/
563219820Sjeff
564219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_perfmgt_mad_ptr
565219820Sjeff* DESCRIPTION
566219820Sjeff*	Gets a pointer to the PerfMgt MAD in this MAD wrapper.
567219820Sjeff*
568219820Sjeff* SYNOPSIS
569219820Sjeff*/
570219820Sjeffstatic inline ib_perfmgt_mad_t *osm_madw_get_perfmgt_mad_ptr(IN const osm_madw_t
571219820Sjeff							     * const p_madw)
572219820Sjeff{
573219820Sjeff	return ((ib_perfmgt_mad_t *) p_madw->p_mad);
574219820Sjeff}
575219820Sjeff
576219820Sjeff/*
577219820Sjeff* PARAMETERS
578219820Sjeff*	p_madw
579219820Sjeff*		[in] Pointer to an osm_madw_t object.
580219820Sjeff*
581219820Sjeff* RETURN VALUES
582219820Sjeff*	Pointer to the start of the PerfMgt MAD.
583219820Sjeff*
584219820Sjeff* NOTES
585219820Sjeff*
586219820Sjeff* SEE ALSO
587219820Sjeff*	MAD Wrapper object
588219820Sjeff*********/
589219820Sjeff
590219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_ni_context_ptr
591219820Sjeff* NAME
592219820Sjeff*	osm_madw_get_ni_context_ptr
593219820Sjeff*
594219820Sjeff* DESCRIPTION
595219820Sjeff*	Gets a pointer to the NodeInfo context in this MAD.
596219820Sjeff*
597219820Sjeff* SYNOPSIS
598219820Sjeff*/
599219820Sjeffstatic inline osm_ni_context_t *osm_madw_get_ni_context_ptr(IN const osm_madw_t
600219820Sjeff							    * const p_madw)
601219820Sjeff{
602219820Sjeff	return ((osm_ni_context_t *) & p_madw->context);
603219820Sjeff}
604219820Sjeff
605219820Sjeff/*
606219820Sjeff* PARAMETERS
607219820Sjeff*	p_madw
608219820Sjeff*		[in] Pointer to an osm_madw_t object.
609219820Sjeff*
610219820Sjeff* RETURN VALUES
611219820Sjeff*	Pointer to the start of the context structure.
612219820Sjeff*
613219820Sjeff* NOTES
614219820Sjeff*
615219820Sjeff* SEE ALSO
616219820Sjeff*********/
617219820Sjeff
618219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_pi_context_ptr
619219820Sjeff* NAME
620219820Sjeff*	osm_madw_get_pi_context_ptr
621219820Sjeff*
622219820Sjeff* DESCRIPTION
623219820Sjeff*	Gets a pointer to the PortInfo context in this MAD.
624219820Sjeff*
625219820Sjeff* SYNOPSIS
626219820Sjeff*/
627219820Sjeffstatic inline osm_pi_context_t *osm_madw_get_pi_context_ptr(IN const osm_madw_t
628219820Sjeff							    * const p_madw)
629219820Sjeff{
630219820Sjeff	return ((osm_pi_context_t *) & p_madw->context);
631219820Sjeff}
632219820Sjeff
633219820Sjeff/*
634219820Sjeff* PARAMETERS
635219820Sjeff*	p_madw
636219820Sjeff*		[in] Pointer to an osm_madw_t object.
637219820Sjeff*
638219820Sjeff* RETURN VALUES
639219820Sjeff*	Pointer to the start of the context structure.
640219820Sjeff*
641219820Sjeff* NOTES
642219820Sjeff*
643219820Sjeff* SEE ALSO
644219820Sjeff*********/
645219820Sjeff
646219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_nd_context_ptr
647219820Sjeff* NAME
648219820Sjeff*	osm_madw_get_nd_context_ptr
649219820Sjeff*
650219820Sjeff* DESCRIPTION
651219820Sjeff*	Gets a pointer to the NodeDescription context in this MAD.
652219820Sjeff*
653219820Sjeff* SYNOPSIS
654219820Sjeff*/
655219820Sjeffstatic inline osm_nd_context_t *osm_madw_get_nd_context_ptr(IN const osm_madw_t
656219820Sjeff							    * const p_madw)
657219820Sjeff{
658219820Sjeff	return ((osm_nd_context_t *) & p_madw->context);
659219820Sjeff}
660219820Sjeff
661219820Sjeff/*
662219820Sjeff* PARAMETERS
663219820Sjeff*	p_madw
664219820Sjeff*		[in] Pointer to an osm_madw_t object.
665219820Sjeff*
666219820Sjeff* RETURN VALUES
667219820Sjeff*	Pointer to the start of the context structure.
668219820Sjeff*
669219820Sjeff* NOTES
670219820Sjeff*
671219820Sjeff* SEE ALSO
672219820Sjeff*********/
673219820Sjeff
674219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_lft_context_ptr
675219820Sjeff* NAME
676219820Sjeff*	osm_madw_get_lft_context_ptr
677219820Sjeff*
678219820Sjeff* DESCRIPTION
679219820Sjeff*	Gets a pointer to the LFT context in this MAD.
680219820Sjeff*
681219820Sjeff* SYNOPSIS
682219820Sjeff*/
683219820Sjeffstatic inline osm_lft_context_t *osm_madw_get_lft_context_ptr(IN const
684219820Sjeff							      osm_madw_t *
685219820Sjeff							      const p_madw)
686219820Sjeff{
687219820Sjeff	return ((osm_lft_context_t *) & p_madw->context);
688219820Sjeff}
689219820Sjeff
690219820Sjeff/*
691219820Sjeff* PARAMETERS
692219820Sjeff*	p_madw
693219820Sjeff*		[in] Pointer to an osm_madw_t object.
694219820Sjeff*
695219820Sjeff* RETURN VALUES
696219820Sjeff*	Pointer to the start of the context structure.
697219820Sjeff*
698219820Sjeff* NOTES
699219820Sjeff*
700219820Sjeff* SEE ALSO
701219820Sjeff*********/
702219820Sjeff
703219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_mft_context_ptr
704219820Sjeff* NAME
705219820Sjeff*	osm_madw_get_mft_context_ptr
706219820Sjeff*
707219820Sjeff* DESCRIPTION
708219820Sjeff*	Gets a pointer to the MFT context in this MAD.
709219820Sjeff*
710219820Sjeff* SYNOPSIS
711219820Sjeff*/
712219820Sjeffstatic inline osm_mft_context_t *osm_madw_get_mft_context_ptr(IN const
713219820Sjeff							      osm_madw_t *
714219820Sjeff							      const p_madw)
715219820Sjeff{
716219820Sjeff	return ((osm_mft_context_t *) & p_madw->context);
717219820Sjeff}
718219820Sjeff
719219820Sjeff/*
720219820Sjeff* PARAMETERS
721219820Sjeff*	p_madw
722219820Sjeff*		[in] Pointer to an osm_madw_t object.
723219820Sjeff*
724219820Sjeff* RETURN VALUES
725219820Sjeff*	Pointer to the start of the context structure.
726219820Sjeff*
727219820Sjeff* NOTES
728219820Sjeff*
729219820Sjeff* SEE ALSO
730219820Sjeff*********/
731219820Sjeff
732219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_si_context_ptr
733219820Sjeff* NAME
734219820Sjeff*	osm_madw_get_si_context_ptr
735219820Sjeff*
736219820Sjeff* DESCRIPTION
737219820Sjeff*	Gets a pointer to the SwitchInfo context in this MAD.
738219820Sjeff*
739219820Sjeff* SYNOPSIS
740219820Sjeff*/
741219820Sjeffstatic inline osm_si_context_t *osm_madw_get_si_context_ptr(IN const osm_madw_t
742219820Sjeff							    * const p_madw)
743219820Sjeff{
744219820Sjeff	return ((osm_si_context_t *) & p_madw->context);
745219820Sjeff}
746219820Sjeff
747219820Sjeff/*
748219820Sjeff* PARAMETERS
749219820Sjeff*	p_madw
750219820Sjeff*		[in] Pointer to an osm_madw_t object.
751219820Sjeff*
752219820Sjeff* RETURN VALUES
753219820Sjeff*	Pointer to the start of the context structure.
754219820Sjeff*
755219820Sjeff* NOTES
756219820Sjeff*
757219820Sjeff* SEE ALSO
758219820Sjeff*********/
759219820Sjeff
760219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_smi_context_ptr
761219820Sjeff* NAME
762219820Sjeff*	osm_madw_get_smi_context_ptr
763219820Sjeff*
764219820Sjeff* DESCRIPTION
765219820Sjeff*	Gets a pointer to the SMInfo context in this MAD.
766219820Sjeff*
767219820Sjeff* SYNOPSIS
768219820Sjeff*/
769219820Sjeffstatic inline osm_smi_context_t *osm_madw_get_smi_context_ptr(IN const
770219820Sjeff							      osm_madw_t *
771219820Sjeff							      const p_madw)
772219820Sjeff{
773219820Sjeff	return ((osm_smi_context_t *) & p_madw->context);
774219820Sjeff}
775219820Sjeff
776219820Sjeff/*
777219820Sjeff* PARAMETERS
778219820Sjeff*	p_madw
779219820Sjeff*		[in] Pointer to an osm_madw_t object.
780219820Sjeff*
781219820Sjeff* RETURN VALUES
782219820Sjeff*	Pointer to the start of the context structure.
783219820Sjeff*
784219820Sjeff* NOTES
785219820Sjeff*
786219820Sjeff* SEE ALSO
787219820Sjeff*********/
788219820Sjeff
789219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_pkey_context_ptr
790219820Sjeff* NAME
791219820Sjeff*	osm_madw_get_pkey_context_ptr
792219820Sjeff*
793219820Sjeff* DESCRIPTION
794219820Sjeff*	Gets a pointer to the P_Key context in this MAD.
795219820Sjeff*
796219820Sjeff* SYNOPSIS
797219820Sjeff*/
798219820Sjeffstatic inline osm_pkey_context_t *osm_madw_get_pkey_context_ptr(IN const
799219820Sjeff								osm_madw_t *
800219820Sjeff								const p_madw)
801219820Sjeff{
802219820Sjeff	return ((osm_pkey_context_t *) & p_madw->context);
803219820Sjeff}
804219820Sjeff
805219820Sjeff/*
806219820Sjeff* PARAMETERS
807219820Sjeff*	p_madw
808219820Sjeff*		[in] Pointer to an osm_madw_t object.
809219820Sjeff*
810219820Sjeff* RETURN VALUES
811219820Sjeff*	Pointer to the start of the context structure.
812219820Sjeff*
813219820Sjeff* NOTES
814219820Sjeff*
815219820Sjeff* SEE ALSO
816219820Sjeff*********/
817219820Sjeff
818219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_slvl_context_ptr
819219820Sjeff* NAME
820219820Sjeff*	osm_madw_get_slvl_context_ptr
821219820Sjeff*
822219820Sjeff* DESCRIPTION
823219820Sjeff*	Gets a pointer to the PortInfo context in this MAD.
824219820Sjeff*
825219820Sjeff* SYNOPSIS
826219820Sjeff*/
827219820Sjeffstatic inline osm_slvl_context_t *osm_madw_get_slvl_context_ptr(IN const
828219820Sjeff								osm_madw_t *
829219820Sjeff								const p_madw)
830219820Sjeff{
831219820Sjeff	return ((osm_slvl_context_t *) & p_madw->context);
832219820Sjeff}
833219820Sjeff
834219820Sjeff/*
835219820Sjeff* PARAMETERS
836219820Sjeff*	p_madw
837219820Sjeff*		[in] Pointer to an osm_madw_t object.
838219820Sjeff*
839219820Sjeff* RETURN VALUES
840219820Sjeff*	Pointer to the start of the context structure.
841219820Sjeff*
842219820Sjeff* NOTES
843219820Sjeff*
844219820Sjeff* SEE ALSO
845219820Sjeff*********/
846219820Sjeff
847219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_vla_context_ptr
848219820Sjeff* NAME
849219820Sjeff*	osm_madw_get_vla_context_ptr
850219820Sjeff*
851219820Sjeff* DESCRIPTION
852219820Sjeff*	Gets a pointer to the Vl Arb context in this MAD.
853219820Sjeff*
854219820Sjeff* SYNOPSIS
855219820Sjeff*/
856219820Sjeffstatic inline osm_vla_context_t *osm_madw_get_vla_context_ptr(IN const
857219820Sjeff							      osm_madw_t *
858219820Sjeff							      const p_madw)
859219820Sjeff{
860219820Sjeff	return ((osm_vla_context_t *) & p_madw->context);
861219820Sjeff}
862219820Sjeff
863219820Sjeff/*
864219820Sjeff* PARAMETERS
865219820Sjeff*	p_madw
866219820Sjeff*		[in] Pointer to an osm_madw_t object.
867219820Sjeff*
868219820Sjeff* RETURN VALUES
869219820Sjeff*	Pointer to the start of the context structure.
870219820Sjeff*
871219820Sjeff* NOTES
872219820Sjeff*
873219820Sjeff* SEE ALSO
874219820Sjeff*********/
875219820Sjeff
876219820Sjeff#ifndef OSM_VENDOR_INTF_OPENIB
877219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_arbitrary_context_ptr
878219820Sjeff* NAME
879219820Sjeff*	osm_madw_get_arbitrary_context_ptr
880219820Sjeff*
881219820Sjeff* DESCRIPTION
882219820Sjeff*	Gets a pointer to the arbitrary context in this MAD.
883219820Sjeff*
884219820Sjeff* SYNOPSIS
885219820Sjeff*/
886219820Sjeffstatic inline osm_arbitrary_context_t *osm_madw_get_arbitrary_context_ptr(IN
887219820Sjeff									  const
888219820Sjeff									  osm_madw_t
889219820Sjeff									  *
890219820Sjeff									  const
891219820Sjeff									  p_madw)
892219820Sjeff{
893219820Sjeff	return ((osm_arbitrary_context_t *) & p_madw->context);
894219820Sjeff}
895219820Sjeff
896219820Sjeff/*
897219820Sjeff* PARAMETERS
898219820Sjeff*	p_madw
899219820Sjeff*		[in] Pointer to an osm_madw_t object.
900219820Sjeff*
901219820Sjeff* RETURN VALUES
902219820Sjeff*	Pointer to the start of the context structure.
903219820Sjeff*
904219820Sjeff* NOTES
905219820Sjeff*
906219820Sjeff* SEE ALSO
907219820Sjeff*********/
908219820Sjeff#endif
909219820Sjeff
910219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_vend_ptr
911219820Sjeff* NAME
912219820Sjeff*	osm_madw_get_vend_ptr
913219820Sjeff*
914219820Sjeff* DESCRIPTION
915219820Sjeff*	Gets a pointer to the vendor specific MAD wrapper component.
916219820Sjeff*
917219820Sjeff* SYNOPSIS
918219820Sjeff*/
919219820Sjeffstatic inline osm_vend_wrap_t *osm_madw_get_vend_ptr(IN const osm_madw_t *
920219820Sjeff						     const p_madw)
921219820Sjeff{
922219820Sjeff	return ((osm_vend_wrap_t *) & p_madw->vend_wrap);
923219820Sjeff}
924219820Sjeff
925219820Sjeff/*
926219820Sjeff* PARAMETERS
927219820Sjeff*	p_madw
928219820Sjeff*		[in] Pointer to an osm_madw_t object.
929219820Sjeff*
930219820Sjeff* RETURN VALUES
931219820Sjeff*	Gets a pointer to the vendor specific MAD wrapper component.
932219820Sjeff*
933219820Sjeff* NOTES
934219820Sjeff*
935219820Sjeff* SEE ALSO
936219820Sjeff*********/
937219820Sjeff
938219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_vend_ptr
939219820Sjeff* NAME
940219820Sjeff*	osm_madw_get_vend_ptr
941219820Sjeff*
942219820Sjeff* DESCRIPTION
943219820Sjeff*	Returns the bind handle associated with this MAD.
944219820Sjeff*
945219820Sjeff* SYNOPSIS
946219820Sjeff*/
947219820Sjeffstatic inline osm_bind_handle_t
948219820Sjeffosm_madw_get_bind_handle(IN const osm_madw_t * const p_madw)
949219820Sjeff{
950219820Sjeff	return ((osm_bind_handle_t) p_madw->h_bind);
951219820Sjeff}
952219820Sjeff
953219820Sjeff/*
954219820Sjeff* PARAMETERS
955219820Sjeff*	p_madw
956219820Sjeff*		[in] Pointer to an osm_madw_t object.
957219820Sjeff*
958219820Sjeff* RETURN VALUES
959219820Sjeff*	Returns the bind handle associated with this MAD.
960219820Sjeff*
961219820Sjeff* NOTES
962219820Sjeff*
963219820Sjeff* SEE ALSO
964219820Sjeff*********/
965219820Sjeff
966219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_mad_addr_ptr
967219820Sjeff* NAME
968219820Sjeff*	osm_madw_get_mad_addr_ptr
969219820Sjeff*
970219820Sjeff* DESCRIPTION
971219820Sjeff*	Returns the mad address structure associated with this MAD.
972219820Sjeff*
973219820Sjeff* SYNOPSIS
974219820Sjeff*/
975219820Sjeffstatic inline osm_mad_addr_t *osm_madw_get_mad_addr_ptr(IN const osm_madw_t *
976219820Sjeff							const p_madw)
977219820Sjeff{
978219820Sjeff	return ((osm_mad_addr_t *) & p_madw->mad_addr);
979219820Sjeff}
980219820Sjeff
981219820Sjeff/*
982219820Sjeff* PARAMETERS
983219820Sjeff*	p_madw
984219820Sjeff*		[in] Pointer to an osm_madw_t object.
985219820Sjeff*
986219820Sjeff* RETURN VALUES
987219820Sjeff*	Returns the mad address structure associated with this MAD.
988219820Sjeff*
989219820Sjeff* NOTES
990219820Sjeff*
991219820Sjeff* SEE ALSO
992219820Sjeff*********/
993219820Sjeff
994219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_mad_ptr
995219820Sjeff* NAME
996219820Sjeff*	osm_madw_get_mad_ptr
997219820Sjeff*
998219820Sjeff* DESCRIPTION
999219820Sjeff*	Returns the mad address structure associated with this MAD.
1000219820Sjeff*
1001219820Sjeff* SYNOPSIS
1002219820Sjeff*/
1003219820Sjeffstatic inline ib_mad_t *osm_madw_get_mad_ptr(IN const osm_madw_t * const p_madw)
1004219820Sjeff{
1005219820Sjeff	return ((ib_mad_t *) p_madw->p_mad);
1006219820Sjeff}
1007219820Sjeff
1008219820Sjeff/*
1009219820Sjeff* PARAMETERS
1010219820Sjeff*	p_madw
1011219820Sjeff*		[in] Pointer to an osm_madw_t object.
1012219820Sjeff*
1013219820Sjeff* RETURN VALUES
1014219820Sjeff*	Returns the mad address structure associated with this MAD.
1015219820Sjeff*
1016219820Sjeff* NOTES
1017219820Sjeff*
1018219820Sjeff* SEE ALSO
1019219820Sjeff*********/
1020219820Sjeff
1021219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_get_err_msg
1022219820Sjeff* NAME
1023219820Sjeff*	osm_madw_get_err_msg
1024219820Sjeff*
1025219820Sjeff* DESCRIPTION
1026219820Sjeff*	Returns the message with which to post this mad wrapper if
1027219820Sjeff*	an error occurs during processing the mad.
1028219820Sjeff*
1029219820Sjeff* SYNOPSIS
1030219820Sjeff*/
1031219820Sjeffstatic inline cl_disp_msgid_t
1032219820Sjeffosm_madw_get_err_msg(IN const osm_madw_t * const p_madw)
1033219820Sjeff{
1034219820Sjeff	return ((cl_disp_msgid_t) p_madw->fail_msg);
1035219820Sjeff}
1036219820Sjeff
1037219820Sjeff/*
1038219820Sjeff* PARAMETERS
1039219820Sjeff*	p_madw
1040219820Sjeff*		[in] Pointer to an osm_madw_t object.
1041219820Sjeff*
1042219820Sjeff* RETURN VALUES
1043219820Sjeff*	Returns the message with which to post this mad wrapper if
1044219820Sjeff*	an error occurs during processing the mad.
1045219820Sjeff*
1046219820Sjeff* NOTES
1047219820Sjeff*
1048219820Sjeff* SEE ALSO
1049219820Sjeff*********/
1050219820Sjeff
1051219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_set_mad
1052219820Sjeff* NAME
1053219820Sjeff*	osm_madw_set_mad
1054219820Sjeff*
1055219820Sjeff* DESCRIPTION
1056219820Sjeff*	Associates a wire MAD with this MAD Wrapper object.
1057219820Sjeff*
1058219820Sjeff* SYNOPSIS
1059219820Sjeff*/
1060219820Sjeffstatic inline void
1061219820Sjeffosm_madw_set_mad(IN osm_madw_t * const p_madw, IN const ib_mad_t * const p_mad)
1062219820Sjeff{
1063219820Sjeff	p_madw->p_mad = p_mad;
1064219820Sjeff}
1065219820Sjeff
1066219820Sjeff/*
1067219820Sjeff* PARAMETERS
1068219820Sjeff*	p_madw
1069219820Sjeff*		[in] Pointer to an osm_madw_t object.
1070219820Sjeff*
1071219820Sjeff*	p_mad
1072219820Sjeff*		[in] Pointer to the wire MAD to attach to this wrapper.
1073219820Sjeff*
1074219820Sjeff* RETURN VALUES
1075219820Sjeff*	None.
1076219820Sjeff*
1077219820Sjeff* NOTES
1078219820Sjeff*
1079219820Sjeff* SEE ALSO
1080219820Sjeff*********/
1081219820Sjeff
1082219820Sjeff/****f* OpenSM: MAD Wrapper/osm_madw_copy_context
1083219820Sjeff* NAME
1084219820Sjeff*	osm_madw_copy_context
1085219820Sjeff*
1086219820Sjeff* DESCRIPTION
1087219820Sjeff*	Copies the controller context from one MAD Wrapper to another.
1088219820Sjeff*
1089219820Sjeff* SYNOPSIS
1090219820Sjeff*/
1091219820Sjeffstatic inline void
1092219820Sjeffosm_madw_copy_context(IN osm_madw_t * const p_dest,
1093219820Sjeff		      IN const osm_madw_t * const p_src)
1094219820Sjeff{
1095219820Sjeff	p_dest->context = p_src->context;
1096219820Sjeff}
1097219820Sjeff
1098219820Sjeff/*
1099219820Sjeff* PARAMETERS
1100219820Sjeff*	p_dest
1101219820Sjeff*		[in] Pointer to the destination osm_madw_t object.
1102219820Sjeff*
1103219820Sjeff*	p_src
1104219820Sjeff*		[in] Pointer to the source osm_madw_t object.
1105219820Sjeff*
1106219820Sjeff* RETURN VALUES
1107219820Sjeff*	None.
1108219820Sjeff*
1109219820Sjeff* NOTES
1110219820Sjeff*
1111219820Sjeff* SEE ALSO
1112219820Sjeff*********/
1113219820Sjeff
1114219820SjeffEND_C_DECLS
1115219820Sjeff#endif				/* _OSM_MADW_H_ */
1116