1219820Sjeff/*
2219820Sjeff * Copyright (c) 2005 Intel Inc. All rights reserved.
3219820Sjeff *
4219820Sjeff * This software is available to you under a choice of one of two
5219820Sjeff * licenses.  You may choose to be licensed under the terms of the GNU
6219820Sjeff * General Public License (GPL) Version 2, available from the file
7219820Sjeff * COPYING in the main directory of this source tree, or the
8219820Sjeff * OpenIB.org BSD license below:
9219820Sjeff *
10219820Sjeff *     Redistribution and use in source and binary forms, with or
11219820Sjeff *     without modification, are permitted provided that the following
12219820Sjeff *     conditions are met:
13219820Sjeff *
14219820Sjeff *      - Redistributions of source code must retain the above
15219820Sjeff *        copyright notice, this list of conditions and the following
16219820Sjeff *        disclaimer.
17219820Sjeff *
18219820Sjeff *      - Redistributions in binary form must reproduce the above
19219820Sjeff *        copyright notice, this list of conditions and the following
20219820Sjeff *        disclaimer in the documentation and/or other materials
21219820Sjeff *        provided with the distribution.
22219820Sjeff *
23219820Sjeff * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24219820Sjeff * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25219820Sjeff * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26219820Sjeff * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27219820Sjeff * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28219820Sjeff * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29219820Sjeff * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30219820Sjeff * SOFTWARE.
31219820Sjeff */
32219820Sjeff
33219820Sjeff#ifndef __MAD_RMPP_H__
34219820Sjeff#define __MAD_RMPP_H__
35219820Sjeff
36219820Sjeffenum {
37219820Sjeff	IB_RMPP_RESULT_PROCESSED,
38219820Sjeff	IB_RMPP_RESULT_CONSUMED,
39219820Sjeff	IB_RMPP_RESULT_INTERNAL,
40219820Sjeff	IB_RMPP_RESULT_UNHANDLED
41219820Sjeff};
42219820Sjeff
43219820Sjeffint ib_send_rmpp_mad(struct ib_mad_send_wr_private *mad_send_wr);
44219820Sjeff
45219820Sjeffstruct ib_mad_recv_wc *
46219820Sjeffib_process_rmpp_recv_wc(struct ib_mad_agent_private *agent,
47219820Sjeff			struct ib_mad_recv_wc *mad_recv_wc);
48219820Sjeff
49219820Sjeffint ib_process_rmpp_send_wc(struct ib_mad_send_wr_private *mad_send_wr,
50219820Sjeff			    struct ib_mad_send_wc *mad_send_wc);
51219820Sjeff
52219820Sjeffvoid ib_rmpp_send_handler(struct ib_mad_send_wc *mad_send_wc);
53219820Sjeff
54219820Sjeffvoid ib_cancel_rmpp_recvs(struct ib_mad_agent_private *agent);
55219820Sjeff
56219820Sjeffint ib_retry_rmpp(struct ib_mad_send_wr_private *mad_send_wr);
57219820Sjeff
58219820Sjeff#endif	/* __MAD_RMPP_H__ */
59