diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2015-07-16 15:42:15 +0300 |
---|---|---|
committer | Kalle Valo <kvalo@codeaurora.org> | 2015-07-21 18:08:21 +0300 |
commit | 8358491d893e08d4b82af0d6012e078158f57ed9 (patch) | |
tree | f7c642f9f7fc59ce1111d8305c71c7b145fdb09d /drivers/net/wireless/iwlegacy/3945-mac.c | |
parent | 5d6af28a2d240602a594cea236406a9d29bc719a (diff) | |
download | linux-stable-8358491d893e08d4b82af0d6012e078158f57ed9.tar.gz linux-stable-8358491d893e08d4b82af0d6012e078158f57ed9.tar.bz2 linux-stable-8358491d893e08d4b82af0d6012e078158f57ed9.zip |
iwlegacy: convert hex_dump_to_buffer() to %*ph
There is no need to use hex_dump_to_buffer() in the cases like this:
hexdump_to_buffer(buf, len, 16, 1, outbuf, outlen, false); /* len <= 16 */
sprintf("%s\n", outbuf);
since it maybe easily converted to simple:
sprintf("%*ph\n", len, buf);
Note: it seems in the case the output is groupped by 2 bytes and looks like a
typo. Thus, patch changes that to plain byte stream.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Diffstat (limited to 'drivers/net/wireless/iwlegacy/3945-mac.c')
-rw-r--r-- | drivers/net/wireless/iwlegacy/3945-mac.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/wireless/iwlegacy/3945-mac.c b/drivers/net/wireless/iwlegacy/3945-mac.c index 7f4cb692cc57..af1b3e6839fa 100644 --- a/drivers/net/wireless/iwlegacy/3945-mac.c +++ b/drivers/net/wireless/iwlegacy/3945-mac.c @@ -3259,7 +3259,7 @@ il3945_show_measurement(struct device *d, struct device_attribute *attr, while (size && PAGE_SIZE - len) { hex_dump_to_buffer(data + ofs, size, 16, 1, buf + len, - PAGE_SIZE - len, 1); + PAGE_SIZE - len, true); len = strlen(buf); if (PAGE_SIZE - len) buf[len++] = '\n'; |