From: Yan Hong <clouds.yan@gmail.com>
To: gregkh@linuxfoundation.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH 3/3] debugfs: break long lines
Date: Sat, 27 Oct 2012 01:55:44 +0800 [thread overview]
Message-ID: <1351274144-31591-3-git-send-email-clouds.yan@gmail.com> (raw)
In-Reply-To: <1351274144-31591-1-git-send-email-clouds.yan@gmail.com>
Signed-off-by: Yan Hong <clouds.yan@gmail.com>
---
fs/debugfs/file.c | 42 ++++++++++++++++++++++++++++--------------
fs/debugfs/inode.c | 10 ++++++----
2 files changed, 34 insertions(+), 18 deletions(-)
diff --git a/fs/debugfs/file.c b/fs/debugfs/file.c
index 3915cc9..b37eee1 100644
--- a/fs/debugfs/file.c
+++ b/fs/debugfs/file.c
@@ -95,10 +95,12 @@ struct dentry *debugfs_create_u8(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u8_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u8_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u8_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u8_wo);
return debugfs_create_file(name, mode, parent, value, &fops_u8);
}
@@ -147,10 +149,12 @@ struct dentry *debugfs_create_u16(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u16_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u16_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u16_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u16_wo);
return debugfs_create_file(name, mode, parent, value, &fops_u16);
}
@@ -199,10 +203,12 @@ struct dentry *debugfs_create_u32(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u32_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u32_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u32_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u32_wo);
return debugfs_create_file(name, mode, parent, value, &fops_u32);
}
@@ -252,10 +258,12 @@ struct dentry *debugfs_create_u64(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u64_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u64_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_u64_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_u64_wo);
return debugfs_create_file(name, mode, parent, value, &fops_u64);
}
@@ -298,10 +306,12 @@ struct dentry *debugfs_create_x8(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x8_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x8_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x8_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x8_wo);
return debugfs_create_file(name, mode, parent, value, &fops_x8);
}
@@ -322,10 +332,12 @@ struct dentry *debugfs_create_x16(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x16_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x16_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x16_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x16_wo);
return debugfs_create_file(name, mode, parent, value, &fops_x16);
}
@@ -346,10 +358,12 @@ struct dentry *debugfs_create_x32(const char *name, umode_t mode,
{
/* if there are no write bits set, make read only */
if (!(mode & S_IWUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x32_ro);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x32_ro);
/* if there are no read bits set, make write only */
if (!(mode & S_IRUGO))
- return debugfs_create_file(name, mode, parent, value, &fops_x32_wo);
+ return debugfs_create_file(name, mode, parent, value,
+ &fops_x32_wo);
return debugfs_create_file(name, mode, parent, value, &fops_x32);
}
diff --git a/fs/debugfs/inode.c b/fs/debugfs/inode.c
index 58eadc1..edbaf37 100644
--- a/fs/debugfs/inode.c
+++ b/fs/debugfs/inode.c
@@ -34,8 +34,9 @@ static struct vfsmount *debugfs_mount;
static int debugfs_mount_count;
static bool debugfs_registered;
-static struct inode *debugfs_get_inode(struct super_block *sb, umode_t mode, dev_t dev,
- void *data, const struct file_operations *fops)
+static struct inode *debugfs_get_inode(struct super_block *sb, umode_t mode,
+ dev_t dev, void *data,
+ const struct file_operations *fops)
{
struct inode *inode = new_inode(sb);
@@ -110,8 +111,9 @@ static int debugfs_link(struct inode *dir, struct dentry *dentry, umode_t mode,
return debugfs_mknod(dir, dentry, mode, 0, data, NULL);
}
-static int debugfs_create(struct inode *dir, struct dentry *dentry, umode_t mode,
- void *data, const struct file_operations *fops)
+static int debugfs_create(struct inode *dir, struct dentry *dentry,
+ umode_t mode, void *data,
+ const struct file_operations *fops)
{
int res;
--
1.7.9.5
next prev parent reply other threads:[~2012-10-26 17:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-26 17:55 [PATCH 1/3] debugfs: pass NULL as the last parameter of debugfs_print_regs32() Yan Hong
2012-10-26 17:55 ` [PATCH 2/3] debugfs: code clean and refactor Yan Hong
2012-10-26 18:12 ` Greg KH
2012-10-26 17:55 ` Yan Hong [this message]
2012-10-26 18:12 ` [PATCH 3/3] debugfs: break long lines Greg KH
2012-10-26 18:13 ` [PATCH 1/3] debugfs: pass NULL as the last parameter of debugfs_print_regs32() Greg KH
2012-10-26 18:34 ` yan yan
2012-10-26 18:48 ` Greg KH
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=1351274144-31591-3-git-send-email-clouds.yan@gmail.com \
--to=clouds.yan@gmail.com \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
/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
Powered by JetHome