All of lore.kernel.org
 help / color / mirror / Atom feed
From: Greg KH <gregkh@linuxfoundation.org>
To: DaeSeok Youn <daeseok.youn@gmail.com>
Cc: devel <devel@driverdev.osuosl.org>,
	linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] staging: unisys: use kzalloc instead of kmalloc/memset 0
Date: Wed, 19 Mar 2014 02:31:35 +0000	[thread overview]
Message-ID: <20140319023135.GB25178@kroah.com> (raw)
In-Reply-To: <CAHb8M2D1vGZ1xk=Xs6y2hTPAy_9efXV1LVvi7t2MscBW+_CyEg@mail.gmail.com>

On Wed, Mar 19, 2014 at 10:04:40AM +0900, DaeSeok Youn wrote:
> oh...
> You didn't get my reply about vmalloc usage.
> 
> My replay attach again, below.
> 
> > 2014-03-18 9:37 GMT+09:00 Greg KH <gregkh@linuxfoundation.org>:
> >> On Tue, Mar 18, 2014 at 09:26:07AM +0900, DaeSeok Youn wrote:
> >>> I think vmalloc/kmalloc in uislib_malloc() can be removed and just use
> >>> vmalloc/kmalloc directly.
> >>
> >> Yes.  Actually, just use kmalloc, I don't knwo why vmalloc is being
> >> used, but cc: the driver maintainers just to be sure.
> >
> Here, need to check by you.
> > It try to allocate 128KiB(131072byte) with vmalloc(). I think if it
> > trying to allocate with kmalloc()
> > it has a possibility to fail because of memory fragmentation even if
> > system has enough memory to use.
> > Just my opinion. If I'm wrong, let me know.

Check to see just how big you are allocating, you should know based on
the flags which code path happened uislib_malloc().

Just keep the logic the same and you should be fine.

greg k-h

  reply	other threads:[~2014-03-19  2:30 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-12 10:37 [PATCH] staging: unisys: use kzalloc instead of kmalloc/memset 0 Daeseok Youn
2014-03-17 21:41 ` Greg KH
2014-03-18  0:26   ` DaeSeok Youn
2014-03-18  0:37     ` Greg KH
2014-03-18  8:11       ` DaeSeok Youn
2014-03-19  0:03         ` DaeSeok Youn
2014-03-19  0:58           ` Greg KH
2014-03-19  1:04             ` DaeSeok Youn
2014-03-19  2:31               ` Greg KH [this message]
2014-03-19  4:32                 ` DaeSeok Youn
2014-03-18 13:00     ` Ken Cox
2014-03-19  0:09       ` DaeSeok Youn
2014-03-19  0:58         ` Greg KH
2014-03-18 20:07 ` [patch][wip] staging: unisys: kmalloc/memset move to kzalloc Silvio F
2014-03-18 20:07   ` [PATCH] staging: unisys: kmalloc/memset to kzalloc conversation Silvio F
2014-03-18 20:17     ` Joe Perches
2014-03-18 20:41       ` Greg KH
2014-03-18 20:41     ` Greg KH
2014-03-18 20:46       ` Silvio F.
2014-03-18 21:13 ` [patch][wip] staging: unisys: kmalloc/memset move to kzalloc Silvio F
2014-03-18 21:13   ` [PATCH] staging: unisys: kmalloc/memset to kzalloc conversation Silvio F

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=20140319023135.GB25178@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=daeseok.youn@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --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 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.