All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sandeen <sandeen@sandeen.net>
To: Bill O'Donnell <billodo@redhat.com>, xfs@oss.sgi.com
Subject: Re: [PATCH 2/3] xfs: create symlink proc/fs/xfs/stat to sys/fs/xfs/stats
Date: Fri, 4 Sep 2015 13:32:52 -0500	[thread overview]
Message-ID: <55E9E3D4.5090509@sandeen.net> (raw)
In-Reply-To: <1441371319-31625-3-git-send-email-billodo@redhat.com>

On 9/4/15 7:55 AM, Bill O'Donnell wrote:
> As a part of the work to move xfs global stats from procfs to sysfs,
> this patch creates the symlink from proc/fs/xfs/stat to sys/fs/xfs/stats.
> 
> Signed-off-by: Bill O'Donnell <billodo@redhat.com>
> ---
>  fs/xfs/xfs_stats.c | 7 +++++--
>  1 file changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/fs/xfs/xfs_stats.c b/fs/xfs/xfs_stats.c
> index 6008e25..734b867 100644
> --- a/fs/xfs/xfs_stats.c
> +++ b/fs/xfs/xfs_stats.c
> @@ -244,9 +244,12 @@ xfs_init_procfs(void)
>  	if (!proc_mkdir("fs/xfs", NULL))
>  		goto out;
>  
> -	if (!proc_create("fs/xfs/stat", 0, NULL,
> -			 &xfs_stat_proc_fops))
> +	if (!proc_symlink("fs/xfs/stat", NULL,
> +			  "/sys/fs/xfs/stats/stats"))
> +	{
>  		goto out_remove_xfs_dir;
> +	}

Ok, without the printk, now there's no need for the braces :)

Also, as an aside, the kernel/xfs style is:

	if (foo) {
		...
	}

not:

	if (foo)
	{
		...
	}

just FYI...

Thanks,
-Eric
> +
>  #ifdef CONFIG_XFS_QUOTA
>  	if (!proc_create("fs/xfs/xqmstat", 0, NULL,
>  			 &xqmstat_proc_fops))
> 

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

  reply	other threads:[~2015-09-04 18:32 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-04 12:55 [PATCH 0/3 V2] xfs: new global stats in sysfs Bill O'Donnell
2015-09-04 12:55 ` [PATCH 1/3] xfs: create global stats and stats_clear " Bill O'Donnell
2015-09-04 20:13   ` Eric Sandeen
2015-09-04 20:15     ` Bill O'Donnell
2015-09-04 12:55 ` [PATCH 2/3] xfs: create symlink proc/fs/xfs/stat to sys/fs/xfs/stats Bill O'Donnell
2015-09-04 18:32   ` Eric Sandeen [this message]
2015-09-04 12:55 ` [PATCH 3/3] xfs: remove unused procfs code Bill O'Donnell
  -- strict thread matches above, loose matches on Subject: below --
2015-09-04 20:54 [PATCH 0/3 V3] xfs: new global stats in sysfs Bill O'Donnell
2015-09-04 20:54 ` [PATCH 2/3] xfs: create symlink proc/fs/xfs/stat to sys/fs/xfs/stats Bill O'Donnell
2015-09-04 20:42 Bill O'Donnell
2015-09-03 16:36 [PATCH 0/3] xfs: new global stats in sysfs billodo
2015-09-03 16:36 ` [PATCH 2/3] xfs: create symlink proc/fs/xfs/stat to sys/fs/xfs/stats billodo
2015-09-03 17:57   ` Darrick J. Wong
2015-09-03 18:32     ` Eric Sandeen
2015-09-03 18:39       ` Bill O'Donnell
2015-09-03 19:15         ` Bill O'Donnell
2015-09-03 19:17           ` Darrick J. Wong
2015-09-03 20:08   ` Eric Sandeen

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=55E9E3D4.5090509@sandeen.net \
    --to=sandeen@sandeen.net \
    --cc=billodo@redhat.com \
    --cc=xfs@oss.sgi.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.