linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Johannes Berg <johannes@sipsolutions.net>
To: Joe Perches <joe@perches.com>,
	Arend van Spriel <arend.vanspriel@broadcom.com>,
	linux-wireless@vger.kernel.org
Subject: Re: [RFC] networking: add and use skb_put_u8()
Date: Fri, 16 Jun 2017 14:26:15 +0200	[thread overview]
Message-ID: <1497615975.2622.11.camel@sipsolutions.net> (raw)
In-Reply-To: <1497614684.10546.9.camel@perches.com>

On Fri, 2017-06-16 at 05:04 -0700, Joe Perches wrote:
> 
> Perhaps
> 
> 	skb_put_data(skb, &c, sizeof(c))
> 
> as that avoids api expansion.

Doing this means putting c on the stack first in many places so a
pointer can be taken, which isn't nice.

> Optimizing the indirections and the size in a macro front-end
> in skb_put_data may be better as it's would be completely
> consistent for all use styles.

Well, you'd still have to worry about aligned/unaligned for anything
bigger than 1 byte, so ...

My bikeshedding on this is over, I'll send out all these (now 6)
patches again once I have a build result from the 0-day bot, and unless
Dave wants to have specific changes I've already spent enough time.

johannes

  reply	other threads:[~2017-06-16 12:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-16  9:03 [RFC] networking: add and use skb_put_u8() Johannes Berg
2017-06-16 10:16 ` Arend van Spriel
2017-06-16 10:22   ` Johannes Berg
2017-06-16 12:04     ` Joe Perches
2017-06-16 12:26       ` Johannes Berg [this message]
2017-06-16 12:42       ` Joe Perches

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=1497615975.2622.11.camel@sipsolutions.net \
    --to=johannes@sipsolutions.net \
    --cc=arend.vanspriel@broadcom.com \
    --cc=joe@perches.com \
    --cc=linux-wireless@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).