mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
To: Joe Perches <joe@perches.com>
Cc: linux-kernel@vger.kernel.org,
	Adrian Hunter <adrian.hunter@nokia.com>,
	Alex Elder <aelder@sgi.com>,
	Artem Bityutskiy <dedekind@infradead.org>,
	Christoph Hellwig <hch@lst.de>,
	Harvey Harrison <harvey.harrison@gmail.com>,
	Huang Ying <ying.huang@intel.com>, Ingo Molnar <mingo@elte.hu>,
	Jeff Garzik <jgarzik@redhat.com>, Matt Mackall <mpm@selenic.com>,
	Mauro Carvalho Chehab <mchehab@infradead.org>,
	Neil Brown <neilb@suse.de>,
	Steven Whitehouse <swhiteho@redhat.com>,
	xfs-masters@oss.sgi.com, linux-media@vger.kernel.org
Subject: Re: [PATCH 6/9] drivers/media/video/uvc: Use %pUr to print UUIDs
Date: Thu, 1 Oct 2009 02:20:17 +0200	[thread overview]
Message-ID: <200910010220.17534.laurent.pinchart@ideasonboard.com> (raw)
In-Reply-To: <111526fa2ce7f728d1f81465a00859c1780f0607.1254193019.git.joe@perches.com>

Hi Joe,

thanks for the patch. A few comments below.

On Tuesday 29 September 2009 07:01:08 Joe Perches wrote:
> Signed-off-by: Joe Perches <joe@perches.com>
> ---
>  drivers/media/video/uvc/uvc_ctrl.c   |   69 ++++++++++++++++------------------
>  drivers/media/video/uvc/uvc_driver.c |    7 +--
>  drivers/media/video/uvc/uvcvideo.h   |   10 -----
>  3 files changed, 35 insertions(+), 51 deletions(-)
> 
> diff --git a/drivers/media/video/uvc/uvc_ctrl.c
>  b/drivers/media/video/uvc/uvc_ctrl.c index c3225a5..2959e46 100644
> --- a/drivers/media/video/uvc/uvc_ctrl.c
> +++ b/drivers/media/video/uvc/uvc_ctrl.c
> @@ -1093,8 +1093,8 @@ int uvc_xu_ctrl_query(struct uvc_video_chain *chain,
> 
>  	if (!found) {
>  		uvc_trace(UVC_TRACE_CONTROL,
> -			"Control " UVC_GUID_FORMAT "/%u not found.\n",
> -			UVC_GUID_ARGS(entity->extension.guidExtensionCode),
> +			"Control %pUr/%u not found.\n",
> +			entity->extension.guidExtensionCode,
>  			xctrl->selector);

Could you try to cut long statements in as few lines as possible ? This one
would become

		uvc_trace(UVC_TRACE_CONTROL, "Control %pUr/%u not found.\n",
			  entity->extension.guidExtensionCode, xctrl->selector);

There are a few others that should be changed as well. If you prefer I can
apply the patch through my tree (after the printk patch goes in of course)
and handle that myself.

[snip]

>  		flags = info->flags;
>  		if (((flags & UVC_CONTROL_GET_CUR) && !(inf & (1 << 0))) ||
>  		    ((flags & UVC_CONTROL_SET_CUR) && !(inf & (1 << 1)))) {
> -			uvc_trace(UVC_TRACE_CONTROL, "Control "
> -				UVC_GUID_FORMAT "/%u flags don't match "
> -				"supported operations.\n",
> -				UVC_GUID_ARGS(info->entity), info->selector);
> +			uvc_trace(UVC_TRACE_CONTROL,
> +				  "Control %pUr/%u flags don't match supported operations.\n",
> +				  info->entity, info->selector);

This doesn't fit the 80 columns limit. Please run checkpatch.pl on your patches.

[snip]

> diff --git a/drivers/media/video/uvc/uvc_driver.c
>  b/drivers/media/video/uvc/uvc_driver.c index 8756be5..647d0a2 100644
> --- a/drivers/media/video/uvc/uvc_driver.c
> +++ b/drivers/media/video/uvc/uvc_driver.c
> @@ -328,11 +328,10 @@ static int uvc_parse_format(struct uvc_device *dev,
>  				sizeof format->name);
>  			format->fcc = fmtdesc->fcc;
>  		} else {
> -			uvc_printk(KERN_INFO, "Unknown video format "
> -				UVC_GUID_FORMAT "\n",
> -				UVC_GUID_ARGS(&buffer[5]));
> +			uvc_printk(KERN_INFO, "Unknown video format %pUr\n",
> +				   &buffer[5]);
>  			snprintf(format->name, sizeof format->name,
> -				UVC_GUID_FORMAT, UVC_GUID_ARGS(&buffer[5]));
> +				 "%pUr", &Buffer[5]);

Should be &buffer[5], not &Buffer[5]. You haven't compiled the patch, have
you ? :-)

-- 
Regards,

Laurent Pinchart

  reply	other threads:[~2009-10-01  0:18 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-29  5:01 [PATCH 0/9] Add vsprintf extension %pU to print UUID/GUIDs and use it Joe Perches
2009-09-29  5:01 ` [PATCH 1/9] lib/vsprintf.c: Add %pU to print UUID/GUIDs Joe Perches
2009-10-01  7:10   ` Geert Uytterhoeven
2009-10-01  7:26     ` Joe Perches
2009-10-01  8:55       ` Geert Uytterhoeven
2009-10-07  0:07         ` Joe Perches
2009-09-29  5:01 ` [PATCH 2/9] efi.h: Use %pUr to print UUIDs Joe Perches
2009-09-29  5:01 ` [PATCH 3/9] random.c: Use %pU " Joe Perches
2009-09-29  5:01 ` [PATCH 4/9] drivers/firmware/dmi_scan.c: Use %pUX " Joe Perches
2009-09-29  5:01 ` [PATCH 5/9] drivers/md/md.c: Use %pU " Joe Perches
2009-09-29  5:01 ` [PATCH 6/9] drivers/media/video/uvc: Use %pUr " Joe Perches
2009-10-01  0:20   ` Laurent Pinchart [this message]
2009-10-01  0:24     ` Joe Perches
2009-09-29  5:01 ` [PATCH 7/9] fs/gfs2/sys.c: Use %pUX " Joe Perches
2009-09-29  8:50   ` Steven Whitehouse
2009-09-29  5:01 ` [PATCH 8/9] fs/ubifs: " Joe Perches
2009-09-29 12:32   ` Artem Bityutskiy
2009-09-29  5:01 ` [PATCH 9/9] fs/xfs/xfs_log_recover.c: Use %pU " Joe Perches
2009-09-29  5:57 ` [PATCH 0/9] Add vsprintf extension %pU to print UUID/GUIDs and use it Huang Ying
2009-10-01  0:07   ` Laurent Pinchart
2009-10-01  0:20     ` Joe Perches
2009-10-10  5:50     ` Huang Ying

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=200910010220.17534.laurent.pinchart@ideasonboard.com \
    --to=laurent.pinchart@ideasonboard.com \
    --cc=adrian.hunter@nokia.com \
    --cc=aelder@sgi.com \
    --cc=dedekind@infradead.org \
    --cc=harvey.harrison@gmail.com \
    --cc=hch@lst.de \
    --cc=jgarzik@redhat.com \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@infradead.org \
    --cc=mingo@elte.hu \
    --cc=mpm@selenic.com \
    --cc=neilb@suse.de \
    --cc=swhiteho@redhat.com \
    --cc=xfs-masters@oss.sgi.com \
    --cc=ying.huang@intel.com \
    /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

all inboxes | Powered by JetHome®