tpmdd-devel.lists.sourceforge.net archive mirror
 help / color / mirror / Atom feed
From: Jarkko Sakkinen <jarkko.sakkinen-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
To: Tomas Winkler <tomas.winkler-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Cc: tpmdd-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [PATCH 1/1] tpm/tpm-dev: fix broken style in copy_from_user
Date: Sun, 11 Sep 2016 23:38:49 +0300	[thread overview]
Message-ID: <20160911203849.GA26511@intel.com> (raw)
In-Reply-To: <1473621730-23125-1-git-send-email-tomas.winkler-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

On Sun, Sep 11, 2016 at 10:22:10PM +0300, Tomas Winkler wrote:
> Straighten unneeded line brake and drop useless cast to void.
> 
> Signed-off-by: Tomas Winkler <tomas.winkler-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

Thanks.

Acked-by: Jarkko Sakkinen <jarkko.sakkinen-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>

/Jarkko

> ---
>  drivers/char/tpm/tpm-dev.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/drivers/char/tpm/tpm-dev.c b/drivers/char/tpm/tpm-dev.c
> index 912ad30be585..9782df406345 100644
> --- a/drivers/char/tpm/tpm-dev.c
> +++ b/drivers/char/tpm/tpm-dev.c
> @@ -130,8 +130,7 @@ static ssize_t tpm_write(struct file *file, const char __user *buf,
>  
>  	mutex_lock(&priv->buffer_mutex);
>  
> -	if (copy_from_user
> -	    (priv->data_buffer, (void __user *) buf, in_size)) {
> +	if (copy_from_user(priv->data_buffer, buf, in_size)) {
>  		mutex_unlock(&priv->buffer_mutex);
>  		return -EFAULT;
>  	}
> -- 
> 2.7.4
> 

------------------------------------------------------------------------------

  parent reply	other threads:[~2016-09-11 20:38 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-11 19:22 [PATCH 1/1] tpm/tpm-dev: fix broken style in copy_from_user Tomas Winkler
     [not found] ` <1473621730-23125-1-git-send-email-tomas.winkler-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2016-09-11 20:38   ` Jarkko Sakkinen [this message]
     [not found]     ` <20160911203849.GA26511-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2016-09-12  4:39       ` Peter Huewe
     [not found]         ` <E2960FB9-598A-4289-9486-9B8AFD054E95-Mmb7MZpHnFY@public.gmane.org>
2016-09-12  7:56           ` Jarkko Sakkinen
     [not found]             ` <20160912075637.GB5094-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2016-09-12 16:06               ` Peter Huewe
     [not found]                 ` <3113B445-E63D-45C3-8B6A-DFDB1B5DDC7D-Mmb7MZpHnFY@public.gmane.org>
2016-09-12 18:42                   ` Jarkko Sakkinen

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=20160911203849.GA26511@intel.com \
    --to=jarkko.sakkinen-vuqaysv1563yd54fqh9/ca@public.gmane.org \
    --cc=tomas.winkler-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
    --cc=tpmdd-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.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).