summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aic7xxx/aic7xxx_proc.c
diff options
context:
space:
mode:
authorRasmus Villemoes <linux@rasmusvillemoes.dk>2014-12-03 00:10:54 +0100
committerJames Bottomley <JBottomley@Parallels.com>2015-02-02 09:57:46 -0800
commitf50332ff2574130903356e800913c1a73cc6c1dc (patch)
tree89f06badf4e0f42bc26f150d89101efde0dea82e /drivers/scsi/aic7xxx/aic7xxx_proc.c
parent3d30079c3a9000504cf71e4e8dd94619070dc4f3 (diff)
downloadlinux-stable-f50332ff2574130903356e800913c1a73cc6c1dc.tar.gz
linux-stable-f50332ff2574130903356e800913c1a73cc6c1dc.tar.bz2
linux-stable-f50332ff2574130903356e800913c1a73cc6c1dc.zip
scsi: print single-character strings with seq_putc
Using seq_putc to print a single character saves at least a strlen() call and a memory access, and may also give a small .text reduction. Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk> Reviewed-by: Finn Thain <fthain@telegraphics.com.au> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/aic7xxx/aic7xxx_proc.c')
-rw-r--r--drivers/scsi/aic7xxx/aic7xxx_proc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/scsi/aic7xxx/aic7xxx_proc.c b/drivers/scsi/aic7xxx/aic7xxx_proc.c
index 25511ca2024a..18459605d991 100644
--- a/drivers/scsi/aic7xxx/aic7xxx_proc.c
+++ b/drivers/scsi/aic7xxx/aic7xxx_proc.c
@@ -125,9 +125,9 @@ ahc_format_transinfo(struct seq_file *m, struct ahc_transinfo *tinfo)
}
seq_printf(m, "%dbit)", 8 * (0x01 << tinfo->width));
} else if (freq != 0) {
- seq_puts(m, ")");
+ seq_putc(m, ')');
}
- seq_puts(m, "\n");
+ seq_putc(m, '\n');
}
static void
@@ -308,14 +308,14 @@ ahc_linux_show_info(struct seq_file *m, struct Scsi_Host *shost)
seq_puts(m, "Serial EEPROM:\n");
for (i = 0; i < sizeof(*ahc->seep_config)/2; i++) {
if (((i % 8) == 0) && (i != 0)) {
- seq_puts(m, "\n");
+ seq_putc(m, '\n');
}
seq_printf(m, "0x%.4x ",
((uint16_t*)ahc->seep_config)[i]);
}
- seq_puts(m, "\n");
+ seq_putc(m, '\n');
}
- seq_puts(m, "\n");
+ seq_putc(m, '\n');
max_targ = 16;
if ((ahc->features & (AHC_WIDE|AHC_TWIN)) == 0)