Skip to contentSkip to conversation

common: Increase LOGLEVEL back to 6

PATCH New Stefan Roese 3 participants 7 messages Aug 6, 2018 – Aug 7, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Commit 6a3e65dea3e5 ("common: Drop LOGLEVEL to 4") reduced the loglevel resulting in pr_warn() messages fro e.g. UBI are not shown anymore. With this change back to 6, messages like this appear again:

nand: attempt to erase a bad/reserved block @6000000

---
 common/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/Kconfig +1 -1
index 4d7215a360..678a108508 100644
@@ -266,7 +266,7 @@ config IDENT_STRING
 
 config LOGLEVEL
 	int "loglevel"
-	default 4
+	default 6
 	range 0 8
 	help
 	  All Messages with a loglevel smaller than the console loglevel will
Signature · 1 line
2.18.0
#1 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Quoted 17 lines · Stefan Roese

Commit 6a3e65dea3e5 ("common: Drop LOGLEVEL to 4") reduced the loglevel resulting in pr_warn() messages fro e.g. UBI are not shown anymore. With this change back to 6, messages like this appear again:

nand: attempt to erase a bad/reserved block @6000000

---
 common/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/Kconfig +0 -0
index 4d7215a360..678a108508 100644

common/Kconfig config IDENT_STRING · line 272

Quoted 8 lines
common/Kconfig +1 -1
@@ -266,7 +266,7 @@ config IDENT_STRING
 
 config LOGLEVEL
 	int "loglevel"
-	default 4
+	default 6
 	range 0 8
 	help
 	  All Messages with a loglevel smaller than the console loglevel will

This is a huge size increase on boards that rely on the default. And I bet this causes some boards to no longer link. That said, if boards want more logging messages, such as warnings, they can increase it on their own. If you feel that whole SoCs would benefit from this, I have no objection to default 6 if ... being added. And if the example message you gave is more than just a warning and should be seen more often, perhaps it should be a higher level message? Thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180806/5758aec7/attachment.sig>
#2 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Quoted 20 lines · Tom Rini
Quoted 18 lines · Stefan Roese

Commit 6a3e65dea3e5 ("common: Drop LOGLEVEL to 4") reduced the loglevel resulting in pr_warn() messages fro e.g. UBI are not shown anymore. With this change back to 6, messages like this appear again:

nand: attempt to erase a bad/reserved block @6000000

---
  common/Kconfig | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
common/Kconfig +0 -0
index 4d7215a360..678a108508 100644
@@ -266,7 +266,7 @@ config IDENT_STRING
 
Quoted 15 lines

common/Kconfig config IDENT_STRING · line 272

Quoted 7 lines
common/Kconfig +1 -1
  config LOGLEVEL
  	int "loglevel"
-	default 4
+	default 6
  	range 0 8
  	help
  	  All Messages with a loglevel smaller than the console loglevel will

This is a huge size increase on boards that rely on the default. And I bet this causes some boards to no longer link. That said, if boards want more logging messages, such as warnings, they can increase it on their own. If you feel that whole SoCs would benefit from this, I have no objection to default 6 if ... being added. And if the example message you gave is more than just a warning and should be seen more often, perhaps it should be a higher level message? Thanks!

Its a "warn" and this should be visible to the user IMHO. One might discuss, if an "info" or "notice" text should printed, but warnings seem quite important (at least for my taste). Changing this to even higher level messages (like "err") is too much. And this would lead to differences between Linux and U-Boot which we should avoid.

Back to the issue, if you don't want to pull this change for the default LOGLEVEL, I will change it for this board or platform as you suggested above. Just let me know.

Thanks,
Stefan

#3 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Quoted 42 lines · Stefan Roese
Quoted 27 lines · Tom Rini
Quoted 17 lines · Stefan Roese

Commit 6a3e65dea3e5 ("common: Drop LOGLEVEL to 4") reduced the loglevel resulting in pr_warn() messages fro e.g. UBI are not shown anymore. With this change back to 6, messages like this appear again:

nand: attempt to erase a bad/reserved block @6000000

---
 common/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
common/Kconfig +0 -0
index 4d7215a360..678a108508 100644

common/Kconfig config IDENT_STRING · line 271

Quoted 7 lines
common/Kconfig +1 -1
@@ -266,7 +266,7 @@ config IDENT_STRING
 config LOGLEVEL
 	int "loglevel"
