All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Daeseok Youn <daeseok.youn@gmail.com>
Cc: mchehab@kernel.org, devel@driverdev.osuosl.org,
	gregkh@linuxfoundation.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org, alan@linux.intel.com,
	linux-media@vger.kernel.org
Subject: Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset
Date: Mon, 13 Mar 2017 11:51:29 +0000	[thread overview]
Message-ID: <20170313115129.GC4136@mwanda> (raw)
In-Reply-To: <20170313105421.GA32342@SEL-JYOUN-D1>

On Mon, Mar 13, 2017 at 07:54:21PM +0900, Daeseok Youn wrote:
> If the atomisp_kernel_zalloc() has "true" as a second parameter, it
> tries to allocate zeroing memory from kmalloc(vmalloc) and memset.
> But using kzalloc is rather than kmalloc followed by memset with 0.
> (vzalloc is for same reason with kzalloc)
> 
> And also atomisp_kernel_malloc() can be used with
> atomisp_kernel_zalloc(<size>, false);
> 

We should just change all the callers to kvmalloc() and kvzmalloc().

regards,
dan carpenter


WARNING: multiple messages have this Message-ID (diff)
From: Dan Carpenter <dan.carpenter@oracle.com>
To: Daeseok Youn <daeseok.youn@gmail.com>
Cc: mchehab@kernel.org, devel@driverdev.osuosl.org,
	gregkh@linuxfoundation.org, kernel-janitors@vger.kernel.org,
	linux-kernel@vger.kernel.org, alan@linux.intel.com,
	linux-media@vger.kernel.org
Subject: Re: [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset
Date: Mon, 13 Mar 2017 14:51:29 +0300	[thread overview]
Message-ID: <20170313115129.GC4136@mwanda> (raw)
In-Reply-To: <20170313105421.GA32342@SEL-JYOUN-D1>

On Mon, Mar 13, 2017 at 07:54:21PM +0900, Daeseok Youn wrote:
> If the atomisp_kernel_zalloc() has "true" as a second parameter, it
> tries to allocate zeroing memory from kmalloc(vmalloc) and memset.
> But using kzalloc is rather than kmalloc followed by memset with 0.
> (vzalloc is for same reason with kzalloc)
> 
> And also atomisp_kernel_malloc() can be used with
> atomisp_kernel_zalloc(<size>, false);
> 

We should just change all the callers to kvmalloc() and kvzmalloc().

regards,
dan carpenter

  reply	other threads:[~2017-03-13 11:51 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-13 10:54 [PATCH] staging: atomisp: use k{v}zalloc instead of k{v}alloc and memset Daeseok Youn
2017-03-13 10:54 ` Daeseok Youn
2017-03-13 11:51 ` Dan Carpenter [this message]
2017-03-13 11:51   ` Dan Carpenter
2017-03-13 14:07   ` DaeSeok Youn
2017-03-13 14:07     ` DaeSeok Youn
2017-03-13 15:40     ` DaeSeok Youn
2017-03-13 15:40       ` DaeSeok Youn
2017-03-13 17:54 ` Alan Cox
2017-03-14  1:15   ` DaeSeok Youn
2017-03-14  1:15     ` DaeSeok Youn

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=20170313115129.GC4136@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=alan@linux.intel.com \
    --cc=daeseok.youn@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-media@vger.kernel.org \
    --cc=mchehab@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 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.