All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab@redhat.com>
To: damateem <damateem4@gmail.com>
Cc: linux-media list <linux-media@vger.kernel.org>
Subject: Re: Debug output
Date: Thu, 01 Dec 2011 17:18:30 -0200	[thread overview]
Message-ID: <4ED7D306.6040603@redhat.com> (raw)
In-Reply-To: <4ED7CF04.8050906@gmail.com>

On 01-12-2011 17:01, damateem wrote:
> Ok, if I set debug as follows
>
> vfd->debug =V4L2_DEBUG_IOCTL | V4L2_DEBUG_IOCTL_ARG;
>
> I can see the debug trace in dmesg, but this doesn't seem like the
> correct way to set the flags.

In general, what it is none is to add a debug modprobe parameter that
would enable those logs with something like:

static unsigned int debug;
module_param(debug, int, 0644);
MODULE_PARM_DESC(debug, "debug message mask (1 = ioctl, 2 = ioctl args)");


...
	vfd->debug = debug;

>
> What is the typical method of setting these debug flags?
>
> Is this the best place to ask these type of questions?
>
> Thanks,
> David
>
>
> On 11/30/2011 7:46 PM, damateem wrote:
>> There are a fair number of debug print statements in the V4L2 code. How
>> do I turn those on?
>>
>> For instance, I'd like the following code to print
>>
>> if ((vfd->debug&  V4L2_DEBUG_IOCTL)&&
>>                  !(vfd->debug&  V4L2_DEBUG_IOCTL_ARG)) {
>>          v4l_print_ioctl(vfd->name, cmd);
>>          printk(KERN_CONT "\n");
>>      }
>>
>> so I can trace the IOCTL calls.
>>
>> Thanks,
>> David
> --
> To unsubscribe from this list: send the line "unsubscribe linux-media" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


  reply	other threads:[~2011-12-01 19:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-01  0:46 Debug output damateem
2011-12-01 19:01 ` damateem
2011-12-01 19:18   ` Mauro Carvalho Chehab [this message]
     [not found] <B50FF75CBCFA2E4E8D23F26E18F52B101850FF@mail.oerlikon.ca>
2006-08-31 15:01 ` Debug Output Abot Botbot
  -- strict thread matches above, loose matches on Subject: below --
2006-08-31  3:37 IP-Config: Failed to open eth0 kabbin
2006-08-31 14:10 ` Debug Output Abot Botbot

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=4ED7D306.6040603@redhat.com \
    --to=mchehab@redhat.com \
    --cc=damateem4@gmail.com \
    --cc=linux-media@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.