Netdev List
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: kaber@trash.net
Cc: davem@davemloft.net, netfilter-devel@vger.kernel.org,
	netdev@vger.kernel.org
Subject: Re: [PATCH 02/11] net: add function to allocate skbuff head without data area
Date: Sun, 04 Sep 2011 10:12:18 +0200	[thread overview]
Message-ID: <1315123938.2635.1.camel@edumazet-laptop> (raw)
In-Reply-To: <1315070771-18576-3-git-send-email-kaber@trash.net>

Le samedi 03 septembre 2011 à 19:26 +0200, kaber@trash.net a écrit :

> +struct sk_buff *__alloc_skb_head(gfp_t gfp_mask, int node)
> +{
> +	struct sk_buff *skb;
> +
> +	/* Get the HEAD */
> +	skb = kmem_cache_alloc_node(skbuff_head_cache,
> +				    gfp_mask & ~__GFP_DMA, node);
> +	if (!skb)
> +		goto out;
> +	prefetchw(skb);

Please remove this prefetchw(), since we have no delay between it and
actual memset(skb).

> +
> +	/*
> +	 * Only clear those fields we need to clear, not those that we will
> +	 * actually initialise below. Hence, don't put any more fields after
> +	 * the tail pointer in struct sk_buff!
> +	 */
> +	memset(skb, 0, offsetof(struct sk_buff, tail));



--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2011-09-04  8:12 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-03 17:26 [PATCH RFC 0/11] netlink: memory mapped I/O kaber
2011-09-03 17:26 ` [PATCH 01/11] netlink: add symbolic value for congested state kaber
2011-09-03 17:26 ` [PATCH 02/11] net: add function to allocate skbuff head without data area kaber
2011-09-04  8:12   ` Eric Dumazet [this message]
2011-09-07 15:20     ` Patrick McHardy
2011-09-03 17:26 ` [PATCH 03/11] netlink: add helper function for queueing skbs to the receive queue kaber
2011-09-03 17:26 ` [PATCH 04/11] netlink: don't orphan skb in netlink_trim() kaber
2011-09-03 17:26 ` [PATCH 05/11] netlink: add netlink_skb_set_owner_r() kaber
2011-09-03 17:26 ` [PATCH 06/11] netlink: memory mapped netlink: ring setup kaber
2011-09-03 17:26 ` [PATCH 07/11] netlink: add memory mapped netlink helper functions kaber
2011-09-03 17:26 ` [PATCH 08/11] netlink: implement memory mapped sendmsg() kaber
2011-09-04 16:18   ` Michał Mirosław
2011-09-07 15:22     ` Patrick McHardy
2011-09-07 20:03       ` Michał Mirosław
2011-09-08  9:33         ` Patrick McHardy
2011-09-08 18:08           ` Michał Mirosław
2011-09-03 17:26 ` [PATCH 09/11] netlink: implement memory mapped recvmsg() kaber
2011-09-03 17:26 ` [PATCH 10/11] netlink: add documentation for memory mapped I/O kaber
2011-09-03 17:26 ` [PATCH 11/11] nfnetlink: add support for memory mapped netlink kaber
2011-09-17  5:48 ` [PATCH RFC 0/11] netlink: memory mapped I/O David Miller
  -- strict thread matches above, loose matches on Subject: below --
2012-08-20  6:18 [PATCH 00/11] " Patrick McHardy
2012-08-20  6:18 ` [PATCH 02/11] net: add function to allocate skbuff head without data area Patrick McHardy
2012-08-20  6:39   ` Eric Dumazet
2012-08-20  6:41     ` Patrick McHardy

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=1315123938.2635.1.camel@edumazet-laptop \
    --to=eric.dumazet@gmail.com \
    --cc=davem@davemloft.net \
    --cc=kaber@trash.net \
    --cc=netdev@vger.kernel.org \
    --cc=netfilter-devel@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