nfs.h (e477abf734cc777a55286bfbd6b80a6760c96acf) nfs.h (1f60bfd8227f0972d61f5977ba62452335b757e0)
1/*-
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Rick Macklem at The University of Guelph.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 36 unchanged lines hidden (view full) ---

45#define NFS_MINTIMEO (1 * NFS_HZ) /* Min timeout to use */
46#define NFS_MAXTIMEO (60 * NFS_HZ) /* Max timeout to backoff to */
47#define NFS_TCPTIMEO 300 /* TCP timeout */
48#define NFS_MAXRCVTIMEO 60 /* 1 minute in seconds */
49#define NFS_MINIDEMTIMEO (5 * NFS_HZ) /* Min timeout for non-idempotent ops*/
50#define NFS_MAXREXMIT 100 /* Stop counting after this many */
51#define NFSV4_CALLBACKTIMEO (2 * NFS_HZ) /* Timeout in ticks */
52#define NFSV4_CALLBACKRETRY 5 /* Number of retries before failure */
1/*-
2 * Copyright (c) 1989, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Rick Macklem at The University of Guelph.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 36 unchanged lines hidden (view full) ---

45#define NFS_MINTIMEO (1 * NFS_HZ) /* Min timeout to use */
46#define NFS_MAXTIMEO (60 * NFS_HZ) /* Max timeout to backoff to */
47#define NFS_TCPTIMEO 300 /* TCP timeout */
48#define NFS_MAXRCVTIMEO 60 /* 1 minute in seconds */
49#define NFS_MINIDEMTIMEO (5 * NFS_HZ) /* Min timeout for non-idempotent ops*/
50#define NFS_MAXREXMIT 100 /* Stop counting after this many */
51#define NFSV4_CALLBACKTIMEO (2 * NFS_HZ) /* Timeout in ticks */
52#define NFSV4_CALLBACKRETRY 5 /* Number of retries before failure */
53#define NFSV4_CBSLOTS 8 /* Number of slots for session */
53#define NFSV4_CBRETRYCNT 4 /* # of CBRecall retries upon err */
54#define NFSV4_UPCALLTIMEO (15 * NFS_HZ) /* Timeout in ticks for upcalls */
55 /* to gssd or nfsuserd */
56#define NFSV4_UPCALLRETRY 4 /* Number of retries before failure */
57#define NFS_MAXWINDOW 1024 /* Max number of outstanding requests */
58#define NFS_RETRANS 10 /* Num of retrans for soft mounts */
59#define NFS_RETRANS_TCP 2 /* Num of retrans for TCP soft mounts */
60#define NFS_MAXGRPS 16 /* Max. size of groups list */

--- 34 unchanged lines hidden (view full) ---

95#define NFSUSERHASHSIZE 30 /* Size of user id hash table */
96#endif
97#ifndef NFSGROUPHASHSIZE
98#define NFSGROUPHASHSIZE 5 /* Size of group id hash table */
99#endif
100#ifndef NFSCLDELEGHIGHWATER
101#define NFSCLDELEGHIGHWATER 10000 /* limit for client delegations */
102#endif
54#define NFSV4_CBRETRYCNT 4 /* # of CBRecall retries upon err */
55#define NFSV4_UPCALLTIMEO (15 * NFS_HZ) /* Timeout in ticks for upcalls */
56 /* to gssd or nfsuserd */
57#define NFSV4_UPCALLRETRY 4 /* Number of retries before failure */
58#define NFS_MAXWINDOW 1024 /* Max number of outstanding requests */
59#define NFS_RETRANS 10 /* Num of retrans for soft mounts */
60#define NFS_RETRANS_TCP 2 /* Num of retrans for TCP soft mounts */
61#define NFS_MAXGRPS 16 /* Max. size of groups list */

--- 34 unchanged lines hidden (view full) ---

96#define NFSUSERHASHSIZE 30 /* Size of user id hash table */
97#endif
98#ifndef NFSGROUPHASHSIZE
99#define NFSGROUPHASHSIZE 5 /* Size of group id hash table */
100#endif
101#ifndef NFSCLDELEGHIGHWATER
102#define NFSCLDELEGHIGHWATER 10000 /* limit for client delegations */
103#endif
104#ifndef NFSCLLAYOUTHIGHWATER
105#define NFSCLLAYOUTHIGHWATER 10000 /* limit for client pNFS layouts */
106#endif
103#ifndef NFSNOOPEN /* Inactive open owner (sec) */
104#define NFSNOOPEN 120
105#endif
106#define NFSRV_LEASEDELTA 15 /* # of seconds to delay beyond lease */
107#define NFS_IDMAXSIZE 4 /* max sizeof (in_addr_t) */
108#ifndef NFSRVCACHE_UDPTIMEOUT
109#define NFSRVCACHE_UDPTIMEOUT 30 /* # of sec to hold cached rpcs(udp) */
110#endif

--- 413 unchanged lines hidden (view full) ---

