All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ivan Safonov <insafonov@gmail.com>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: devel@driverdev.osuosl.org, Anish Bhatt <anish@gatech.edu>,
	Vaishali Thakkar <vthakkar1994@gmail.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org,
	Nicholas Mc Guire <der.herr@hofr.at>,
	Joe Perches <joe@perches.com>,
	Sudip Mukherjee <sudipm.mukherjee@gmail.com>,
	Alexey Khoroshilov <khoroshilov@ispras.ru>
Subject: Re: [PATCH v2 05/12] staging: rtl8188eu: kzalloc replaced by kmalloc
Date: Wed, 11 Nov 2015 17:17:50 +0700	[thread overview]
Message-ID: <564315CE.3090902@gmail.com> (raw)
In-Reply-To: <20151111094314.GF18797@mwanda>

On 11/11/2015 04:43 PM, Dan Carpenter wrote:
> On Sun, Nov 08, 2015 at 02:11:08PM +0700, Ivan Safonov wrote:
>> _rtl88e_fill_dummy fills the array elemets with zeros if necessary.
>>
> _rtl88e_fill_dummy() fills the last sizeof(u32) or whatever so the code
> is aligned but it doesn't fill up to the end of FW_8188E_SIZE.  Why do
> we even allocate that much memory.  Why don't we just allocate:
>
> 	pfwdata = kmalloc(round_up(fwsize, sizeof(u32)), GFP_KERNEL);
>
> regards,
> dan carpenter

Yes, it will save about 2 KB. I will correct it in the next patch.

  reply	other threads:[~2015-11-11 10:16 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-08  7:11 [PATCH v2 05/12] staging: rtl8188eu: kzalloc replaced by kmalloc Ivan Safonov
2015-11-11  9:43 ` Dan Carpenter
2015-11-11 10:17   ` Ivan Safonov [this message]
2016-02-08  2:55     ` Greg Kroah-Hartman

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=564315CE.3090902@gmail.com \
    --to=insafonov@gmail.com \
    --cc=anish@gatech.edu \
    --cc=dan.carpenter@oracle.com \
    --cc=der.herr@hofr.at \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=joe@perches.com \
    --cc=khoroshilov@ispras.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sudipm.mukherjee@gmail.com \
    --cc=vthakkar1994@gmail.com \
    /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.