lkml.org 
[lkml]   [2014]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    SubjectRe: [PATCH] staging: unisys: use kzalloc instead of kmalloc/memset 0
    From
    Hi, greg.

    Review my comment below.

    Thanks.
    Daeseok Youn.

    2014-03-18 17:11 GMT+09:00 DaeSeok Youn <daeseok.youn@gmail.com>:
    > 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.
    >
    > 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.
    >
    >>
    >>> (UISMALLOC() macro is also removed.)
    >>
    >> Yes.
    >>
    >>> And uislib_malloc() is renamed to "uislib_trace_buffer_status()" which
    >>> is just tracing buffer status(Malloc_FailuresAlloc, Malloc_BytesInUse
    >>> ...) for info_proc_read_helper().
    >>
    >> The whole tracing stuff needs to be ripped out, so no problem deleting
    >> it here as well.
    >
    > OK. I will remove that information in info_proc_read_helper().
    >
    >>
    >>> If this change is accepted, it also need to change uislib_free().
    >>
    >> Drop it and just use kfree().
    > OK. replace kfree() with uislib_free().
    >
    >>
    >> thanks,
    >>
    >> greg k-h


    \
     
     \ /
      Last update: 2014-03-19 01:41    [W:2.696 / U:0.272 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site