printk unexpected LF is inserted in message

Solution Verified - Updated -

Issue

  • printk unexpected LF is inserted in message. The results of printk() are different between RHEL6 and RHEL7 as follows.
< RHEL7 >
# uname -r
3.10.0-123.el7.x86_64
# dmesg
...skip...
[  164.938026] sd 2:0:0:0: [sdb]  
[  164.938027] Add. Sense: Unrecovered read error
[  164.938028] sd 2:0:0:0: [sdb] CDB: 
[  164.938030] Read(10): 28 00 00 00 12 30 00 00 08 00
[  165.021177] sd 2:0:0:0: [sdb] Unhandled sense code
[  165.021180] sd 2:0:0:0: [sdb]  
[  165.021181] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[  165.021182] sd 2:0:0:0: [sdb]  
[  165.021185] Sense Key : Medium Error [current] 
[  165.021187] Info fld=0x1234
...skip...

< RHEL6 >
# uname -r
2.6.32-431.el6.x86_64
# dmesg
...skip...
[  911.566475] sd 2:0:0:0: [sdb] Add. Sense: Unrecovered read error
[  911.567484] sd 2:0:0:0: [sdb] CDB: Read(10): 28 00 00 00 11 e0 00 01 00 00
[  911.570034] sd 2:0:0:0: [sdb] Unhandled sense code
[  911.570756] sd 2:0:0:0: [sdb] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[  911.571658] sd 2:0:0:0: [sdb] Sense Key : Medium Error [current] 
[  911.572616] Info fld=0x1234
...skip...

Environment

  • Red Hat Enterprise Linux 7

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.