All of lore.kernel.org
 help / color / mirror / Atom feed
From: Harry Wentland <hwentlan@amd.com>
To: "Zhang, Dingchen (David)" <Dingchen.Zhang@amd.com>,
	"dri-devel@lists.freedesktop.org"
	<dri-devel@lists.freedesktop.org>
Cc: "Li, Sun peng (Leo)" <Sunpeng.Li@amd.com>
Subject: Re: [PATCH] drm: actually remove the newline for CRC source name.
Date: Thu, 6 Jun 2019 19:12:19 +0000	[thread overview]
Message-ID: <60f94b35-1d4e-59fc-1801-c601946173a3@amd.com> (raw)
In-Reply-To: <20190605183556.3006-1-dingchen.zhang@amd.com>

Thanks for the quick follow-up to Sam.

Drop the word "actually" from the patch subject line.

It's generally helpful to generate a 2nd version of the patch with '-v
2', and to leave a description what v2 changed.

Also CC anyone who previously commented.

On 2019-06-05 2:35 p.m., Dingchen Zhang wrote:
> 'n-1' is the index to replace the newline character of CRC source name.
> 

Add here:
v2: Update patch subject (Sam)

> Cc: Leo Li <sunpeng.li@amd.com>
> Cc: Harry Wentland<Harry.Wentland@amd.com>
> Signed-off-by: Dingchen Zhang <dingchen.zhang@amd.com>
> ---
>  drivers/gpu/drm/drm_debugfs_crc.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/gpu/drm/drm_debugfs_crc.c b/drivers/gpu/drm/drm_debugfs_crc.c
> index 585169f0dcc5..e20adef9d623 100644
> --- a/drivers/gpu/drm/drm_debugfs_crc.c
> +++ b/drivers/gpu/drm/drm_debugfs_crc.c
> @@ -131,8 +131,8 @@ static ssize_t crc_control_write(struct file *file, const char __user *ubuf,
>  	if (IS_ERR(source))
>  		return PTR_ERR(source);
>  
> -	if (source[len] == '\n')
> -		source[len] = '\0';
> +	if (source[len-1] == '\n')
> +		source[len-1] = '\0';
>  

As Sam mentioned, you'll want this to be

+	if (source[len - 1] == '\n')
+		source[len - 1] = '\0';

I forgot to mention this to you before, but please run
./scripts/checkpatch.pl on your patches before sending them and fix up
any errors or warnings.

Harry

>  	ret = crtc->funcs->verify_crc_source(crtc, source, &values_cnt);
>  	if (ret)
> 
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

      parent reply	other threads:[~2019-06-06 19:12 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-05 18:35 [PATCH] drm: actually remove the newline for CRC source name Dingchen Zhang
2019-06-05 18:59 ` Sam Ravnborg
2019-06-06 19:12 ` Harry Wentland [this message]

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=60f94b35-1d4e-59fc-1801-c601946173a3@amd.com \
    --to=hwentlan@amd.com \
    --cc=Dingchen.Zhang@amd.com \
    --cc=Sunpeng.Li@amd.com \
    --cc=dri-devel@lists.freedesktop.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.