linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mingming Cao <cmm@us.ibm.com>
To: Eric Sandeen <sandeen@redhat.com>
Cc: ext4 development <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH] fix up vfs inode version patch for modules
Date: Mon, 03 Dec 2007 10:00:34 -0800	[thread overview]
Message-ID: <1196704834.4022.2.camel@localhost.localdomain> (raw)
In-Reply-To: <474DD0A6.9010809@redhat.com>

On Wed, 2007-11-28 at 14:33 -0600, Eric Sandeen wrote:
> ext4 calls inode_inc_iversion(), but it's not exported, so modular ext4
> has trouble.  Any reason not to just make it an inline, as below?
> 

I agree.

Mingming
> Signed-off-by: Eric Sandeen <sandeen@redhat.com>
> 
> ---
> 
> Index: linux-2.6.24-rc1/fs/inode.c
> ===================================================================
> --- linux-2.6.24-rc1.orig/fs/inode.c
> +++ linux-2.6.24-rc1/fs/inode.c
> @@ -1243,23 +1243,6 @@ void touch_atime(struct vfsmount *mnt, s
>  EXPORT_SYMBOL(touch_atime);
> 
>  /**
> - *     inode_inc_iversion      -       increments i_version
> - *     @inode: inode that need to be updated
> - *
> - *     Every time the inode is modified, the i_version field
> - *     will be incremented.
> - *     The filesystem has to be mounted with i_version flag
> - *
> - */
> -
> -void inode_inc_iversion(struct inode *inode)
> -{
> -	spin_lock(&inode->i_lock);
> -	inode->i_version++;
> -	spin_unlock(&inode->i_lock);
> -}
> -
> -/**
>   *	file_update_time	-	update mtime and ctime time
>   *	@file: file accessed
>   *
> Index: linux-2.6.24-rc1/include/linux/fs.h
> ===================================================================
> --- linux-2.6.24-rc1.orig/include/linux/fs.h
> +++ linux-2.6.24-rc1/include/linux/fs.h
> @@ -1396,7 +1396,21 @@ static inline void inode_dec_link_count(
>  	mark_inode_dirty(inode);
>  }
> 
> -extern void inode_inc_iversion(struct inode *inode);
> +/**
> + * inode_inc_iversion - increments i_version
> + * @inode: inode that need to be updated
> + *
> + * Every time the inode is modified, the i_version field will be incremented.
> + * The filesystem has to be mounted with i_version flag
> + */
> +
> +static inline void inode_inc_iversion(struct inode *inode)
> +{
> +       spin_lock(&inode->i_lock);
> +       inode->i_version++;
> +       spin_unlock(&inode->i_lock);
> +}
> +
>  extern void touch_atime(struct vfsmount *mnt, struct dentry *dentry);
>  static inline void file_accessed(struct file *file)
>  {
> 
> -
> To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

      reply	other threads:[~2007-12-03 18:01 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-28 20:33 [PATCH] fix up vfs inode version patch for modules Eric Sandeen
2007-12-03 18:00 ` Mingming Cao [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1196704834.4022.2.camel@localhost.localdomain \
    --to=cmm@us.ibm.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=sandeen@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).