summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2011-05-09 02:07:40 +0200
committerJames Bottomley <jbottomley@parallels.com>2011-05-17 09:17:07 +0200
commit51f52a47527a07e45746b1bac1ab6123892095a0 (patch)
tree709a14b83e78ea467d5dd1581b55f637a8390885 /drivers
parent[SCSI] hpsa: add P2000 to list of shared SAS devices (diff)
downloadlinux-51f52a47527a07e45746b1bac1ab6123892095a0.tar.xz
linux-51f52a47527a07e45746b1bac1ab6123892095a0.zip
[SCSI] ipr: Rate limit DMA mapping errors
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> Acked-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: James Bottomley <jbottomley@parallels.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/scsi/ipr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/ipr.c b/drivers/scsi/ipr.c
index 3667f89abdea..12868ca46110 100644
--- a/drivers/scsi/ipr.c
+++ b/drivers/scsi/ipr.c
@@ -5200,7 +5200,8 @@ static int ipr_build_ioadl64(struct ipr_ioa_cfg *ioa_cfg,
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;
}