From 54a2300f9ce51b694c975d4bf2d452e9c9f914f7 Mon Sep 17 00:00:00 2001 From: phil Date: Mon, 8 Sep 2003 05:10:41 +0000 Subject: [PATCH] - remove obd_run_ctxt from obd->u.mds and obd->u.filter; put it in the obd_device - add lvfs_callback_ops, and the first one, the l_fid2dentry - add callback ops to obd_run_ctxt - change the 100 uses of mds->mds_ctxt and filter->fo_ctxt - add a handful of llog tests --- lustre/include/linux/lvfs.h | 8 ++++++++ lustre/lvfs/Makefile.am | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lustre/include/linux/lvfs.h b/lustre/include/linux/lvfs.h index 722f600..06d76aa 100644 --- a/lustre/include/linux/lvfs.h +++ b/lustre/include/linux/lvfs.h @@ -18,6 +18,10 @@ struct obd_ucred { __u32 ouc_suppgid2; }; +struct lvfs_callback_ops { + struct dentry *(*l_fid2dentry)(__u64 id_ino, __u32 gr_gen, void *data); +}; + #define OBD_RUN_CTXT_MAGIC 0xC0FFEEAA #define OBD_CTXT_DEBUG /* development-only debugging */ struct obd_run_ctxt { @@ -26,6 +30,7 @@ struct obd_run_ctxt { mm_segment_t fs; struct obd_ucred ouc; int ngroups; + struct lvfs_callback_ops cb_ops; #ifdef OBD_CTXT_DEBUG __u32 magic; #endif @@ -50,6 +55,9 @@ int lustre_fread(struct file *file, void *buf, int len, loff_t *off); int lustre_fwrite(struct file *file, const void *buf, int len, loff_t *off); int lustre_fsync(struct file *file); +/* lvfs_common.c */ +struct dentry *lvfs_fid2dentry(struct obd_run_ctxt *, __u64, __u32, void *data); + static inline void l_dput(struct dentry *de) { if (!de || IS_ERR(de)) diff --git a/lustre/lvfs/Makefile.am b/lustre/lvfs/Makefile.am index 4c807b5..5842f63 100644 --- a/lustre/lvfs/Makefile.am +++ b/lustre/lvfs/Makefile.am @@ -25,7 +25,7 @@ else modulefs_DATA = lvfs.o $(FSMOD).o fsfilt_reiserfs.o EXTRA_PROGRAMS = lvfs $(FSMOD) fsfilt_reiserfs -lvfs_SOURCES = lvfs_linux.c fsfilt.c +lvfs_SOURCES = lvfs_common.c lvfs_linux.c fsfilt.c endif -- 1.8.3.1