linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] scsi: Shorten too long warning messages
@ 2022-06-30  2:38 lizhijian
  2022-06-30 16:05 ` Bart Van Assche
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: lizhijian @ 2022-06-30  2:38 UTC (permalink / raw)
  To: James E.J. Bottomley, Martin K. Petersen, linux-scsi
  Cc: linux-kernel, lizhijian, Finn Thain

sdev_printk will only accept messages less than 128 bytes. So shorten
the messages exceeding 128 bytes avoid getting a incomplete sentence like:
[  475.156955] sd 9:0:0:0: Warning! Received an indication that the LUN assignments on this target have changed. The Linux SCSI layer does not automatical

Suggested-by: Finn Thain <fthain@linux-m68k.org>
Signed-off-by: Li Zhijian <lizhijian@fujitsu.com>
---
V2: update patch as suggested by Finn and upadte the subject correspondingly
---
 drivers/scsi/scsi_error.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/drivers/scsi/scsi_error.c b/drivers/scsi/scsi_error.c
index 49ef864df581..947d98a0565f 100644
--- a/drivers/scsi/scsi_error.c
+++ b/drivers/scsi/scsi_error.c
@@ -463,14 +463,12 @@ static void scsi_report_sense(struct scsi_device *sdev,
 			evt_type = SDEV_EVT_LUN_CHANGE_REPORTED;
 			scsi_report_lun_change(sdev);
 			sdev_printk(KERN_WARNING, sdev,
-				    "Warning! Received an indication that the "
 				    "LUN assignments on this target have "
 				    "changed. The Linux SCSI layer does not "
 				    "automatically remap LUN assignments.\n");
 		} else if (sshdr->asc == 0x3f)
 			sdev_printk(KERN_WARNING, sdev,
-				    "Warning! Received an indication that the "
-				    "operating parameters on this target have "
+				    "Operating parameters on this target have "
 				    "changed. The Linux SCSI layer does not "
 				    "automatically adjust these parameters.\n");
 
-- 
2.31.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] scsi: Shorten too long warning messages
  2022-06-30  2:38 [PATCH] scsi: Shorten too long warning messages lizhijian
@ 2022-06-30 16:05 ` Bart Van Assche
  2022-07-07 20:57 ` Martin K. Petersen
  2022-07-14  4:22 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Bart Van Assche @ 2022-06-30 16:05 UTC (permalink / raw)
  To: lizhijian, James E.J. Bottomley, Martin K. Petersen, linux-scsi
  Cc: linux-kernel, Finn Thain

On 6/29/22 19:38, lizhijian@fujitsu.com wrote:
> sdev_printk will only accept messages less than 128 bytes. So shorten
> the messages exceeding 128 bytes avoid getting a incomplete sentence like:
> [  475.156955] sd 9:0:0:0: Warning! Received an indication that the LUN assignments on this target have changed. The Linux SCSI layer does not automatical

Reviewed-by: Bart Van Assche <bvanassche@acm.org>

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] scsi: Shorten too long warning messages
  2022-06-30  2:38 [PATCH] scsi: Shorten too long warning messages lizhijian
  2022-06-30 16:05 ` Bart Van Assche
@ 2022-07-07 20:57 ` Martin K. Petersen
  2022-07-14  4:22 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Martin K. Petersen @ 2022-07-07 20:57 UTC (permalink / raw)
  To: lizhijian
  Cc: James E.J. Bottomley, Martin K. Petersen, linux-scsi,
	linux-kernel, Finn Thain


> sdev_printk will only accept messages less than 128 bytes. So shorten
> the messages exceeding 128 bytes avoid getting a incomplete sentence like:
> [ 475.156955] sd 9:0:0:0: Warning! Received an indication that the LUN
> assignments on this target have changed. The Linux SCSI layer does not
> automatical

Applied to 5.20/scsi-staging, thanks!

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] scsi: Shorten too long warning messages
  2022-06-30  2:38 [PATCH] scsi: Shorten too long warning messages lizhijian
  2022-06-30 16:05 ` Bart Van Assche
  2022-07-07 20:57 ` Martin K. Petersen
@ 2022-07-14  4:22 ` Martin K. Petersen
  2 siblings, 0 replies; 4+ messages in thread
From: Martin K. Petersen @ 2022-07-14  4:22 UTC (permalink / raw)
  To: linux-scsi, lizhijian, James E.J. Bottomley
  Cc: Martin K . Petersen, linux-kernel, Finn Thain

On Thu, 30 Jun 2022 02:38:11 +0000, lizhijian@fujitsu.com wrote:

> sdev_printk will only accept messages less than 128 bytes. So shorten
> the messages exceeding 128 bytes avoid getting a incomplete sentence like:
> [  475.156955] sd 9:0:0:0: Warning! Received an indication that the LUN assignments on this target have changed. The Linux SCSI layer does not automatical
> 
> 

Applied to 5.20/scsi-queue, thanks!

[1/1] scsi: Shorten too long warning messages
      https://git.kernel.org/mkp/scsi/c/a2417db3679c

-- 
Martin K. Petersen	Oracle Linux Engineering

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-07-14  4:23 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-30  2:38 [PATCH] scsi: Shorten too long warning messages lizhijian
2022-06-30 16:05 ` Bart Van Assche
2022-07-07 20:57 ` Martin K. Petersen
2022-07-14  4:22 ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).