All of lore.kernel.org
 help / color / mirror / Atom feed
From: Aviral Gupta <shiv14112001@gmail.com>
To: viro@zeniv.linux.org.uk, shuah@kernal.org
Cc: Aviral Gupta <shiv14112001@gmail.com>,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-kernel-mentees@lists.linuxfoundation.org
Subject: [PATCH] This commit fixes the error generated due to the wrong indentation which does not follow the codding  style norms set by Linux-kernel  and space- bar is used in place of tab to give space which causes a visual error for  some compilers
Date: Fri, 21 May 2021 16:26:54 +0530	[thread overview]
Message-ID: <20210521105654.4046-1-shiv14112001@gmail.com> (raw)

ERROR: switch and case should be at the same indent
+	switch (whence) {
+		case 1:
[...]
+		case 0:
[...]
+		default:
ERROR: code indent should use tabs where possible
+                              void (*callback)(struct dentry *))$

Signed-off-by: Aviral Gupta <shiv14112001@gmail.com>
---
 fs/libfs.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/fs/libfs.c b/fs/libfs.c
index e9b29c6ffccb..a7a9deec546c 100644
--- a/fs/libfs.c
+++ b/fs/libfs.c
@@ -138,15 +138,15 @@ loff_t dcache_dir_lseek(struct file *file, loff_t offset, int whence)
 {
 	struct dentry *dentry = file->f_path.dentry;
 	switch (whence) {
-		case 1:
-			offset += file->f_pos;
-			fallthrough;
-		case 0:
-			if (offset >= 0)
-				break;
-			fallthrough;
-		default:
-			return -EINVAL;
+	case 1:
+		offset += file->f_pos;
+		fallthrough;
+	case 0:
+		if (offset >= 0)
+			break;
+		fallthrough;
+	default:
+		return -EINVAL;
 	}
 	if (offset != file->f_pos) {
 		struct dentry *cursor = file->private_data;
@@ -266,7 +266,7 @@ static struct dentry *find_next_child(struct dentry *parent, struct dentry *prev
 }
 
 void simple_recursive_removal(struct dentry *dentry,
-                              void (*callback)(struct dentry *))
+				void (*callback)(struct dentry *))
 {
 	struct dentry *this = dget(dentry);
 	while (true) {
-- 
2.25.1


WARNING: multiple messages have this Message-ID (diff)
From: Aviral Gupta <shiv14112001@gmail.com>
To: viro@zeniv.linux.org.uk, shuah@kernal.org
Cc: linux-fsdevel@vger.kernel.org,
	linux-kernel-mentees@lists.linuxfoundation.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH] This commit fixes the error generated due to the wrong indentation which does not follow the codding style norms set by Linux-kernel and space- bar is used in place of tab to give space which causes a visual error for some compilers
Date: Fri, 21 May 2021 16:26:54 +0530	[thread overview]
Message-ID: <20210521105654.4046-1-shiv14112001@gmail.com> (raw)

ERROR: switch and case should be at the same indent
+	switch (whence) {
+		case 1:
[...]
+		case 0:
[...]
+		default:
ERROR: code indent should use tabs where possible
+                              void (*callback)(struct dentry *))$

Signed-off-by: Aviral Gupta <shiv14112001@gmail.com>
---
 fs/libfs.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/fs/libfs.c b/fs/libfs.c
index e9b29c6ffccb..a7a9deec546c 100644
--- a/fs/libfs.c
+++ b/fs/libfs.c
@@ -138,15 +138,15 @@ loff_t dcache_dir_lseek(struct file *file, loff_t offset, int whence)
 {
 	struct dentry *dentry = file->f_path.dentry;
 	switch (whence) {
-		case 1:
-			offset += file->f_pos;
-			fallthrough;
-		case 0:
-			if (offset >= 0)
-				break;
-			fallthrough;
-		default:
-			return -EINVAL;
+	case 1:
+		offset += file->f_pos;
+		fallthrough;
+	case 0:
+		if (offset >= 0)
+			break;
+		fallthrough;
+	default:
+		return -EINVAL;
 	}
 	if (offset != file->f_pos) {
 		struct dentry *cursor = file->private_data;
@@ -266,7 +266,7 @@ static struct dentry *find_next_child(struct dentry *parent, struct dentry *prev
 }
 
 void simple_recursive_removal(struct dentry *dentry,
-                              void (*callback)(struct dentry *))
+				void (*callback)(struct dentry *))
 {
 	struct dentry *this = dget(dentry);
 	while (true) {
-- 
2.25.1

_______________________________________________
Linux-kernel-mentees mailing list
Linux-kernel-mentees@lists.linuxfoundation.org
https://lists.linuxfoundation.org/mailman/listinfo/linux-kernel-mentees

             reply	other threads:[~2021-05-21 10:56 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-21 10:56 Aviral Gupta [this message]
2021-05-21 10:56 ` [PATCH] This commit fixes the error generated due to the wrong indentation which does not follow the codding style norms set by Linux-kernel and space- bar is used in place of tab to give space which causes a visual error for some compilers Aviral Gupta
2021-05-21 11:07 ` Greg KH
2021-05-21 11:07   ` Greg KH
2021-05-21 11:41 ` Pavel Skripkin
2021-05-21 11:41   ` Pavel Skripkin

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=20210521105654.4046-1-shiv14112001@gmail.com \
    --to=shiv14112001@gmail.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel-mentees@lists.linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=shuah@kernal.org \
    --cc=viro@zeniv.linux.org.uk \
    /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.