Re: [2/2] iwlegacy: convert hex_dump_to_buffer() to %*ph

2015-07-21 Thread Kalle Valo
> 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: i

[PATCH 2/2] iwlegacy: convert hex_dump_to_buffer() to %*ph

2015-07-16 Thread Andy Shevchenko
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 ca