svc_dg.h revision 1.1.66.1 1 1.1.66.1 riz /* $NetBSD: svc_dg.h,v 1.1.66.1 2013/03/14 22:03:10 riz Exp $ */
2 1.1 fvdl /*
3 1.1.66.1 riz * Copyright (c) 2010, Oracle America, Inc.
4 1.1.66.1 riz *
5 1.1.66.1 riz * Redistribution and use in source and binary forms, with or without
6 1.1.66.1 riz * modification, are permitted provided that the following conditions are
7 1.1.66.1 riz * met:
8 1.1.66.1 riz *
9 1.1.66.1 riz * * Redistributions of source code must retain the above copyright
10 1.1.66.1 riz * notice, this list of conditions and the following disclaimer.
11 1.1.66.1 riz * * Redistributions in binary form must reproduce the above
12 1.1.66.1 riz * copyright notice, this list of conditions and the following
13 1.1.66.1 riz * disclaimer in the documentation and/or other materials
14 1.1.66.1 riz * provided with the distribution.
15 1.1.66.1 riz * * Neither the name of the "Oracle America, Inc." nor the names of its
16 1.1.66.1 riz * contributors may be used to endorse or promote products derived
17 1.1.66.1 riz * from this software without specific prior written permission.
18 1.1.66.1 riz *
19 1.1.66.1 riz * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20 1.1.66.1 riz * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21 1.1.66.1 riz * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
22 1.1.66.1 riz * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
23 1.1.66.1 riz * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
24 1.1.66.1 riz * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 1.1.66.1 riz * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
26 1.1.66.1 riz * GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 1.1.66.1 riz * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28 1.1.66.1 riz * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
29 1.1.66.1 riz * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30 1.1.66.1 riz * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31 1.1 fvdl */
32 1.1 fvdl
33 1.1 fvdl /*
34 1.1 fvdl * XXX - this file exists only so that the rpcbind code can pull it in.
35 1.1 fvdl * This should go away. It should only be include by svc_dg.c and
36 1.1 fvdl * rpcb_svc_com.c in the rpcbind code.
37 1.1 fvdl */
38 1.1 fvdl
39 1.1 fvdl /*
40 1.1 fvdl * kept in xprt->xp_p2
41 1.1 fvdl */
42 1.1 fvdl struct svc_dg_data {
43 1.1 fvdl /* XXX: optbuf should be the first field, used by ti_opts.c code */
44 1.1 fvdl size_t su_iosz; /* size of send.recv buffer */
45 1.1 fvdl u_int32_t su_xid; /* transaction id */
46 1.1 fvdl XDR su_xdrs; /* XDR handle */
47 1.1 fvdl char su_verfbody[MAX_AUTH_BYTES]; /* verifier body */
48 1.1 fvdl void *su_cache; /* cached data, NULL if none */
49 1.1 fvdl };
50 1.1 fvdl
51 1.1 fvdl #define __rpcb_get_dg_xidp(x) (&((struct svc_dg_data *)(x)->xp_p2)->su_xid)
52