-	default 4
+	default 6
 	range 0 8
 	help
 	  All Messages with a loglevel smaller than the console loglevel will
Quoted 7 lines

This is a huge size increase on boards that rely on the default. And I bet this causes some boards to no longer link. That said, if boards want more logging messages, such as warnings, they can increase it on their own. If you feel that whole SoCs would benefit from this, I have no objection to default 6 if ... being added. And if the example message you gave is more than just a warning and should be seen more often, perhaps it should be a higher level message? Thanks!

Its a "warn" and this should be visible to the user IMHO. One might discuss, if an "info" or "notice" text should printed, but warnings seem quite important (at least for my taste). Changing this to even higher level messages (like "err") is too much. And this would lead to differences between Linux and U-Boot which we should avoid.

Quoted 3 lines

Back to the issue, if you don't want to pull this change for the default LOGLEVEL, I will change it for this board or platform as you suggested above. Just let me know.

Please bump it per board/SoC, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180807/0bb891ab/attachment.sig>
#4 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Dear Tom,

Quoted 4 lines · In message <20180807111435.GD29229@bill-the-cat> you wrote:
Quoted 4 lines

Its a "warn" and this should be visible to the user IMHO. One might discuss, if an "info" or "notice" text should printed, but warnings seem quite important (at least for my taste). Changing this to even

...

Quoted 1 line

Please bump it per board/SoC, thanks!

So we stop printing warnings now, just to satisfy code size limitations on a few boards?

This is a totally wrong approach! If code size is a problem, these boards should disable unneeded or at least non-essential features, but you don;t want to ignore warnings, especially if these cause a command to not perform the expected operation.

Please reconsider!

Best regards,

Wolfgang Denk

Signature · 5 lines
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
A positive attitude may not solve all  your  problems,  but  it  will
annoy enough people to make it worth the effort.      - Herm Albright
#5 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Quoted 10 lines · Wolfgang Denk

Dear Tom,

Quoted 4 lines · In message <20180807111435.GD29229@bill-the-cat> you wrote:
Quoted 4 lines

Its a "warn" and this should be visible to the user IMHO. One might discuss, if an "info" or "notice" text should printed, but warnings seem quite important (at least for my taste). Changing this to even

...

Quoted 1 line

Please bump it per board/SoC, thanks!

Quoted 7 lines

So we stop printing warnings now, just to satisfy code size limitations on a few boards?

This is a totally wrong approach! If code size is a problem, these boards should disable unneeded or at least non-essential features, but you don;t want to ignore warnings, especially if these cause a command to not perform the expected operation.

Yes, by default "warnings", which means pr_warn, along with pr_notice and pr_info get optimized away. In no case should a warning be printed in a case where we aren't otherwise recovering and working correctly. I think there's a strong case here that the root problem here is that the prints in question ought to be pr_err and that should be corrected in the kernel too.

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180807/d413dc89/attachment.sig>
#6 lore raw

PATCH 1/1 common: Increase LOGLEVEL back to 6

Quoted 19 lines · Tom Rini
Quoted 10 lines · Wolfgang Denk

Dear Tom,

Quoted 4 lines · In message <20180807111435.GD29229@bill-the-cat> you wrote:
Quoted 4 lines

Its a "warn" and this should be visible to the user IMHO. One might discuss, if an "info" or "notice" text should printed, but warnings seem quite important (at least for my taste). Changing this to even

...

Quoted 1 line

Please bump it per board/SoC, thanks!

Quoted 7 lines

So we stop printing warnings now, just to satisfy code size limitations on a few boards?

This is a totally wrong approach! If code size is a problem, these boards should disable unneeded or at least non-essential features, but you don;t want to ignore warnings, especially if these cause a command to not perform the expected operation.

Quoted 6 lines

Yes, by default "warnings", which means pr_warn, along with pr_notice and pr_info get optimized away. In no case should a warning be printed in a case where we aren't otherwise recovering and working correctly. I think there's a strong case here that the root problem here is that the prints in question ought to be pr_err and that should be corrected in the kernel too.

That said, I am not strictly against increasing the default, slightly, to 5 (which means 4 and lower included). The troublesome boards already set things to 3 in their configs and we can make SPL_LOGLEVEL be untied from LOGLEVEL. But I want someone to show me the before/after size deltas on that too.

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20180807/e6f063ab/attachment.sig>