linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ipr: Rate limit DMA mapping errors
@ 2011-05-09  0:07 Anton Blanchard
  2011-05-09 13:05 ` Brian King
  0 siblings, 1 reply; 2+ messages in thread
From: Anton Blanchard @ 2011-05-09  0:07 UTC (permalink / raw)
  To: wayneb, brking; +Cc: linux-scsi


I noticed a stream of errors from the IPR driver while doing
IOMMU fault injection. Rate limit the errors so we don't clog
up the console and logfiles.

Signed-off-by: Anton Blanchard <anton@samba.org>
---

Index: linux-powerpc/drivers/scsi/ipr.c
===================================================================
--- linux-powerpc.orig/drivers/scsi/ipr.c	2011-05-03 16:35:10.304480474 +1000
+++ linux-powerpc/drivers/scsi/ipr.c	2011-05-09 10:00:41.439578385 +1000
@@ -5143,7 +5143,8 @@ static int ipr_build_ioadl64(struct ipr_
 
 	nseg = scsi_dma_map(scsi_cmd);
 	if (nseg < 0) {
-		dev_err(&ioa_cfg->pdev->dev, "pci_map_sg failed!\n");
+		if (printk_ratelimit())
+			dev_err(&ioa_cfg->pdev->dev, "pci_map_sg failed!\n");
 		return -1;
 	}
 

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

end of thread, other threads:[~2011-05-09 13:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-05-09  0:07 [PATCH] ipr: Rate limit DMA mapping errors Anton Blanchard
2011-05-09 13:05 ` Brian King

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).