524 struct ucred *nd_cred; /* Credentials */
525 uid_t nd_saveduid; /* Saved uid */
526 u_int64_t nd_sockref; /* Rcv socket ref# */
527 u_int64_t nd_compref; /* Compound RPC ref# */
528 time_t nd_tcpconntime; /* Time TCP connection est. */
529 nfsquad_t nd_clientid; /* Implied clientid */
530 int nd_gssnamelen; /* principal name length */
531 char *nd_gssname; /* principal name */
107#ifndef NFSNOOPEN /* Inactive open owner (sec) */
108#define NFSNOOPEN 120
109#endif
110#define NFSRV_LEASEDELTA 15 /* # of seconds to delay beyond lease */
111#define NFS_IDMAXSIZE 4 /* max sizeof (in_addr_t) */
112#ifndef NFSRVCACHE_UDPTIMEOUT
113#define NFSRVCACHE_UDPTIMEOUT 30 /* # of sec to hold cached rpcs(udp) */
114#endif

--- 413 unchanged lines hidden (view full) ---

528 struct ucred *nd_cred; /* Credentials */
529 uid_t nd_saveduid; /* Saved uid */
530 u_int64_t nd_sockref; /* Rcv socket ref# */
531 u_int64_t nd_compref; /* Compound RPC ref# */
532 time_t nd_tcpconntime; /* Time TCP connection est. */
533 nfsquad_t nd_clientid; /* Implied clientid */
534 int nd_gssnamelen; /* principal name length */
535 char *nd_gssname; /* principal name */
536 uint32_t *nd_slotseq; /* ptr to slot seq# in req */
532};
533
534#define nd_princlen nd_gssnamelen
535#define nd_principal nd_gssname
536
537/* Bits for "nd_flag" */
538#define ND_DONTSAVEREPLY 0x00000001
539#define ND_SAVEREPLY 0x00000002

--- 15 unchanged lines hidden (view full) ---

555#define ND_NFSCB 0x00020000
556#define ND_AUTHNONE 0x00040000
557#define ND_EXAUTHSYS 0x00080000
558#define ND_EXGSS 0x00100000
559#define ND_EXGSSINTEGRITY 0x00200000
560#define ND_EXGSSPRIVACY 0x00400000
561#define ND_INCRSEQID 0x00800000
562#define ND_NFSCL 0x01000000
537};
538
539#define nd_princlen nd_gssnamelen
540#define nd_principal nd_gssname
541
542/* Bits for "nd_flag" */
543#define ND_DONTSAVEREPLY 0x00000001
544#define ND_SAVEREPLY 0x00000002

--- 15 unchanged lines hidden (view full) ---

560#define ND_NFSCB 0x00020000
561#define ND_AUTHNONE 0x00040000
562#define ND_EXAUTHSYS 0x00080000
563#define ND_EXGSS 0x00100000
564#define ND_EXGSSINTEGRITY 0x00200000
565#define ND_EXGSSPRIVACY 0x00400000
566#define ND_INCRSEQID 0x00800000
567#define ND_NFSCL 0x01000000
568#define ND_NFSV41 0x02000000
569#define ND_HASSEQUENCE 0x04000000
563
564/*
565 * ND_GSS should be the "or" of all GSS type authentications.
566 */
567#define ND_GSS (ND_KERBV)
568
569struct nfsv4_opflag {
570 int retfh;
571 int needscfh;
572 int savereply;
573 int modifyfs;
574 int lktype;
570
571/*
572 * ND_GSS should be the "or" of all GSS type authentications.
573 */
574#define ND_GSS (ND_KERBV)
575
576struct nfsv4_opflag {
577 int retfh;
578 int needscfh;
579 int savereply;
580 int modifyfs;
581 int lktype;
582 int needsseq;
575};
576
577/*
578 * Flags used to indicate what to do w.r.t. seqid checking.
579 */
580#define NFSRVSEQID_FIRST 0x01
581#define NFSRVSEQID_LAST 0x02
582#define NFSRVSEQID_OPEN 0x04

--- 57 unchanged lines hidden (view full) ---

640#define NFSACCCHK_ALLOWOWNER 2
641
642/*
643 * and values for the vpislocked argument for nfsvno_accchk().
644 */
645#define NFSACCCHK_VPNOTLOCKED 0
646#define NFSACCCHK_VPISLOCKED 1
647
583};
584
585/*
586 * Flags used to indicate what to do w.r.t. seqid checking.
587 */
588#define NFSRVSEQID_FIRST 0x01
589#define NFSRVSEQID_LAST 0x02
590#define NFSRVSEQID_OPEN 0x04

--- 57 unchanged lines hidden (view full) ---

648#define NFSACCCHK_ALLOWOWNER 2
649
650/*
651 * and values for the vpislocked argument for nfsvno_accchk().
652 */
653#define NFSACCCHK_VPNOTLOCKED 0
654#define NFSACCCHK_VPISLOCKED 1
655
656/*
657 * Slot for the NFSv4.1 Sequence Op.
658 */
659struct nfsslot {
660 int nfssl_inprog;
661 uint32_t nfssl_seq;
662 struct mbuf *nfssl_reply;
663};
664
648#endif /* _KERNEL */
649
650#endif /* _NFS_NFS_H */
665#endif /* _KERNEL */
666
667#endif /* _NFS_NFS_H */