1/* $NetBSD$ */ 2 3/* 4 * Copyright (c) 1997-2009 Erez Zadok 5 * Copyright (c) 1990 Jan-Simon Pendry 6 * Copyright (c) 1990 Imperial College of Science, Technology & Medicine 7 * Copyright (c) 1990 The Regents of the University of California. 8 * All rights reserved. 9 * 10 * This code is derived from software contributed to Berkeley by 11 * Jan-Simon Pendry at Imperial College, London. 12 * 13 * Redistribution and use in source and binary forms, with or without 14 * modification, are permitted provided that the following conditions 15 * are met: 16 * 1. Redistributions of source code must retain the above copyright 17 * notice, this list of conditions and the following disclaimer. 18 * 2. Redistributions in binary form must reproduce the above copyright 19 * notice, this list of conditions and the following disclaimer in the 20 * documentation and/or other materials provided with the distribution. 21 * 3. All advertising materials mentioning features or use of this software 22 * must display the following acknowledgment: 23 * This product includes software developed by the University of 24 * California, Berkeley and its contributors. 25 * 4. Neither the name of the University nor the names of its contributors 26 * may be used to endorse or promote products derived from this software 27 * without specific prior written permission. 28 * 29 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 30 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 31 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 32 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 33 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 34 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 35 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 36 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 37 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 38 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 39 * SUCH DAMAGE. 40 * 41 * 42 * File: am-utils/conf/nfs_prot/nfs_prot_netbsd1_3.h 43 * 44 */ 45 46#ifndef _AMU_NFS_PROT_H 47#define _AMU_NFS_PROT_H 48 49#ifdef HAVE_RPCSVC_NFS_PROT_H 50# include <rpcsvc/nfs_prot.h> 51#endif /* HAVE_RPCSVC_NFS_PROT_H */ 52 53/* NON-NFS STUFF (doesn't really belong here) */ 54#ifndef DEFINED_YPALL_CALLBACK_FXN_T 55# define DEFINED_YPALL_CALLBACK_FXN_T 56#if 0 57/* this is RIGHT for 1.2G and 1.2.1 */ 58typedef int (*ypall_callback_fxn_t)(u_long, char *, int, char *, int, void *); 59#endif /* 0 */ 60/* this is right for 1.3beta and newer */ 61typedef int (*ypall_callback_fxn_t)(int, char *, int, char *, int, char *); 62#endif /* DEFINED_YPALL_CALLBACK_FXN_T */ 63 64 65/* 66 * MACROS: 67 */ 68#define dr_drok_u diropres 69#define ca_where where 70#define da_fhandle dir 71#define da_name name 72#define dl_entries entries 73#define dl_eof eof 74#define dr_status status 75#define dr_u diropres_u 76#define drok_attributes attributes 77#define drok_fhandle file 78#define fh_data data 79#define la_fhandle from 80#define la_to to 81#define na_atime atime 82#define na_ctime ctime 83#define na_fileid fileid 84#define na_fsid fsid 85#define na_mode mode 86#define na_mtime mtime 87#define na_nlink nlink 88#define na_size size 89#define na_type type 90#define ne_cookie cookie 91#define ne_fileid fileid 92#define ne_name name 93#define ne_nextentry nextentry 94#define ns_attr_u attributes 95#define ns_status status 96#define ns_u attrstat_u 97#define nt_seconds seconds 98#define nt_useconds useconds 99#define rda_cookie cookie 100#define rda_count count 101#define rda_fhandle dir 102#define rdr_reply_u reply 103#define rdr_status status 104#define rdr_u readdirres_u 105#define rlr_data_u data 106#define rlr_status status 107#define rlr_u readlinkres_u 108#define rna_from from 109#define rna_to to 110#define rr_status status 111#define sag_fhandle file 112#define sfr_reply_u reply 113#define sfr_status status 114#define sfr_u statfsres_u 115#define sfrok_bavail bavail 116#define sfrok_bfree bfree 117#define sfrok_blocks blocks 118#define sfrok_bsize bsize 119#define sfrok_tsize tsize 120#define sla_from from 121#define wra_fhandle file 122 123 124/* 125 * TYPEDEFS: 126 */ 127typedef attrstat nfsattrstat; 128typedef createargs nfscreateargs; 129typedef dirlist nfsdirlist; 130typedef diropargs nfsdiropargs; 131typedef diropres nfsdiropres; 132typedef entry nfsentry; 133typedef fattr nfsfattr; 134typedef ftype nfsftype; 135typedef linkargs nfslinkargs; 136typedef readargs nfsreadargs; 137typedef readdirargs nfsreaddirargs; 138typedef readdirres nfsreaddirres; 139typedef readlinkres nfsreadlinkres; 140typedef readres nfsreadres; 141typedef renameargs nfsrenameargs; 142typedef sattrargs nfssattrargs; 143typedef statfsokres nfsstatfsokres; 144typedef statfsres nfsstatfsres; 145typedef symlinkargs nfssymlinkargs; 146typedef writeargs nfswriteargs; 147 148/* 149 * 150 * NetBSD 1.2 has NFS V3, but it is undefined in the header files. 151 * so I define everything that's needed for NFS V3 here. 152 */ 153#ifdef NFSMNT_NFSV3 154 155# define MOUNT_NFS3 MOUNT_NFS 156# define MNTOPT_NFS3 "nfs" 157 158#endif /* NFSMNT_NFSV3 */ 159 160#endif /* not _AMU_NFS_PROT_H */ 161