linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Ricardo Ribalda <ribalda@chromium.org>,
	Mauro Carvalho Chehab <mchehab@kernel.org>,
	Linux Media Mailing List <linux-media@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Joe Perches <joe@perches.com>
Subject: Re: [PATCH v7 08/12] media: uvcvideo: Use dev_ printk aliases
Date: Thu, 24 Dec 2020 15:50:28 +0200	[thread overview]
Message-ID: <X+ScpMyiKFqhySG6@pendragon.ideasonboard.com> (raw)
In-Reply-To: <CAHp75VeTWUGF0huwLm9OPkDpDiDJ8vtG0W2jzoDohWEfB+L3yg@mail.gmail.com>

Hi Andy,

On Thu, Dec 24, 2020 at 02:59:34PM +0200, Andy Shevchenko wrote:
> On Wed, Dec 23, 2020 at 3:39 PM Ricardo Ribalda wrote:
> >
> > Replace all the uses of printk() and uvc_printk() with its
> > equivalent dev_ alias macros.
> 
> > Modify uvc_warn_once() macro to use dev_info instead printk().
> 
> ...
> 
> > +#define uvc_warn_once(_dev, warn, fmt, ...)                            \
> > +do {                                                                   \
> > +       if (!test_and_set_bit(warn, &(_dev)->warnings))                 \
> > +               dev_info(&(_dev)->udev->dev, fmt, ##__VA_ARGS__);       \
> > +} while (0)
> 
> ...
> 
> Why not to use dev_warn_once() instead?

uvc_warn_once() prints the warning once per device, not once globally.

-- 
Regards,

Laurent Pinchart

  reply	other threads:[~2020-12-24 13:51 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-23 13:35 [PATCH v7 00/12] Show privacy_gpio as a v4l2_ctrl Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 01/12] media: uvcvideo: Move guid to entity Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 02/12] media: uvcvideo: Allow extra entities Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 03/12] media: uvcvideo: Allow entities with no pads Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 04/12] media: uvcvideo: Provide sync and async uvc_ctrl_status_event Ricardo Ribalda
2021-01-26 15:38   ` Laurent Pinchart
2020-12-23 13:35 ` [PATCH v7 05/12] media: uvcvideo: Allow entity-defined get_info and get_cur Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 06/12] media: uvcvideo: Implement UVC_EXT_GPIO_UNIT Ricardo Ribalda
2021-01-26 15:53   ` Laurent Pinchart
2021-01-26 15:56     ` Laurent Pinchart
2020-12-23 13:35 ` [PATCH v7 07/12] media: uvcvideo: Add Privacy control based on EXT_GPIO Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 08/12] media: uvcvideo: Use dev_ printk aliases Ricardo Ribalda
2020-12-24 12:59   ` Andy Shevchenko
2020-12-24 13:50     ` Laurent Pinchart [this message]
2020-12-23 13:35 ` [PATCH v7 09/12] media: uvcvideo: New macro uvc_trace_cont Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 10/12] media: uvcvideo: use dev_printk() for uvc_trace() Ricardo Ribalda
2020-12-23 13:35 ` [PATCH v7 11/12] media: uvcvideo: Rename debug functions Ricardo Ribalda
2021-01-26 17:05   ` Laurent Pinchart
2020-12-23 13:35 ` [PATCH v7 12/12] media: uvcvideo: Implement UVC_QUIRK_PRIVACY_DURING_STREAM Ricardo Ribalda

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=X+ScpMyiKFqhySG6@pendragon.ideasonboard.com \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@kernel.org \
    --cc=ribalda@chromium.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).