1. 11 10月, 2007 1 次提交
    • E
      [NET]: Make /proc/net per network namespace · 457c4cbc
      Eric W. Biederman 提交于
      This patch makes /proc/net per network namespace.  It modifies the global
      variables proc_net and proc_net_stat to be per network namespace.
      The proc_net file helpers are modified to take a network namespace argument,
      and all of their callers are fixed to pass &init_net for that argument.
      This ensures that all of the /proc/net files are only visible and
      usable in the initial network namespace until the code behind them
      has been updated to be handle multiple network namespaces.
      
      Making /proc/net per namespace is necessary as at least some files
      in /proc/net depend upon the set of network devices which is per
      network namespace, and even more files in /proc/net have contents
      that are relevant to a single network namespace.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      457c4cbc
  2. 11 7月, 2007 1 次提交
  3. 04 5月, 2007 1 次提交
  4. 26 4月, 2007 7 次提交
  5. 13 2月, 2007 1 次提交
  6. 11 2月, 2007 1 次提交
  7. 09 2月, 2007 1 次提交
  8. 24 1月, 2007 1 次提交
  9. 03 12月, 2006 3 次提交
  10. 23 9月, 2006 1 次提交
  11. 18 8月, 2006 1 次提交
  12. 01 7月, 2006 1 次提交
  13. 21 3月, 2006 1 次提交
  14. 08 2月, 2006 1 次提交
  15. 25 1月, 2006 1 次提交
    • D
      [IPV6] MLDv2: fix change records when transitioning to/from inactive · 7add2a43
      David L Stevens 提交于
      The following patch fixes these problems in MLDv2:
      
      1) Add/remove "delete" records for sending change reports when
              addition of a filter results in that filter transitioning to/from
              inactive. [same as recent IPv4 IGMPv3 fix]
      2) Remove 2 redundant "group_type" checks (can't be IPV6_ADDR_ANY
              within that loop, so checks are always true)
      3) change an is_in() "return 0" to "return type == MLD2_MODE_IS_INCLUDE".
              It should always be "0" to get here, but it improves code locality 
              to not assume it, and if some race allowed otherwise, doing
              the check would return the correct result.
      Signed-off-by: NDavid L Stevens <dlstevens@us.ibm.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      7add2a43
  16. 17 1月, 2006 1 次提交
  17. 14 1月, 2006 1 次提交
    • J
      [NET]: Use NIP6_FMT in kernel.h · 46b86a2d
      Joe Perches 提交于
      There are errors and inconsistency in the display of NIP6 strings.
      	ie: net/ipv6/ip6_flowlabel.c
      
      There are errors and inconsistency in the display of NIPQUAD strings too.
      	ie: net/netfilter/nf_conntrack_ftp.c
      
      This patch:
      	adds NIP6_FMT to kernel.h
      	changes all code to use NIP6_FMT
      	fixes net/ipv6/ip6_flowlabel.c
      	adds NIPQUAD_FMT to kernel.h
      	fixes net/netfilter/nf_conntrack_ftp.c
      	changes a few uses of "%u.%u.%u.%u" to NIPQUAD_FMT for symmetry to NIP6_FMT
      Signed-off-by: NJoe Perches <joe@perches.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      46b86a2d
  18. 12 1月, 2006 1 次提交
  19. 05 1月, 2006 1 次提交
  20. 28 12月, 2005 1 次提交
    • D
      [IPV6] mcast: Fix multiple issues in MLDv2 reports. · 5ab4a6c8
      David L Stevens 提交于
      The below "jumbo" patch fixes the following problems in MLDv2.
      
      1) Add necessary "ntohs" to recent "pskb_may_pull" check [breaks
              all nonzero source queries on little-endian (!)]
      
      2) Add locking to source filter list [resend of prior patch]
      
      3) fix "mld_marksources()" to
              a) send nothing when all queried sources are excluded
              b) send full exclude report when source queried sources are
                      not excluded
              c) don't schedule a timer when there's nothing to report
      
      NOTE: RFC 3810 specifies the source list should be saved and each
        source reported individually as an IS_IN. This is an obvious DOS
        path, requiring the host to store and then multicast as many sources
        as are queried (e.g., millions...). This alternative sends a full, 
        relevant report that's limited to number of sources present on the
        machine.
      
      4) fix "add_grec()" to send empty-source records when it should
              The original check doesn't account for a non-empty source
              list with all sources inactive; the new code keeps that
              short-circuit case, and also generates the group header
              with an empty list if needed.
      
      5) fix mca_crcount decrement to be after add_grec(), which needs
              its original value
      
      These issues (other than item #1 ;-) ) were all found by Yan Zheng,
      much thanks!
      Signed-off-by: NDavid L Stevens <dlstevens@us.ibm.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      5ab4a6c8
  21. 27 12月, 2005 1 次提交
  22. 03 12月, 2005 1 次提交
  23. 03 11月, 2005 1 次提交
    • Y
      [MCAST]: ip[6]_mc_add_src should be called when number of sources is zero · 8713dbf0
      Yan Zheng 提交于
      And filter mode is exclude.
      
      Further explanation by David Stevens:
      
      Multicast source filters aren't widely used yet, and that's really the only
      feature that's affected if an application actually exercises this bug, as far
      as I can tell. An ordinary filter-less multicast join should still work, and
      only forwarded multicast traffic making use of filters and doing empty-source
      filters with the MSFILTER ioctl would be at risk of not getting multicast
      traffic forwarded to them because the reports generated would not be based on
      the correct counts.
      
      Signed-off-by: Yan Zheng <yanzheng@21cn.com
      Acked-by: NDavid L Stevens <dlstevens@us.ibm.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@mandriva.com>
      8713dbf0
  24. 01 11月, 2005 1 次提交
  25. 29 10月, 2005 1 次提交
    • Y
      [MCAST] IPv6: Fix algorithm to compute Querier's Query Interval · f12baeab
      Yan Zheng 提交于
      5.1.3.  Maximum Response Code
      
         The Maximum Response Code field specifies the maximum time allowed
         before sending a responding Report.  The actual time allowed, called
         the Maximum Response Delay, is represented in units of milliseconds,
         and is derived from the Maximum Response Code as follows:
      
         If Maximum Response Code < 32768,
            Maximum Response Delay = Maximum Response Code
      
         If Maximum Response Code >=32768, Maximum Response Code represents a
         floating-point value as follows:
      
             0 1 2 3 4 5 6 7 8 9 A B C D E F
            +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
            |1| exp |          mant         |
            +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      
         Maximum Response Delay = (mant | 0x1000) << (exp+3)
      
      
      5.1.9.  QQIC (Querier's Query Interval Code)
      
         The Querier's Query Interval Code field specifies the [Query
         Interval] used by the Querier.  The actual interval, called the
         Querier's Query Interval (QQI), is represented in units of seconds,
         and is derived from the Querier's Query Interval Code as follows:
      
         If QQIC < 128, QQI = QQIC
      
         If QQIC >= 128, QQIC represents a floating-point value as follows:
      
             0 1 2 3 4 5 6 7
            +-+-+-+-+-+-+-+-+
            |1| exp | mant  |
            +-+-+-+-+-+-+-+-+
      
         QQI = (mant | 0x10) << (exp + 3)
      
                                                      -- rfc3810
      
      #define MLDV2_QQIC(value) MLDV2_EXP(0x80, 4, 3, value)
      #define MLDV2_MRC(value) MLDV2_EXP(0x8000, 12, 3, value)
      
      Above macro are defined in mcast.c. but 1 << 4 == 0x10 and 1 << 12 == 0x1000.
      So the result computed by original Macro is larger.
      Signed-off-by: NYan Zheng <yanzheng@21cn.com>
      Acked-by: NDavid L Stevens <dlstevens@us.ibm.com>
      Signed-off-by: NArnaldo Carvalho de Melo <acme@mandriva.com>
      f12baeab
  26. 06 10月, 2005 1 次提交
  27. 15 9月, 2005 1 次提交
  28. 09 7月, 2005 3 次提交
  29. 22 6月, 2005 2 次提交
    • P
      [NETFILTER]: Restore netfilter assumptions in IPv6 multicast · e9823185
      Patrick McHardy 提交于
      Netfilter assumes that skb->data == skb->nh.ipv6h
      Signed-off-by: NPatrick McHardy <kaber@trash.net>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      e9823185
    • D
      [IPV6]: multicast join and misc · c9e3e8b6
      David L Stevens 提交于
      Here is a simplified version of the patch to fix a bug in IPv6
      multicasting. It:
      
      1) adds existence check & EADDRINUSE error for regular joins
      2) adds an exception for EADDRINUSE in the source-specific multicast
              join (where a prior join is ok)
      3) adds a missing/needed read_lock on sock_mc_list; would've raced
              with destroying the socket on interface down without
      4) adds a "leave group" in the (INCLUDE, empty) source filter case.
              This frees unneeded socket buffer memory, but also prevents
              an inappropriate interaction among the 8 socket options that
              mess with this. Some would fail as if in the group when you
              aren't really.
      
      Item #4 had a locking bug in the last version of this patch; rather than
      removing the idev->lock read lock only, I've simplified it to remove
      all lock state in the path and treat it as a direct "leave group" call for
      the (INCLUDE,empty) case it covers. Tested on an MP machine. :-)
      
      Much thanks to HoerdtMickael <hoerdt@clarinet.u-strasbg.fr> who
      reported the original bug.
      Signed-off-by: NDavid L Stevens <dlstevens@us.ibm.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c9e3e8b6