lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <49DEE70B.9030902@suse.de>
Date:	Fri, 10 Apr 2009 14:28:27 +0800
From:	Coly Li <coly.li@...e.de>
To:	Ryusuke Konishi <konishi.ryusuke@....ntt.co.jp>
Cc:	linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/8] nilfs2: return f_fsid for statfs2

Ack-by: Coly Li <coly.li@...e.de>

Ryusuke Konishi Wrote:
> This follows the change of Coly Li's series ("fs: return f_fsid for
> statfs(2)"), and make nilfs2 return f_fsid info for statfs(2).
> 
> Cc: Coly Li <coly.li@...e.de>
> Signed-off-by: Ryusuke Konishi <konishi.ryusuke@....ntt.co.jp>
> ---
>  fs/nilfs2/super.c |    6 +++++-
>  1 files changed, 5 insertions(+), 1 deletions(-)
> 
> diff --git a/fs/nilfs2/super.c b/fs/nilfs2/super.c
> index e117e1e..8a965f9 100644
> --- a/fs/nilfs2/super.c
> +++ b/fs/nilfs2/super.c
> @@ -476,11 +476,12 @@ static int nilfs_statfs(struct dentry *dentry, struct kstatfs *buf)
>  {
>  	struct super_block *sb = dentry->d_sb;
>  	struct nilfs_sb_info *sbi = NILFS_SB(sb);
> +	struct the_nilfs *nilfs = sbi->s_nilfs;
> +	u64 id = huge_encode_dev(sb->s_bdev->bd_dev);
>  	unsigned long long blocks;
>  	unsigned long overhead;
>  	unsigned long nrsvblocks;
>  	sector_t nfreeblocks;
> -	struct the_nilfs *nilfs = sbi->s_nilfs;
>  	int err;
>  
>  	/*
> @@ -514,6 +515,9 @@ static int nilfs_statfs(struct dentry *dentry, struct kstatfs *buf)
>  	buf->f_files = atomic_read(&sbi->s_inodes_count);
>  	buf->f_ffree = 0; /* nilfs_count_free_inodes(sb); */
>  	buf->f_namelen = NILFS_NAME_LEN;
> +	buf->f_fsid.val[0] = (u32)id;
> +	buf->f_fsid.val[1] = (u32)(id >> 32);
> +
>  	return 0;
>  }
>  

-- 
Coly Li
SuSE Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