public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Fengguang Wu <fengguang.wu@intel.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Lidza Louina <lidza.louina@gmail.com>,
	kbuild-all@01.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH staging] dgnc: remove useless cast on kzalloc()
Date: Fri, 27 Sep 2013 13:09:58 +0800	[thread overview]
Message-ID: <20130927050958.GA23339@localhost> (raw)
In-Reply-To: <20130926162757.GA10468@kroah.com>

On Thu, Sep 26, 2013 at 09:27:57AM -0700, Greg KH wrote:
> On Thu, Sep 26, 2013 at 10:12:23AM +0800, Fengguang Wu wrote:
> > drivers/staging/dgnc/dgnc_driver.c:510:3-7: WARNING: casting value returned by k[cmz]alloc to (char *) is useless.
> > drivers/staging/dgnc/dgnc_driver.c:502:2-19: WARNING: casting value returned by k[cmz]alloc to (struct dgnc_board *) is useless.
> > 
> >  Casting (void *) value returned by kmalloc is useless
> >  as mentioned in Documentation/CodingStyle, Chap 14.
> > 
> > Generated by: coccinelle/api/alloc/drop_kmalloc_cast.cocci
> > 
> > CC: Lidza Louina <lidza.louina@gmail.com>
> > CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> > Signed-off-by: Fengguang Wu <fengguang.wu@intel.com>
> > ---
> > 
> >  drivers/staging/dgnc/dgnc_driver.c |    4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> As Jingoo sent this a few minutes before you did, and also cleaned up
> another cast that you missed, I've added your signed-off-by to his
> patch, as they were the same (although yours didn't apply and his
> did...)

That'd be good, thanks!

Regards,
Fengguang

      reply	other threads:[~2013-09-27  5:10 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-26  2:12 [PATCH staging] dgnc: remove useless cast on kzalloc() Fengguang Wu
2013-09-26 16:27 ` Greg Kroah-Hartman
2013-09-27  5:09   ` Fengguang Wu [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=20130927050958.GA23339@localhost \
    --to=fengguang.wu@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=kbuild-all@01.org \
    --cc=lidza.louina@gmail.com \
    --cc=linux-kernel@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox