From dbebe02c53b039f384a2858edf009ed70b0fbde0 Mon Sep 17 00:00:00 2001 From: wangdi Date: Thu, 11 Dec 2003 08:30:50 +0000 Subject: [PATCH] b:2316 Save the owner of f_op before replace it with llite special file operation --- lustre/llite/special.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lustre/llite/special.c b/lustre/llite/special.c index aeb281b..35d6082 100644 --- a/lustre/llite/special.c +++ b/lustre/llite/special.c @@ -63,14 +63,16 @@ static inline void save_fops(struct file *filp, struct inode *inode, if (sfops != filp->f_op) { struct file_operations** pfop = get_save_fops (filp, FILE_OPS); - + struct module *save_module = NULL; + + save_module = filp->f_op->owner; *pfop = filp->f_op; if (S_ISCHR(inode->i_mode)) { filp->f_op = &ll_special_chr_file_fops; }else if (S_ISFIFO(inode->i_mode)){ filp->f_op = &ll_special_fifo_file_fops; } - filp->f_op->owner = lli->ll_save_ffop->owner; + filp->f_op->owner = save_module; } } -- 1.8.3.1