Linux wireless drivers development
 help / color / mirror / Atom feed
From: Jouni Malinen <j@w1.fi>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: "John W. Linville" <linville@tuxdriver.com>,
	linux-wireless@vger.kernel.org
Subject: Re: [PATCH] nl80211: New command for adding extra IE(s) into management frames
Date: Tue, 13 Jan 2009 15:49:48 +0200	[thread overview]
Message-ID: <20090113134948.GA16694@jm.kir.nu> (raw)
In-Reply-To: <1231853937.3671.28.camel@johannes>

On Tue, Jan 13, 2009 at 02:38:57PM +0100, Johannes Berg wrote:

> kmemdup? Might also make sense to not try the allocation if we're going
> to refuse it anyway, but that might be complicated to do and probably
> doesn't matter.

I did not know there is such a thing as kmemdup (apparently not that
many other people, either, taken into account it is not used anywhere in
the generic wireless code). Anyway, yes, it would work here.

Moving the allocation to be done for each subtype separately would add
quite a bit of extra code and error paths. Doing it once resulted in
simpler implementation. The array version was much simpler on this area,
but with separate variables for each subtype, I think it is better to
just allocate (and deal with NULL) once even if we will immediately
after this need to free the buffer in the case the request is going to
be refused.

-- 
Jouni Malinen                                            PGP id EFC895FA

  reply	other threads:[~2009-01-13 13:50 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-01-13 11:51 [PATCH] nl80211: New command for adding extra IE(s) into management frames Jouni Malinen
2009-01-13 13:38 ` Johannes Berg
2009-01-13 13:49   ` Jouni Malinen [this message]
2009-01-13 13:55     ` Johannes Berg
2009-01-13 14:03   ` [PATCHv2] " Jouni Malinen

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=20090113134948.GA16694@jm.kir.nu \
    --to=j@w1.fi \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=linville@tuxdriver.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox