Re: [PATCH] usb: gadget: use native print_hex_dump_bytes()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> writes:

> Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>

Obviously.

Acked-by: Michal Nazarewicz <mina86@xxxxxxxxxx>

In addition, it also adds ACSII print out. :)

> ---
>  drivers/usb/gadget/rndis.c |   22 ++--------------------
>  1 file changed, 2 insertions(+), 20 deletions(-)
>
> diff --git a/drivers/usb/gadget/rndis.c b/drivers/usb/gadget/rndis.c
> index b35babe..e4192b8 100644
> --- a/drivers/usb/gadget/rndis.c
> +++ b/drivers/usb/gadget/rndis.c
> @@ -863,26 +863,8 @@ int rndis_msg_parser(u8 configNr, u8 *buf)
>  		 */
>  		pr_warning("%s: unknown RNDIS message 0x%08X len %d\n",
>  			__func__, MsgType, MsgLength);
> -		{
> -			unsigned i;
> -			for (i = 0; i < MsgLength; i += 16) {
> -				pr_debug("%03d: "
> -					" %02x %02x %02x %02x"
> -					" %02x %02x %02x %02x"
> -					" %02x %02x %02x %02x"
> -					" %02x %02x %02x %02x"
> -					"\n",
> -					i,
> -					buf[i], buf [i+1],
> -						buf[i+2], buf[i+3],
> -					buf[i+4], buf [i+5],
> -						buf[i+6], buf[i+7],
> -					buf[i+8], buf [i+9],
> -						buf[i+10], buf[i+11],
> -					buf[i+12], buf [i+13],
> -						buf[i+14], buf[i+15]);
> -			}
> -		}
> +		print_hex_dump_bytes(__func__, DUMP_PREFIX_OFFSET,
> +				     buf, MsgLength);
>  		break;
>  	}

-- 
Best regards,                                         _     _
.o. | Liege of Serenely Enlightened Majesty of      o' \,=./ `o
..o | Computer Science,  Michał “mina86” Nazarewicz    (o o)
ooo +----<email/xmpp: mpn@xxxxxxxxxx>--------------ooO--(_)--Ooo--

Attachment: pgpvZSeno7BoV.pgp
Description: PGP signature


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux