1. 22 6月, 2005 5 次提交
    • M
      [PATCH] VM: early zone reclaim · 753ee728
      Martin Hicks 提交于
      This is the core of the (much simplified) early reclaim.  The goal of this
      patch is to reclaim some easily-freed pages from a zone before falling back
      onto another zone.
      
      One of the major uses of this is NUMA machines.  With the default allocator
      behavior the allocator would look for memory in another zone, which might be
      off-node, before trying to reclaim from the current zone.
      
      This adds a zone tuneable to enable early zone reclaim.  It is selected on a
      per-zone basis and is turned on/off via syscall.
      
      Adding some extra throttling on the reclaim was also required (patch
      4/4).  Without the machine would grind to a crawl when doing a "make -j"
      kernel build.  Even with this patch the System Time is higher on
      average, but it seems tolerable.  Here are some numbers for kernbench
      runs on a 2-node, 4cpu, 8Gig RAM Altix in the "make -j" run:
      
      			wall  user   sys   %cpu  ctx sw.  sleeps
      			----  ----   ---   ----   ------  ------
      No patch		1009  1384   847   258   298170   504402
      w/patch, no reclaim     880   1376   667   288   254064   396745
      w/patch & reclaim       1079  1385   926   252   291625   548873
      
      These numbers are the average of 2 runs of 3 "make -j" runs done right
      after system boot.  Run-to-run variability for "make -j" is huge, so
      these numbers aren't terribly useful except to seee that with reclaim
      the benchmark still finishes in a reasonable amount of time.
      
      I also looked at the NUMA hit/miss stats for the "make -j" runs and the
      reclaim doesn't make any difference when the machine is thrashing away.
      
      Doing a "make -j8" on a single node that is filled with page cache pages
      takes 700 seconds with reclaim turned on and 735 seconds without reclaim
      (due to remote memory accesses).
      
      The simple zone_reclaim syscall program is at
      http://www.bork.org/~mort/sgi/zone_reclaim.cSigned-off-by: NMartin Hicks <mort@sgi.com>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      753ee728
    • I
      [PATCH] smp_processor_id() cleanup · 39c715b7
      Ingo Molnar 提交于
      This patch implements a number of smp_processor_id() cleanup ideas that
      Arjan van de Ven and I came up with.
      
      The previous __smp_processor_id/_smp_processor_id/smp_processor_id API
      spaghetti was hard to follow both on the implementational and on the
      usage side.
      
      Some of the complexity arose from picking wrong names, some of the
      complexity comes from the fact that not all architectures defined
      __smp_processor_id.
      
      In the new code, there are two externally visible symbols:
      
       - smp_processor_id(): debug variant.
      
       - raw_smp_processor_id(): nondebug variant. Replaces all existing
         uses of _smp_processor_id() and __smp_processor_id(). Defined
         by every SMP architecture in include/asm-*/smp.h.
      
      There is one new internal symbol, dependent on DEBUG_PREEMPT:
      
       - debug_smp_processor_id(): internal debug variant, mapped to
                                   smp_processor_id().
      
      Also, i moved debug_smp_processor_id() from lib/kernel_lock.c into a new
      lib/smp_processor_id.c file.  All related comments got updated and/or
      clarified.
      
      I have build/boot tested the following 8 .config combinations on x86:
      
       {SMP,UP} x {PREEMPT,!PREEMPT} x {DEBUG_PREEMPT,!DEBUG_PREEMPT}
      
      I have also build/boot tested x64 on UP/PREEMPT/DEBUG_PREEMPT.  (Other
      architectures are untested, but should work just fine.)
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      Signed-off-by: NArjan van de Ven <arjan@infradead.org>
      Signed-off-by: NAndrew Morton <akpm@osdl.org>
      Signed-off-by: NLinus Torvalds <torvalds@osdl.org>
      39c715b7
    • P
      [NETFILTER]: Kill nf_debug · 18b8afc7
      Patrick McHardy 提交于
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      18b8afc7
    • P
      [NETFILTER]: Kill lockhelp.h · e45b1be8
      Patrick McHardy 提交于
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e45b1be8
    • A
      [NETLINK]: netlink_callback structure needs 5 args not 4 · 18b504e2
      Alexey Kuznetsov 提交于
      net/ipv4/tcp_diag.c uses up to ->args[4]
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      18b504e2
  2. 21 6月, 2005 29 次提交
  3. 19 6月, 2005 6 次提交
    • H
      [IPSEC]: Add XFRMA_SA/XFRMA_POLICY for delete notification · 0603eac0
      Herbert Xu 提交于
      This patch changes the format of the XFRM_MSG_DELSA and
      XFRM_MSG_DELPOLICY notification so that the main message
      sent is of the same format as that received by the kernel
      if the original message was via netlink.  This also means
      that we won't lose the byid information carried in km_event.
      
      Since this user interface is introduced by Jamal's patch
      we can still afford to change it.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      0603eac0
    • T
      [NETLINK]: Introduce NLMSG_NEW macro to better handle netlink flags · 1797754e
      Thomas Graf 提交于
      Introduces a new macro NLMSG_NEW which extends NLMSG_PUT but takes
      a flags argument. NLMSG_PUT stays there for compatibility but now
      calls NLMSG_NEW with flags == 0. NLMSG_PUT_ANSWER is renamed to
      NLMSG_NEW_ANSWER which now also takes a flags argument.
      
      Also converts the users of NLMSG_PUT_ANSWER to use NLMSG_NEW_ANSWER
      and fixes the two direct users of __nlmsg_put to either provide
      the flags or use NLMSG_NEW(_ANSWER).
      Signed-off-by: NThomas Graf <tgraf@suug.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      1797754e
    • T
      8f48bcd4
    • T
      [NETLINK]: Fix RTA_NEST_CANCEL(). · c52a3f89
      Thomas Graf 提交于
      Only skb_trim() if 'start' is non-NULL.
      Signed-off-by: NThomas Graf <tgraf@suug.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c52a3f89
    • T
      [NETLINK]: Neighbour table configuration and statistics via rtnetlink · c7fb64db
      Thomas Graf 提交于
      To retrieve the neighbour tables send RTM_GETNEIGHTBL with the
      NLM_F_DUMP flag set. Every neighbour table configuration is
      spread over multiple messages to avoid running into message
      size limits on systems with many interfaces. The first message
      in the sequence transports all not device specific data such as
      statistics, configuration, and the default parameter set.
      This message is followed by 0..n messages carrying device
      specific parameter sets.
      
      Although the ordering should be sufficient, NDTA_NAME can be
      used to identify sequences. The initial message can be identified
      by checking for NDTA_CONFIG. The device specific messages do
      not contain this TLV but have NDTPA_IFINDEX set to the
      corresponding interface index.
      
      To change neighbour table attributes, send RTM_SETNEIGHTBL
      with NDTA_NAME set. Changeable attribute include NDTA_THRESH[1-3],
      NDTA_GC_INTERVAL, and all TLVs in NDTA_PARMS unless marked
      otherwise. Device specific parameter sets can be changed by
      setting NDTPA_IFINDEX to the interface index of the corresponding
      device.
      Signed-off-by: NThomas Graf <tgraf@suug.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c7fb64db
    • T
      [NETLINK] Routing attribute related shortcuts · 00768244
      Thomas Graf 提交于
       RTA_GET_U(32|64)(tlv)
         Assumes TLV is a u32/u64 field and returns its value.
      
       RTA_GET_[M]SECS(tlv)
         Assumes TLV is a u64 and transports jiffies converted
         to seconds or milliseconds and returns its value.
      
       RTA_PUT_U(32|64)(skb, type, value)
         Appends %value as fixed u32/u64 to %skb as TLV %type.
      
       RTA_PUT_[M]SECS(skb, type, jiffies)
         Converts %jiffies to secs/msecs and appends it as u64
         to %skb as TLV %type.
      
       RTA_PUT_STRING(skb, type, string)
         Appends %NUL terminated %string to %skb as TLV %type.
      
       RTA_NEST(skb, type)
         Starts a nested TLV %type and returns the nesting handle.
      
       RTA_NEST_END(skb, nesting_handle)
         Finishes the nested TLV %nesting_handle, must be called
         symmetric to RTA_NEST(). Returns skb->len
      
       RTA_NEST_CANCEL(skb, nesting_handle)
         Cancel the nested TLV %nesting_handle and trim nested TLV
         from skb again, returns -1.
      Signed-off-by: NThomas Graf <tgraf@suug.ch>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      00768244