Add the missing "; \".
[glibc.git] / sunrpc / rpcsvc / bootparam_prot.x
blobf272d52ae55821dd9bbfc122d0de4afeb78a72ca
1 /* @(#)bootparam_prot.x 2.1 88/08/01 4.0 RPCSRC */
2 /* @(#)bootparam_prot.x 1.2 87/06/24 Copyr 1987 Sun Micro */
4 /*
5  * Redistribution and use in source and binary forms, with or without
6  * modification, are permitted provided that the following conditions are
7  * met:
8  *
9  *     * Redistributions of source code must retain the above copyright
10  *       notice, this list of conditions and the following disclaimer.
11  *     * Redistributions in binary form must reproduce the above
12  *       copyright notice, this list of conditions and the following
13  *       disclaimer in the documentation and/or other materials
14  *       provided with the distribution.
15  *     * Neither the name of Sun Microsystems, Inc. nor the names of its
16  *       contributors may be used to endorse or promote products derived
17  *       from this software without specific prior written permission.
18  *
19  *   THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20  *   "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21  *   LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
22  *   FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
23  *   COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
24  *   INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25  *   DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
26  *   GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27  *   INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
28  *   WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
29  *   NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  *   OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
34  * RPC for bootparms service.
35  * There are two procedures:
36  *   WHOAMI takes a net address and returns a client name and also a
37  *      likely net address for routing
38  *   GETFILE takes a client name and file identifier and returns the
39  *      server name, server net address and pathname for the file.
40  *   file identifiers typically include root, swap, pub and dump
41  */
43 #ifdef RPC_HDR
44 %#include <rpc/types.h>
45 %#include <sys/time.h>
46 %#include <sys/errno.h>
47 %#include <nfs/nfs.h>
48 #endif
50 const MAX_MACHINE_NAME  = 255;
51 const MAX_PATH_LEN      = 1024;
52 const MAX_FILEID        = 32;
53 const IP_ADDR_TYPE      = 1;
55 typedef string  bp_machine_name_t<MAX_MACHINE_NAME>;
56 typedef string  bp_path_t<MAX_PATH_LEN>;
57 typedef string  bp_fileid_t<MAX_FILEID>;
59 struct  ip_addr_t {
60         char    net;
61         char    host;
62         char    lh;
63         char    impno;
66 union bp_address switch (int address_type) {
67         case IP_ADDR_TYPE:
68                 ip_addr_t       ip_addr;
71 struct bp_whoami_arg {
72         bp_address              client_address;
75 struct bp_whoami_res {
76         bp_machine_name_t       client_name;
77         bp_machine_name_t       domain_name;
78         bp_address              router_address;
81 struct bp_getfile_arg {
82         bp_machine_name_t       client_name;
83         bp_fileid_t             file_id;
86 struct bp_getfile_res {
87         bp_machine_name_t       server_name;
88         bp_address              server_address;
89         bp_path_t               server_path;
92 program BOOTPARAMPROG {
93         version BOOTPARAMVERS {
94                 bp_whoami_res   BOOTPARAMPROC_WHOAMI(bp_whoami_arg) = 1;
95                 bp_getfile_res  BOOTPARAMPROC_GETFILE(bp_getfile_arg) = 2;
96         } = 1;
97 } = 100026;