提交 f4d0ad1f 编写于 作者: A Andy Shevchenko 提交者: Martin K. Petersen

scsi: hpsa: Use vsnprintf extension %phN

Using this extension reduces the object size.
Signed-off-by: NAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: NDon Brace <don.brace@microsemi.com>
Signed-off-by: NMartin K. Petersen <martin.petersen@oracle.com>
上级 85e75175
......@@ -4619,21 +4619,13 @@ static int hpsa_scatter_gather(struct ctlr_info *h,
return 0;
}
#define BUFLEN 128
static inline void warn_zero_length_transfer(struct ctlr_info *h,
u8 *cdb, int cdb_len,
const char *func)
{
char buf[BUFLEN];
int outlen;
int i;
outlen = scnprintf(buf, BUFLEN,
"%s: Blocking zero-length request: CDB:", func);
for (i = 0; i < cdb_len; i++)
outlen += scnprintf(buf+outlen, BUFLEN - outlen,
"%02hhx", cdb[i]);
dev_warn(&h->pdev->dev, "%s\n", buf);
dev_warn(&h->pdev->dev,
"%s: Blocking zero-length request: CDB:%*phN\n",
func, cdb_len, cdb);
}
#define IO_ACCEL_INELIGIBLE 1
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册