[PATCH] scsi: sd: Use info prints if no write cache

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Per Forlin <perfn@xxxxxxxx>

If the disk has no write cache the following errors are being logged.
* sd 1:0:0:0: [sdb] No Caching mode page found
* sd 1:0:0:0: [sdb] Assuming drive cache: write through

Lower the severity from error to info.
The absence of a write cache should not be treated as an error.
There are many portable drives that don't have a write cache.

Signed-off-by: Per Forlin <perfn@xxxxxxxx>
---
 drivers/scsi/sd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
index b79b366..6605001 100644
--- a/drivers/scsi/sd.c
+++ b/drivers/scsi/sd.c
@@ -2763,7 +2763,7 @@ sd_read_cache_type(struct scsi_disk *sdkp, unsigned char *buffer)
 			}
 		}
 
-		sd_first_printk(KERN_ERR, sdkp, "No Caching mode page found\n");
+		sd_first_printk(KERN_INFO, sdkp, "No Caching mode page found\n");
 		goto defaults;
 
 	Page_found:
@@ -2818,7 +2818,7 @@ sd_read_cache_type(struct scsi_disk *sdkp, unsigned char *buffer)
 				"Assuming drive cache: write back\n");
 		sdkp->WCE = 1;
 	} else {
-		sd_first_printk(KERN_ERR, sdkp,
+		sd_first_printk(KERN_INFO, sdkp,
 				"Assuming drive cache: write through\n");
 		sdkp->WCE = 0;
 	}
-- 
2.1.4




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux