diff options
author | Rasmus Villemoes <linux@rasmusvillemoes.dk> | 2014-12-03 00:10:52 +0100 |
---|---|---|
committer | James Bottomley <JBottomley@Parallels.com> | 2015-02-02 09:57:45 -0800 |
commit | 91c40f24faadd977ee9209fee6a760e72a50d19c (patch) | |
tree | 970b7a1672e51376b341387609b162a2503ca5c8 /drivers/scsi/nsp32.c | |
parent | ee7c7277d9444612c0341588abfb958dffbc5b34 (diff) | |
download | linux-91c40f24faadd977ee9209fee6a760e72a50d19c.tar.bz2 |
scsi: replace seq_printf with seq_puts
Using seq_printf to print a simple string is a lot more expensive than
it needs to be, since seq_puts exists. Replace seq_printf with
seq_puts when possible.
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/nsp32.c')
-rw-r--r-- | drivers/scsi/nsp32.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/scsi/nsp32.c b/drivers/scsi/nsp32.c index 3e775517628d..8f6b1b4c6138 100644 --- a/drivers/scsi/nsp32.c +++ b/drivers/scsi/nsp32.c @@ -1456,7 +1456,7 @@ static int nsp32_show_info(struct seq_file *m, struct Scsi_Host *host) data = (nsp32_hw_data *)host->hostdata; base = host->io_port; - seq_printf(m, "NinjaSCSI-32 status\n\n"); + seq_puts(m, "NinjaSCSI-32 status\n\n"); seq_printf(m, "Driver version: %s, $Revision: 1.33 $\n", nsp32_release_version); seq_printf(m, "SCSI host No.: %d\n", hostno); seq_printf(m, "IRQ: %d\n", host->irq); @@ -1478,25 +1478,25 @@ static int nsp32_show_info(struct seq_file *m, struct Scsi_Host *host) spin_unlock_irqrestore(&(data->Lock), flags); - seq_printf(m, "SDTR status\n"); + seq_puts(m, "SDTR status\n"); for (id = 0; id < ARRAY_SIZE(data->target); id++) { seq_printf(m, "id %d: ", id); if (id == host->this_id) { - seq_printf(m, "----- NinjaSCSI-32 host adapter\n"); + seq_puts(m, "----- NinjaSCSI-32 host adapter\n"); continue; } if (data->target[id].sync_flag == SDTR_DONE) { if (data->target[id].period == 0 && data->target[id].offset == ASYNC_OFFSET ) { - seq_printf(m, "async"); + seq_puts(m, "async"); } else { - seq_printf(m, " sync"); + seq_puts(m, " sync"); } } else { - seq_printf(m, " none"); + seq_puts(m, " none"); } if (data->target[id].period != 0) { @@ -1509,7 +1509,7 @@ static int nsp32_show_info(struct seq_file *m, struct Scsi_Host *host) data->target[id].offset ); } - seq_printf(m, "\n"); + seq_puts(m, "\n"); } return 0; } |