public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab@redhat.com>
To: stefan.ringel@arcor.de
Cc: linux-media@vger.kernel.org, d.belimov@gmail.com
Subject: Re: [PATCH 14/16] tm6000: add pts logging
Date: Fri, 20 May 2011 20:15:58 -0300	[thread overview]
Message-ID: <4DD6F62E.7000704@redhat.com> (raw)
In-Reply-To: <1304970844-20955-14-git-send-email-stefan.ringel@arcor.de>

Em 09-05-2011 16:54, stefan.ringel@arcor.de escreveu:
> From: Stefan Ringel <stefan.ringel@arcor.de>
> 
> add pts logging
> 
> 
> Signed-off-by: Stefan Ringel <stefan.ringel@arcor.de>
> ---
>  drivers/staging/tm6000/tm6000-video.c |    6 +++++-
>  1 files changed, 5 insertions(+), 1 deletions(-)
> 
> diff --git a/drivers/staging/tm6000/tm6000-video.c b/drivers/staging/tm6000/tm6000-video.c
> index 2d83204..4802396 100644
> --- a/drivers/staging/tm6000/tm6000-video.c
> +++ b/drivers/staging/tm6000/tm6000-video.c
> @@ -355,10 +355,14 @@ static int copy_streams(u8 *data, unsigned long len,
>  			case TM6000_URB_MSG_VBI:
>  				/* Need some code to copy vbi buffer */
>  				break;
> -			case TM6000_URB_MSG_PTS:
> +			case TM6000_URB_MSG_PTS: {
>  				/* Need some code to copy pts */
> +				u32 pts;
> +				pts = *(u32 *)ptr;
> +				printk(KERN_INFO "%s: field %d, PTS %x", dev->name, field, pts);

Hmm... field may be unititialized... Please fix.

drivers/staging/tm6000/tm6000-video.c: In function ‘copy_streams’:
drivers/staging/tm6000/tm6000-video.c:231: warning: ‘field’ may be used uninitialized in this function

Also, it is not a good idea of just logging it. Instead, use enable logging only if debug is enabled
seems more appropriate.

Please send a patch fixing it.

Thanks,
Mauro.

>  				break;
>  			}
> +			}
>  		}
>  		if (ptr + pktsize > endp) {
>  			/* End of URB packet, but cmd processing is not


  reply	other threads:[~2011-05-20 23:16 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-09 19:53 [PATCH 01/16] tm6000: add radio capabilities stefan.ringel
2011-05-09 19:53 ` [PATCH 02/16] tm6000: add tm6010 audio mode setup stefan.ringel
2011-05-09 19:53 ` [PATCH 03/16] tm6000: change to virtual inputs stefan.ringel
2011-05-09 19:53 ` [PATCH 04/16] tm6000: vitual input enums stefan.ringel
2011-05-09 19:53 ` [PATCH 05/16] tm6000: change input control stefan.ringel
2011-05-09 19:53 ` [PATCH 06/16] tm6000: add eeprom stefan.ringel
2011-05-09 19:53 ` [PATCH 07/16] tm6000: remove unused capabilities stefan.ringel
2011-05-09 19:53 ` [PATCH 08/16] tm6000: remove old tuner params stefan.ringel
2011-05-09 19:53 ` [PATCH 09/16] tm6000: remove dopple init stefan.ringel
2011-05-09 19:53 ` [PATCH 10/16] tm6000: move from tm6000_set_reg to tm6000_set_reg_mask stefan.ringel
2011-05-09 19:53 ` [PATCH 11/16] tm6000: remove input select stefan.ringel
2011-05-09 19:54 ` [PATCH 12/16] tm6000: all audio packets must swab stefan.ringel
2011-05-09 19:54 ` [PATCH 13/16] tm6000: change from ioctl to unlocked_ioctl stefan.ringel
2011-05-09 19:54 ` [PATCH 14/16] tm6000: add pts logging stefan.ringel
2011-05-20 23:15   ` Mauro Carvalho Chehab [this message]
2011-05-09 19:54 ` [PATCH 15/16] tm6000: remove unsued exports stefan.ringel
2011-05-09 19:54 ` [PATCH 16/16] tm6000: remove tm6010 sif audio start and stop stefan.ringel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4DD6F62E.7000704@redhat.com \
    --to=mchehab@redhat.com \
    --cc=d.belimov@gmail.com \
    --cc=linux-media@vger.kernel.org \
    --cc=stefan.ringel@arcor.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox