/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License, Version 1.0 only
* (the "License"). You may not use this file except in compliance
* with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*
* nfs_inet.h contains definitions specific to inetboot's nfs implementation.
*/
#ifndef _NFS_INET_H
#define _NFS_INET_H
#pragma ident "%Z%%M% %I% %E% SMI"
#ifdef __cplusplus
extern "C" {
#endif
#include <netinet/if_ether.h>
#include <netinet/in_systm.h>
#include <rpcsvc/nfs_prot.h>
#include <rpcsvc/nfs4_prot.h>
#include "clnt.h"
extern int nfs_readsize;
extern struct nfs_file roothandle;
extern CLIENT *root_CLIENT;
/*
* Boot specific V4 fh with maximum allowed data statically allocated
*/
struct nfs_bfh4 {
};
/*
* Boot specific V3 fh with maximum allowed data statically allocated
*/
struct nfs_bfh3 {
};
union _nfs_fh {
};
union _nfs_cookie {
};
union _nfs_ftype {
};
/*
* NFS: This structure represents the current open file.
*/
struct nfs_file {
int version;
};
struct nfs_fid {
};
/*
* Predefine an attribute bitmap that inetboot will most likely be
* interested in.
*/
typedef union attr4_bitmap1_u {
struct {
unsigned int
#ifdef _BIT_FIELDS_HTOL
#endif
#ifdef _BIT_FIELDS_LTOH
#endif
} bitmap_s;
typedef union attr4_bitmap2_u {
struct {
unsigned int
#ifdef _BIT_FIELDS_HTOL
#endif
#ifdef _BIT_FIELDS_LTOH
#endif
} bitmap_s;
typedef struct b_bitmap4 {
} b_bitmap4_t;
/*
* Define a usable set of v4 atttributes for inetboot.
*/
typedef struct b_fattr4_s {
} b_fattr4_t;
/*
* common to putfh and putfhroot.
*/
typedef struct putfh4arg_s {
} putfh4arg_t;
/*
* Use this struct to construct our OTW compound procedures. Layout makes for
* easy XDR'ing. Include putfh.
*/
typedef union compound_u {
struct {
struct {
} b_compound_t;
/*
* Define some macros for easy access into the compound structrue
*/
/*
* Define simple compound structs that include op specific data
*/
typedef struct getattrres_cmn {
/*
*/
typedef struct getattr4arg_s {
typedef struct getattr4res_s {
/*
*/
typedef struct lookup4arg_s {
} lookup4arg_t;
typedef struct lookup4res_s {
} lookup4res_t;
/*
*
* For results: use the lookup4res_t
*/
typedef struct lookupp4arg_s {
/*
*/
typedef struct read4arg_s {
} read4arg_t;
typedef struct read4res_s {
} read4res_t;
typedef struct b_entry4_s {
} b_entry4_t;
/*
*/
typedef struct readdir4arg_s {
typedef struct readdir4res_s {
/*
*/
typedef struct readlink4arg_s {
typedef struct readlink4res_s {
/*
* Generic NFS functions
*/
extern int boot_nfs_mountroot(char *);
extern int boot_nfs_unmountroot(void);
/*
* NFS Version 2 specific functions
*/
/*
* NFS Version 3 specific functions
*/
extern void nfs3_error(enum nfsstat3);
extern int nfs3getsymlink(struct nfs_file *, char **);
/*
* NFS Version 4 specific functions
*/
extern void nfs4_error(enum nfsstat4);
extern int nfs4getsymlink(struct nfs_file *, char **);
struct nfs_bfh4 *);
/*
* NFSv4 xdr ops
*/
#ifdef __cplusplus
}
#endif
#endif /* _NFS_INET_H */