2 * This software has been released under the terms of the IBM Public
3 * License. For details, see the LICENSE file in the top-level source
4 * directory or online at http://www.openafs.org/dl/license10.html
10 #include <afsconfig.h>
11 #include "../afs/param.h"
15 #include "../afs/stds.h"
16 #include "../afs/sysincludes.h" /* Standard vendor system headers */
17 #if defined(AFS_SUN55_ENV) && !defined(AFS_NONFSTRANS)
18 #include "../rpc/types.h"
19 #include "../rpc/auth.h"
20 #include "../rpc/auth_unix.h"
21 #include "../rpc/auth_des.h"
22 #if !defined(AFS_SUN58_ENV)
23 #include "../rpc/auth_kerb.h"
25 #include "../sys/tiuser.h"
26 #include "../rpc/xdr.h"
27 #include "../rpc/svc.h"
28 #include "../nfs/nfs.h"
29 #include "../nfs/export.h"
30 #include "../nfs/nfs_clnt.h"
31 #include "../nfs/nfs_acl.h"
32 #include "../afs/afsincludes.h"
33 #include "../afs/afs_stats.h"
34 #include "../afs/exporter.h"
36 static int xlatorinit_v2_done=0;
37 static int xlatorinit_v3_done=0;
39 extern int afs_nobody;
40 extern int afs_NFSRootOnly;
42 /* It's bigger than this, but we don't care about anything else */
47 struct afs_nfs_disp_tbl {
52 struct afs_nfs2_resp {
60 struct afs_nfs_disp_tbl afs_rfs_disp_tbl[RFS_NPROC];
61 struct afs_nfs_disp_tbl afs_acl_disp_tbl[ACL2_NPROC];
64 is_afs_fh(fhandle_t *fhp) {
65 if ((fhp->fh_fsid.val[0] == AFS_VFSMAGIC) &&
66 (fhp->fh_fsid.val[1] == AFS_VFSFSID))
72 nfs2_to_afs_call(int which, caddr_t *args, fhandle_t **fhpp, fhandle_t **fh2pp)
79 *fh2pp = (fhandle_t *)0;
84 fhp1 = (fhandle_t *)args;
88 struct nfssaargs *sargs = (struct nfssaargs *)args;
89 fhp1 = (fhandle_t *)&sargs->saa_fh;
94 struct nfsdiropargs *sargs = (struct nfsdiropargs *)args;
95 fhp1 = (fhandle_t *)&sargs->da_fhandle;
100 struct nfsreadargs *sargs = (struct nfsreadargs *)args;
101 fhp1 = (fhandle_t *)&sargs->ra_fhandle;
106 struct nfswriteargs *sargs = (struct nfswriteargs *)args;
107 fhp1 = (fhandle_t *)&sargs->wa_fhandle;
112 struct nfscreatargs *sargs = (struct nfscreatargs *)args;
113 fhp1 = (fhandle_t *)&sargs->ca_da.da_fhandle;
118 struct nfsdiropargs *sargs = (struct nfsdiropargs *)args;
119 fhp1 = (fhandle_t *)&sargs->da_fhandle;
124 struct nfsrnmargs *sargs = (struct nfsrnmargs *)args;
125 fhp1 = (fhandle_t *)&sargs->rna_from.da_fhandle;
126 fhp2 = (fhandle_t *)&sargs->rna_to.da_fhandle;
131 struct nfslinkargs *sargs = (struct nfslinkargs *)args;
132 fhp1 = (fhandle_t *)&sargs->la_from;
133 fhp2 = (fhandle_t *)&sargs->la_to.da_fhandle;
138 struct nfsslargs *sargs = (struct nfsslargs *)args;
139 fhp1 = (fhandle_t *)&sargs->sla_from.da_fhandle;
144 struct nfscreatargs *sargs = (struct nfscreatargs *)args;
145 fhp1 = (fhandle_t *)&sargs->ca_da.da_fhandle;
150 struct nfsdiropargs *sargs = (struct nfsdiropargs *)args;
151 fhp1 = (fhandle_t *)&sargs->da_fhandle;
156 struct nfsrddirargs *sargs = (struct nfsrddirargs *)args;
157 fhp1 = (fhandle_t *)&sargs->rda_fh;
164 /* Ok if arg 1 is in AFS or if 2 args and arg 2 is in AFS */
165 if (is_afs_fh(fhp1)) {
171 if (is_afs_fh(fhp2)) {
180 acl2_to_afs_call(int which, caddr_t *args, fhandle_t **fhpp)
189 case ACLPROC2_GETACL:
191 struct GETACL2args *sargs = (struct GETACL2args *) args;
195 case ACLPROC2_SETACL:
197 struct SETACL2args *sargs = (struct SETACL2args *) args;
201 case ACLPROC2_GETATTR:
203 struct GETATTR2args *sargs = (struct GETATTR2args *) args;
207 case ACLPROC2_ACCESS:
209 struct ACCESS2args *sargs = (struct ACCESS2args *) args;
217 if (is_afs_fh(fhp)) {
226 afs_nfs2_dispatcher(int type, afs_int32 which, char *argp,
227 struct exportinfo **expp,
228 struct svc_req *rp, struct AFS_UCRED *crp)
232 afs_int32 client = 0;
234 fhandle_t *fh = (fhandle_t *)argp;
235 fhandle_t *fh2 = (fhandle_t *)0;
237 if (!xlatorinit_v2_done)
240 sa = (struct sockaddr *)svc_getrpccaller(rp->rq_xprt)->buf;
241 client = ((struct sockaddr_in *)sa)->sin_addr.s_addr;
247 code = nfs2_to_afs_call(which, argp, &fh, &fh2);
250 code = acl2_to_afs_call(which, argp, &fh);
257 struct afs_exporter *out = 0;
260 struct SmallFid Sfid;
262 memcpy((char *)&Sfid, fh->fh_data, SIZEOF_SMALLFID);
266 if (!once && *expp) {
267 afs_nobody = (*expp)->exi_export.ex_anon;
270 code = afs_nfsclient_reqhandler((struct afs_exporter *)0, &crp,
271 client, &dummy, &out);
272 /* Be careful to release this */
276 /* We ran and failed */
286 afs_nfs2_smallfidder(struct nfsdiropres *dr)
288 register fhandle_t *fhp = (fhandle_t *)&dr->dr_fhandle;
292 #if defined(AFS_SUN57_64BIT_ENV)
293 /* See also afs_fid() */
294 memcpy((char *)addr, fhp->fh_data, 10);
295 addr[1] = (addr[1] >> 48) & 0xffff;
297 memcpy((char *)addr, fhp->fh_data, 2 * sizeof(long));
301 vcp = VTOAFS((struct vnode*)addr[0]);
303 /* See also afs_osi_vget */
304 if (addr[1] == AFS_XLATOR_MAGIC)
306 if (dr->dr_status == NFS_OK) {
307 struct SmallFid Sfid;
310 /* Make up and copy out a SmallFid */
311 tcell = afs_GetCell(vcp->fid.Cell, READ_LOCK);
312 Sfid.Volume = vcp->fid.Fid.Volume;
313 Sfid.CellAndUnique = ((tcell->cellIndex << 24) |
314 (vcp->fid.Fid.Unique & 0xffffff));
315 afs_PutCell(tcell, READ_LOCK);
316 Sfid.Vnode = (u_short)(vcp->fid.Fid.Vnode & 0xffff);
317 fhp->fh_len = SIZEOF_SMALLFID;
318 memcpy(dr->dr_fhandle.fh_data, (char*)&Sfid, fhp->fh_len);
321 /* If we have a ref, release it */
322 if (vcp->vrefCount >= 1)
323 AFS_RELE(AFSTOV(vcp));
329 afs_nfs2_noaccess(struct afs_nfs2_resp *resp)
331 resp->status = NFSERR_ACCES;
334 void afs_nfs2_null(char *args, char *xp, char *exp, char *rp, char *crp)
339 afs_nfs2_root(char *args, char *xp, char *exp, char *rp, char *crp)
344 afs_nfs2_writecache(char *args, char *xp, char *exp, char *rp, char *crp)
348 #define NFS_V2_REQ(FUNCNAME, RFSOP, POST) \
349 void FUNCNAME(char *args, char *xp, char *exp, char *rp, char *crp) { \
351 struct cred *svcred = curthread->t_cred; \
352 curthread->t_cred = (struct cred*)crp; \
353 call=afs_nfs2_dispatcher(0, RFSOP, (char *)args, &exp, rp, crp); \
354 if (call>1) afs_nfs2_noaccess((struct afs_nfs2_resp *)xp); \
355 else { (*afs_rfs_disp_tbl[RFSOP].orig_proc)(args, xp, exp, rp, crp); \
356 if (POST && afs_NFSRootOnly && call) afs_nfs2_smallfidder(xp); } \
357 curthread->t_cred = svcred; \
361 NFS_V2_REQ(afs_nfs2_getattr, RFS_GETATTR, 0)
362 NFS_V2_REQ(afs_nfs2_setattr, RFS_SETATTR, 0)
363 NFS_V2_REQ(afs_nfs2_lookup, RFS_LOOKUP, 1)
364 NFS_V2_REQ(afs_nfs2_readlink, RFS_READLINK, 0)
365 NFS_V2_REQ(afs_nfs2_read, RFS_READ, 0)
366 NFS_V2_REQ(afs_nfs2_write, RFS_WRITE, 0)
367 NFS_V2_REQ(afs_nfs2_create, RFS_CREATE, 1)
368 NFS_V2_REQ(afs_nfs2_remove, RFS_REMOVE, 0)
369 NFS_V2_REQ(afs_nfs2_rename, RFS_RENAME, 0)
370 NFS_V2_REQ(afs_nfs2_link, RFS_LINK, 0)
371 NFS_V2_REQ(afs_nfs2_symlink, RFS_SYMLINK, 0)
372 NFS_V2_REQ(afs_nfs2_mkdir, RFS_MKDIR, 1)
373 NFS_V2_REQ(afs_nfs2_rmdir, RFS_RMDIR, 0)
374 NFS_V2_REQ(afs_nfs2_readdir, RFS_READDIR, 0)
375 NFS_V2_REQ(afs_nfs2_statfs, RFS_STATFS, 0)
377 struct afs_nfs_disp_tbl afs_rfs_disp_tbl[RFS_NPROC] = {
379 { afs_nfs2_getattr },
380 { afs_nfs2_setattr },
383 { afs_nfs2_readlink },
385 { afs_nfs2_writecache },
391 { afs_nfs2_symlink },
394 { afs_nfs2_readdir },
398 #define ACL_V2_REQ(FUNCNAME, ACLOP) \
399 void FUNCNAME(char *args, char *xp, char *exp, char *rp, char *crp) { \
401 struct cred *svcred = curthread->t_cred; \
402 curthread->t_cred = (struct cred*)crp; \
403 call=afs_nfs2_dispatcher(1, ACLOP, (char *)args, &exp, rp, crp); \
404 if (call>1) afs_nfs2_noaccess((struct afs_nfs2_resp *)xp); \
405 else (*afs_rfs_disp_tbl[ACLOP].orig_proc)(args, xp, exp, rp, crp); \
406 curthread->t_cred = svcred; \
410 ACL_V2_REQ(afs_acl2_getacl, ACLPROC2_GETACL)
411 ACL_V2_REQ(afs_acl2_setacl, ACLPROC2_SETACL)
412 ACL_V2_REQ(afs_acl2_getattr, ACLPROC2_GETATTR)
413 ACL_V2_REQ(afs_acl2_access, ACLPROC2_ACCESS)
415 struct afs_nfs_disp_tbl afs_acl_disp_tbl[ACL2_NPROC] = {
419 { afs_acl2_getattr },
423 /* Munge the dispatch tables to link us in first */
425 afs_xlatorinit_v2(struct rfs_disp_tbl *_rfs_tbl,
426 struct rfs_disp_tbl *_acl_tbl)
430 if (xlatorinit_v2_done++) return;
432 for (i=0; i < RFS_NPROC; i++) {
433 afs_rfs_disp_tbl[i].orig_proc = _rfs_tbl[i].dis_proc;
434 _rfs_tbl[i].dis_proc = afs_rfs_disp_tbl[i].afs_proc;
437 for (i=0; i < ACL2_NPROC; i++) {
438 afs_acl_disp_tbl[i].orig_proc = _acl_tbl[i].dis_proc;
439 _acl_tbl[i].dis_proc = afs_acl_disp_tbl[i].afs_proc;
444 #define RFS3_NPROC 22
451 struct afs_nfs_disp_tbl afs_rfs3_disp_tbl[RFS3_NPROC];
452 struct afs_nfs_disp_tbl afs_acl3_disp_tbl[ACL3_NPROC];
454 struct afs_nfs3_resp {
458 typedef struct afs_nfs3_resp afs_nfs3_resp;
461 is_afs_fh3(nfs_fh3 *fhp) {
462 if ((fhp->fh3_fsid.val[0] == AFS_VFSMAGIC) &&
463 (fhp->fh3_fsid.val[1] == AFS_VFSFSID))
469 afs_nfs3_noaccess(struct afs_nfs3_resp *resp)
471 resp->status = NFS3ERR_ACCES;
476 nfs3_to_afs_call(int which, caddr_t *args, nfs_fh3 **fhpp, nfs_fh3 **fh2pp)
483 *fh2pp = (nfs_fh3 *)0;
485 case NFSPROC3_GETATTR:
487 GETATTR3args *arg = (GETATTR3args *)args;
488 fhp1 = (nfs_fh3 *) &arg->object;
491 case NFSPROC3_SETATTR:
493 SETATTR3args *arg = (SETATTR3args *)args;
494 fhp1 = (nfs_fh3 *) &arg->object;
497 case NFSPROC3_LOOKUP:
499 LOOKUP3args *arg = (LOOKUP3args *)args;
500 fhp1 = (nfs_fh3 *) &arg->what.dirp;
503 case NFSPROC3_ACCESS:
505 ACCESS3args *arg = (ACCESS3args *)args;
506 fhp1 = (nfs_fh3 *) &arg->object;
509 case NFSPROC3_READLINK:
511 READLINK3args *arg = (READLINK3args *)args;
512 fhp1 = (nfs_fh3 *) &arg->symlink;
517 READ3args *arg = (READ3args *)args;
518 fhp1 = (nfs_fh3 *) &arg->file;
523 WRITE3args *arg = (WRITE3args *)args;
524 fhp1 = (nfs_fh3 *) &arg->file;
527 case NFSPROC3_CREATE:
529 CREATE3args *arg = (CREATE3args *)args;
530 fhp1 = (nfs_fh3 *) &arg->where.dir;
535 MKDIR3args *arg = (MKDIR3args *)args;
536 fhp1 = (nfs_fh3 *) &arg->where.dir;
539 case NFSPROC3_SYMLINK:
541 SYMLINK3args *arg = (SYMLINK3args *)args;
542 fhp1 = (nfs_fh3 *) &arg->where.dir;
547 MKNOD3args *arg = (MKNOD3args *)args;
548 fhp1 = (nfs_fh3 *) &arg->where.dir;
551 case NFSPROC3_REMOVE:
553 REMOVE3args *arg = (REMOVE3args *)args;
554 fhp1 = (nfs_fh3 *) &arg->object.dir;
559 RMDIR3args *arg = (RMDIR3args *)args;
560 fhp1 = (nfs_fh3 *) &arg->object.dir;
563 case NFSPROC3_RENAME:
565 RENAME3args *arg = (RENAME3args *)args;
566 fhp1 = (nfs_fh3 *) &arg->from.dir;
567 fhp2 = (nfs_fh3 *) &arg->to.dir;
572 LINK3args *arg = (LINK3args *)args;
573 fhp1 = (nfs_fh3 *) &arg->file;
574 fhp2 = (nfs_fh3 *) &arg->link.dir;
577 case NFSPROC3_READDIR:
579 READDIR3args *arg = (READDIR3args *)args;
580 fhp1 = (nfs_fh3 *) &arg->dir;
583 case NFSPROC3_READDIRPLUS:
585 READDIRPLUS3args *arg = (READDIRPLUS3args *)args;
586 fhp1 = (nfs_fh3 *) &arg->dir;
589 case NFSPROC3_FSSTAT:
591 FSSTAT3args *arg = (FSSTAT3args *)args;
592 fhp1 = (nfs_fh3 *) &arg->fsroot;
595 case NFSPROC3_FSINFO:
597 FSINFO3args *arg = (FSINFO3args *)args;
598 fhp1 = (nfs_fh3 *) &arg->fsroot;
601 case NFSPROC3_PATHCONF:
603 PATHCONF3args *arg = (PATHCONF3args *)args;
604 fhp1 = (nfs_fh3 *) &arg->object;
607 case NFSPROC3_COMMIT:
609 COMMIT3args *arg = (COMMIT3args *)args;
610 fhp1 = (nfs_fh3 *) &arg->file;
617 /* Ok if arg 1 is in AFS or if 2 args and arg 2 is in AFS */
618 if (is_afs_fh3(fhp1)) {
624 if (is_afs_fh3(fhp2)) {
633 acl3_to_afs_call(int which, caddr_t *args, nfs_fh3 **fhpp)
638 case ACLPROC3_GETACL:
640 struct GETACL3args *sargs = (struct GETACL3args *) args;
644 case ACLPROC3_SETACL:
646 struct SETACL3args *sargs = (struct SETACL3args *) args;
654 if (is_afs_fh3(fhp)) {
663 afs_nfs3_dispatcher(int type, afs_int32 which, char *argp,
664 struct exportinfo **expp,
665 struct svc_req *rp, struct AFS_UCRED *crp)
669 afs_int32 client = 0;
671 nfs_fh3 *fh = (nfs_fh3 *)argp;
672 nfs_fh3 *fh2 = (nfs_fh3 *)0;
674 if (!xlatorinit_v3_done)
677 sa = (struct sockaddr *)svc_getrpccaller(rp->rq_xprt)->buf;
678 client = ((struct sockaddr_in *)sa)->sin_addr.s_addr;
684 code = nfs3_to_afs_call(which, argp, &fh, &fh2);
687 code = acl3_to_afs_call(which, argp, &fh);
694 struct afs_exporter *out = 0;
697 struct SmallFid Sfid;
699 memcpy((char *)&Sfid, fh->fh3_data, SIZEOF_SMALLFID);
703 if (!once && *expp) {
704 afs_nobody = (*expp)->exi_export.ex_anon;
707 code = afs_nfsclient_reqhandler((struct afs_exporter *)0, &crp,
708 client, &dummy, &out);
709 /* Be careful to release this */
713 /* We ran and failed */
723 afs_nfs3_smallfidder(struct nfs_fh3 *fhp, int status)
728 #if defined(AFS_SUN57_64BIT_ENV)
729 /* See also afs_fid() */
730 memcpy((char *)addr, fhp->fh3_data, 10);
731 addr[1] = (addr[1] >> 48) & 0xffff;
733 memcpy((char *)addr, fhp->fh3_data, 2 * sizeof(long));
737 vcp = VTOAFS((struct vnode*)addr[0]);
739 /* See also afs_osi_vget */
740 if (addr[1] == AFS_XLATOR_MAGIC)
742 if (status == NFS_OK) {
743 struct SmallFid Sfid;
746 /* Make up and copy out a SmallFid */
747 tcell = afs_GetCell(vcp->fid.Cell, READ_LOCK);
748 Sfid.Volume = vcp->fid.Fid.Volume;
749 Sfid.CellAndUnique = ((tcell->cellIndex << 24) |
750 (vcp->fid.Fid.Unique & 0xffffff));
751 afs_PutCell(tcell, READ_LOCK);
752 Sfid.Vnode = (u_short)(vcp->fid.Fid.Vnode & 0xffff);
753 fhp->fh3_len = SIZEOF_SMALLFID;
754 memcpy(fhp->fh3_data, (char*)&Sfid, fhp->fh3_len);
757 /* If we have a ref, release it */
758 if (vcp->vrefCount >= 1)
759 AFS_RELE(AFSTOV(vcp));
764 #define NFS_V3_REQ(FUNCNAME, NFSOP, POST, RESP, RESPP) \
765 void FUNCNAME(char *args, char *xp, char *exp, char *rp, char *crp) { \
767 afs_nfs3_resp dummy; \
768 struct cred *svcred = curthread->t_cred; \
769 curthread->t_cred = (struct cred*)crp; \
770 call=afs_nfs3_dispatcher(0, NFSOP, (char *)args, &exp, rp, crp); \
771 if (call>1) afs_nfs3_noaccess((struct afs_nfs3_resp *)xp); \
772 else { (*afs_rfs3_disp_tbl[NFSOP].orig_proc)(args, xp, exp, rp, crp); \
773 if (POST && afs_NFSRootOnly && call) { \
774 RESP *resp = ( RESP *)xp; \
775 afs_nfs3_smallfidder( RESPP , resp->status); } } \
776 curthread->t_cred = svcred; \
780 NFS_V3_REQ(afs_nfs3_getattr, NFSPROC3_GETATTR, 0, afs_nfs3_resp, &dummy)
781 NFS_V3_REQ(afs_nfs3_setattr, NFSPROC3_SETATTR, 0, afs_nfs3_resp, &dummy)
782 NFS_V3_REQ(afs_nfs3_lookup, NFSPROC3_LOOKUP, 1, LOOKUP3res, &resp->resok.object)
783 NFS_V3_REQ(afs_nfs3_access, NFSPROC3_ACCESS, 0, afs_nfs3_resp, &dummy)
784 NFS_V3_REQ(afs_nfs3_readlink, NFSPROC3_READLINK, 0, afs_nfs3_resp, &dummy)
785 NFS_V3_REQ(afs_nfs3_read, NFSPROC3_READ, 0, afs_nfs3_resp, &dummy)
786 NFS_V3_REQ(afs_nfs3_write, NFSPROC3_WRITE, 0, afs_nfs3_resp, &dummy)
787 NFS_V3_REQ(afs_nfs3_create, NFSPROC3_CREATE, 1, CREATE3res, &resp->resok.obj.handle)
788 NFS_V3_REQ(afs_nfs3_mkdir, NFSPROC3_MKDIR, 1, MKDIR3res, &resp->resok.obj.handle)
789 NFS_V3_REQ(afs_nfs3_symlink, NFSPROC3_SYMLINK, 0, afs_nfs3_resp, &dummy)
790 NFS_V3_REQ(afs_nfs3_mknod, NFSPROC3_MKNOD, 0, afs_nfs3_resp, &dummy)
791 NFS_V3_REQ(afs_nfs3_remove, NFSPROC3_REMOVE, 0, afs_nfs3_resp, &dummy)
792 NFS_V3_REQ(afs_nfs3_rmdir, NFSPROC3_RMDIR, 0, afs_nfs3_resp, &dummy)
793 NFS_V3_REQ(afs_nfs3_rename, NFSPROC3_RENAME, 0, afs_nfs3_resp, &dummy)
794 NFS_V3_REQ(afs_nfs3_link, NFSPROC3_LINK, 0, afs_nfs3_resp, &dummy)
795 NFS_V3_REQ(afs_nfs3_readdir, NFSPROC3_READDIR, 0, afs_nfs3_resp, &dummy)
796 NFS_V3_REQ(afs_nfs3_readdirplus, NFSPROC3_READDIRPLUS, 0, afs_nfs3_resp, &dummy)
797 NFS_V3_REQ(afs_nfs3_fsstat, NFSPROC3_FSSTAT, 0, afs_nfs3_resp, &dummy)
798 NFS_V3_REQ(afs_nfs3_fsinfo, NFSPROC3_FSINFO, 0, afs_nfs3_resp, &dummy)
799 NFS_V3_REQ(afs_nfs3_pathconf, NFSPROC3_PATHCONF, 0, afs_nfs3_resp, &dummy)
800 NFS_V3_REQ(afs_nfs3_commit, NFSPROC3_COMMIT, 0, afs_nfs3_resp, &dummy)
802 struct afs_nfs_disp_tbl afs_rfs3_disp_tbl[RFS3_NPROC] = {
804 { afs_nfs3_getattr },
805 { afs_nfs3_setattr },
808 { afs_nfs3_readlink },
813 { afs_nfs3_symlink },
819 { afs_nfs3_readdir },
820 { afs_nfs3_readdirplus },
823 { afs_nfs3_pathconf },
827 #define ACL_V3_REQ(FUNCNAME, NFSOP) \
828 void FUNCNAME(char *args, char *xp, char *exp, char *rp, char *crp) { \
830 struct cred *svcred = curthread->t_cred; \
831 curthread->t_cred = (struct cred*)crp; \
832 call=afs_nfs3_dispatcher(1, NFSOP, (char *)args, &exp, rp, crp); \
833 if (call>1) afs_nfs3_noaccess((struct afs_nfs3_resp *)xp); \
834 else (*afs_rfs3_disp_tbl[NFSOP].orig_proc)(args, xp, exp, rp, crp); \
835 curthread->t_cred = svcred; \
839 ACL_V3_REQ(afs_acl3_getacl, ACLPROC3_GETACL)
840 ACL_V3_REQ(afs_acl3_setacl, ACLPROC3_SETACL)
842 struct afs_nfs_disp_tbl afs_acl3_disp_tbl[ACL3_NPROC] = {
848 /* Munge the dispatch tables to link us in first */
850 afs_xlatorinit_v3(struct rfs_disp_tbl *_rfs_tbl,
851 struct rfs_disp_tbl *_acl_tbl)
855 if (xlatorinit_v3_done++) return;
857 for (i=0; i < RFS3_NPROC; i++) {
858 afs_rfs3_disp_tbl[i].orig_proc = _rfs_tbl[i].dis_proc;
859 _rfs_tbl[i].dis_proc = afs_rfs3_disp_tbl[i].afs_proc;
862 for (i=0; i < ACL3_NPROC; i++) {
863 afs_acl3_disp_tbl[i].orig_proc = _acl_tbl[i].dis_proc;
864 _acl_tbl[i].dis_proc = afs_acl3_disp_tbl[i].afs_proc;
867 #endif /* !defined(AFS_NONFSTRANS) */