Skip to contentSkip to conversation

Revert "f2fs: use printk_ratelimited for f2fs_msg"

PATCH Superseded Chao Yu 3 participants 9 messages Aug 13, 2018 – Aug 15, 2018 F2FS file system

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Chao Yu

author
#0 lore raw

PATCH 1/1 Revert "f2fs: use printk_ratelimited for f2fs_msg"

Don't limit printing log, so that we will not miss any key messages.

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 6 lines
2.18.0.rc1


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
#1 lore raw
Quoted 3 lines · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

[]

fs/f2fs/super.c

Quoted 1 line
fs/f2fs/super.c +0 -0

[]

fs/f2fs/super.c void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...) · line 214

Quoted 8 lines
fs/f2fs/super.c +1 -1
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }

If there was value in ratelimiting these messages at all, perhaps there is value in using a specific ratelimit_state other than

	static DEFINE_RATELIMIT_STATE(_rs,				\
				      DEFAULT_RATELIMIT_INTERVAL,	\
				      DEFAULT_RATELIMIT_BURST);		\
author
#2 lore raw

Hi Joe, thanks for pointing out this, I didn't see any cases need to be limited now.

Thanks,

Quoted 29 lines · Joe Perches
Quoted 3 lines · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

[]

fs/f2fs/super.c

Quoted 1 line
fs/f2fs/super.c +0 -0

[]

fs/f2fs/super.c void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...) · line 214

Quoted 8 lines
fs/f2fs/super.c +1 -1
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }

If there was value in ratelimiting these messages at all, perhaps there is value in using a specific ratelimit_state other than

	static DEFINE_RATELIMIT_STATE(_rs,				\
				      DEFAULT_RATELIMIT_INTERVAL,	\
				      DEFAULT_RATELIMIT_BURST);		\

.

maintainer
#3 lore raw
In reply to Chao Yu
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

For example, this can avoid lots of messages during roll-forward recovery.

Quoted 23 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1
author
#4 lore raw
Quoted 4 lines · Jaegeuk Kim
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

For example, this can avoid lots of messages during roll-forward recovery.

That's really important evidence that can prove filesystem didn't lose last fsynced data, when file/data is missing after SPO, otherwise, filesystem will still be treated as suspect... :(

Thanks,

Quoted 27 lines
Quoted 24 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1

.

maintainer
#5 lore raw
Quoted 9 lines · Chao Yu
Quoted 4 lines · Jaegeuk Kim
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

For example, this can avoid lots of messages during roll-forward recovery.

That's really important evidence that can prove filesystem didn't lose last fsynced data, when file/data is missing after SPO, otherwise, filesystem will still be treated as suspect... :(

It's too bad that we need to rely on kernel messages for that purpose. Anyway, if so, we may need to use printk() for essential messages only.

Quoted 30 lines

Thanks,

Quoted 27 lines
Quoted 24 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1

.

author
#6 lore raw
Quoted 5 lines · Jaegeuk Kim
Quoted 4 lines · Chao Yu
Quoted 3 lines · Jaegeuk Kim
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

Quoted 7 lines
Quoted 5 lines
Quoted 1 line

For example, this can avoid lots of messages during roll-forward recovery.

That's really important evidence that can prove filesystem didn't lose last fsynced data, when file/data is missing after SPO, otherwise, filesystem will still be treated as suspect... :(

It's too bad that we need to rely on kernel messages for that purpose. Anyway,

Yes, it's very hard to make sure the problem is not caused by filesystem's bug when trouble shooting, unless there is explicit kernel message.

Also, without message, trouble shooting becomes harder.

Quoted 1 line

if so, we may need to use printk() for essential messages only.

Now, during our debugging, we have to change to use printk to avoid potential message missing...

Thanks,

Quoted 34 lines
Quoted 31 lines

Thanks,

Quoted 27 lines
Quoted 24 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1

.

.

maintainer
#7 lore raw
Quoted 17 lines · Chao Yu
Quoted 5 lines · Jaegeuk Kim
Quoted 4 lines · Chao Yu
Quoted 3 lines · Jaegeuk Kim
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

Quoted 7 lines
Quoted 5 lines
Quoted 1 line

For example, this can avoid lots of messages during roll-forward recovery.

That's really important evidence that can prove filesystem didn't lose last fsynced data, when file/data is missing after SPO, otherwise, filesystem will still be treated as suspect... :(

It's too bad that we need to rely on kernel messages for that purpose. Anyway,

Yes, it's very hard to make sure the problem is not caused by filesystem's bug when trouble shooting, unless there is explicit kernel message.

Quoted 6 lines

Also, without message, trouble shooting becomes harder.

Quoted 1 line

if so, we may need to use printk() for essential messages only.

Now, during our debugging, we have to change to use printk to avoid potential message missing...

Let me understand what messages are really important for your debugging purpose. I believe it'd not require all of them.

Quoted 37 lines

Thanks,

Quoted 34 lines
Quoted 31 lines

Thanks,

Quoted 27 lines
Quoted 24 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1

.

.

author
#8 lore raw
Quoted 18 lines · Jaegeuk Kim
Quoted 17 lines · Chao Yu
Quoted 5 lines · Jaegeuk Kim
Quoted 4 lines · Chao Yu
Quoted 3 lines · Jaegeuk Kim
Quoted 1 line · Chao Yu

Don't limit printing log, so that we will not miss any key messages.

Quoted 7 lines
Quoted 5 lines
Quoted 1 line

For example, this can avoid lots of messages during roll-forward recovery.

That's really important evidence that can prove filesystem didn't lose last fsynced data, when file/data is missing after SPO, otherwise, filesystem will still be treated as suspect... :(

It's too bad that we need to rely on kernel messages for that purpose. Anyway,

Yes, it's very hard to make sure the problem is not caused by filesystem's bug when trouble shooting, unless there is explicit kernel message.

Quoted 8 lines
Quoted 6 lines

Also, without message, trouble shooting becomes harder.

Quoted 1 line

if so, we may need to use printk() for essential messages only.

Now, during our debugging, we have to change to use printk to avoid potential message missing...

Let me understand what messages are really important for your debugging purpose.

The most important message is about filesystem/data consistence.

Quoted 1 line

I believe it'd not require all of them.

Yeah, IMO, error injection prints too many messages.

Thanks,

Quoted 41 lines
Quoted 38 lines

Thanks,

Quoted 34 lines
Quoted 31 lines

Thanks,

Quoted 27 lines
Quoted 24 lines

This reverts commit a36c106dffb616250117efb1cab271c19a8f94ff.

---
 fs/f2fs/super.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/super.c +1 -1
index bf4c919fe418..3d89d94191e7 100644
@@ -209,7 +209,7 @@ void f2fs_msg(struct super_block *sb, const char *level, const char *fmt, ...)
 	va_start(args, fmt);
 	vaf.fmt = fmt;
 	vaf.va = &args;
-	printk_ratelimited("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
+	printk("%sF2FS-fs (%s): %pV\n", level, sb->s_id, &vaf);
 	va_end(args);
 }
 
Signature · 1 line
2.18.0.rc1

.

.

.