1. 14 5月, 2015 19 次提交
  2. 13 5月, 2015 19 次提交
  3. 12 5月, 2015 2 次提交
    • A
      net: Add skb_free_frag to replace use of put_page in freeing skb->head · 181edb2b
      Alexander Duyck 提交于
      This change adds a function called skb_free_frag which is meant to
      compliment the function netdev_alloc_frag.  The general idea is to enable a
      more lightweight version of page freeing since we don't actually need all
      the overhead of a put_page, and we don't quite fit the model of __free_pages.
      Signed-off-by: NAlexander Duyck <alexander.h.duyck@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      181edb2b
    • A
      mm/net: Rename and move page fragment handling from net/ to mm/ · b63ae8ca
      Alexander Duyck 提交于
      This change moves the __alloc_page_frag functionality out of the networking
      stack and into the page allocation portion of mm.  The idea it so help make
      this maintainable by placing it with other page allocation functions.
      
      Since we are moving it from skbuff.c to page_alloc.c I have also renamed
      the basic defines and structure from netdev_alloc_cache to page_frag_cache
      to reflect that this is now part of a different kernel subsystem.
      
      I have also added a simple __free_page_frag function which can handle
      freeing the frags based on the skb->head pointer.  The model for this is
      based off of __free_pages since we don't actually need to deal with all of
      the cases that put_page handles.  I incorporated the virt_to_head_page call
      and compound_order into the function as it actually allows for a signficant
      size reduction by reducing code duplication.
      Signed-off-by: NAlexander Duyck <alexander.h.duyck@redhat.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      b63ae8ca