From patchwork Tue Aug 7 22:56:36 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antti Palosaari X-Patchwork-Id: 1290261 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 57D613FCC5 for ; Tue, 7 Aug 2012 22:57:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1031113Ab2HGW5N (ORCPT ); Tue, 7 Aug 2012 18:57:13 -0400 Received: from mail.kapsi.fi ([217.30.184.167]:45497 "EHLO mail.kapsi.fi" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1031079Ab2HGW5L (ORCPT ); Tue, 7 Aug 2012 18:57:11 -0400 Received: from dyn3-82-128-186-179.psoas.suomi.net ([82.128.186.179] helo=localhost.localdomain) by mail.kapsi.fi with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.72) (envelope-from ) id 1Sysi6-0003mc-9z; Wed, 08 Aug 2012 01:57:10 +0300 From: Antti Palosaari To: linux-media@vger.kernel.org Cc: Antti Palosaari , Andy Shevchenko Subject: [PATCH 2/2] dvb_usb_v2: use %*ph to dump usb xfer debugs Date: Wed, 8 Aug 2012 01:56:36 +0300 Message-Id: <1344380196-9488-2-git-send-email-crope@iki.fi> X-Mailer: git-send-email 1.7.11.2 In-Reply-To: <1344380196-9488-1-git-send-email-crope@iki.fi> References: <1344380196-9488-1-git-send-email-crope@iki.fi> X-SA-Exim-Connect-IP: 82.128.186.179 X-SA-Exim-Mail-From: crope@iki.fi X-SA-Exim-Scanned: No (on mail.kapsi.fi); SAEximRunCond expanded to false Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Cc: Andy Shevchenko Signed-off-by: Antti Palosaari --- drivers/media/dvb/dvb-usb-v2/dvb_usb_urb.c | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/drivers/media/dvb/dvb-usb-v2/dvb_usb_urb.c b/drivers/media/dvb/dvb-usb-v2/dvb_usb_urb.c index 5f5bdd0..0431bee 100644 --- a/drivers/media/dvb/dvb-usb-v2/dvb_usb_urb.c +++ b/drivers/media/dvb/dvb-usb-v2/dvb_usb_urb.c @@ -21,7 +21,6 @@ #include "dvb_usb_common.h" -#undef DVB_USB_XFER_DEBUG int dvb_usbv2_generic_rw(struct dvb_usb_device *d, u8 *wbuf, u16 wlen, u8 *rbuf, u16 rlen) { @@ -37,10 +36,8 @@ int dvb_usbv2_generic_rw(struct dvb_usb_device *d, u8 *wbuf, u16 wlen, u8 *rbuf, if (ret < 0) return ret; -#ifdef DVB_USB_XFER_DEBUG - print_hex_dump(KERN_DEBUG, KBUILD_MODNAME ": >>> ", DUMP_PREFIX_NONE, - 32, 1, wbuf, wlen, 0); -#endif + dev_dbg(&d->udev->dev, "%s: >>> %*ph\n", __func__, wlen, wbuf); + ret = usb_bulk_msg(d->udev, usb_sndbulkpipe(d->udev, d->props->generic_bulk_ctrl_endpoint), wbuf, wlen, &actual_length, 2000); @@ -64,11 +61,8 @@ int dvb_usbv2_generic_rw(struct dvb_usb_device *d, u8 *wbuf, u16 wlen, u8 *rbuf, dev_err(&d->udev->dev, "%s: 2nd usb_bulk_msg() " \ "failed=%d\n", KBUILD_MODNAME, ret); -#ifdef DVB_USB_XFER_DEBUG - print_hex_dump(KERN_DEBUG, KBUILD_MODNAME ": <<< ", - DUMP_PREFIX_NONE, 32, 1, rbuf, actual_length, - 0); -#endif + dev_dbg(&d->udev->dev, "%s: <<< %*ph\n", __func__, + actual_length, rbuf); } mutex_unlock(&d->usb_mutex);