1. 30 Aug, 2013 8 commits
  2. 29 Aug, 2013 5 commits
    • David S. Miller's avatar
      Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/klassert/ipsec · 79f9ab7e
      David S. Miller authored
      Steffen Klassert says:
      
      ====================
      This pull request fixes some issues that arise when 6in4 or 4in6 tunnels
      are used in combination with IPsec, all from Hannes Frederic Sowa and a
      null pointer dereference when queueing packets to the policy hold queue.
      
      1) We might access the local error handler of the wrong address family if
         6in4 or 4in6 tunnel is protected by ipsec. Fix this by addind a pointer
         to the correct local_error to xfrm_state_afinet.
      
      2) Add a helper function to always refer to the correct interpretation
         of skb->sk.
      
      3) Call skb_reset_inner_headers to record the position of the inner headers
         when adding a new one in various ipv6 tunnels. This is needed to identify
         the addresses where to send back errors in the xfrm layer.
      
      4) Dereference inner ipv6 header if encapsulated to always call the
         right error handler.
      
      5) Choose protocol family by skb protocol to not call the wrong
         xfrm{4,6}_local_error handler in case an ipv6 sockets is used
         in ipv4 mode.
      
      6) Partly revert "xfrm: introduce helper for safe determination of mtu"
         because this introduced pmtu discovery problems.
      
      7) Set skb->protocol on tcp, raw and ip6_append_data genereated skbs.
         We need this to get the correct mtu informations in xfrm.
      
      8) Fix null pointer dereference in xdst_queue_output.
      ====================
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      79f9ab7e
    • Thomas Graf's avatar
      ipv6: Don't depend on per socket memory for neighbour discovery messages · 1f324e38
      Thomas Graf authored
      Allocating skbs when sending out neighbour discovery messages
      currently uses sock_alloc_send_skb() based on a per net namespace
      socket and thus share a socket wmem buffer space.
      
      If a netdevice is temporarily unable to transmit due to carrier
      loss or for other reasons, the queued up ndisc messages will cosnume
      all of the wmem space and will thus prevent from any more skbs to
      be allocated even for netdevices that are able to transmit packets.
      
      The number of neighbour discovery messages sent is very limited,
      simply use alloc_skb() and don't depend on any socket wmem space any
      longer.
      
      This patch has orginally been posted by Eric Dumazet in a modified
      form.
      Signed-off-by: default avatarThomas Graf <tgraf@suug.ch>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Acked-by: default avatarHannes Frederic Sowa <hannes@stressinduktion.org>
      Acked-by: default avatarEric Dumazet <edumazet@google.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1f324e38
    • Chris Clark's avatar
      ipv4: sendto/hdrincl: don't use destination address found in header · c27c9322
      Chris Clark authored
      ipv4: raw_sendmsg: don't use header's destination address
      
      A sendto() regression was bisected and found to start with commit
      f8126f1d (ipv4: Adjust semantics of rt->rt_gateway.)
      
      The problem is that it tries to ARP-lookup the constructed packet's
      destination address rather than the explicitly provided address.
      
      Fix this using FLOWI_FLAG_KNOWN_NH so that given nexthop is used.
      
      cf. commit 2ad5b9e4Reported-by: default avatarChris Clark <chris.clark@alcatel-lucent.com>
      Bisected-by: default avatarChris Clark <chris.clark@alcatel-lucent.com>
      Tested-by: default avatarChris Clark <chris.clark@alcatel-lucent.com>
      Suggested-by: default avatarJulian Anastasov <ja@ssi.bg>
      Signed-off-by: default avatarChris Clark <chris.clark@alcatel-lucent.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c27c9322
    • Andrew Vagin's avatar
      tcp: don't apply tsoffset if rcv_tsecr is zero · e3e12028
      Andrew Vagin authored
      The zero value means that tsecr is not valid, so it's a special case.
      
      tsoffset is used to customize tcp_time_stamp for one socket.
      tsoffset is usually zero, it's used when a socket was moved from one
      host to another host.
      
      Currently this issue affects logic of tcp_rcv_rtt_measure_ts. Due to
      incorrect value of rcv_tsecr, tcp_rcv_rtt_measure_ts sets rto to
      TCP_RTO_MAX.
      
      Cc: Pavel Emelyanov <xemul@parallels.com>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
      Cc: James Morris <jmorris@namei.org>
      Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
      Cc: Patrick McHardy <kaber@trash.net>
      Reported-by: default avatarCyrill Gorcunov <gorcunov@openvz.org>
      Signed-off-by: default avatarAndrey Vagin <avagin@openvz.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e3e12028
    • Andrew Vagin's avatar
      tcp: initialize rcv_tstamp for restored sockets · c7781a6e
      Andrew Vagin authored
      u32 rcv_tstamp;     /* timestamp of last received ACK */
      
      Its value used in tcp_retransmit_timer, which closes socket
      if the last ack was received more then TCP_RTO_MAX ago.
      
      Currently rcv_tstamp is initialized to zero and if tcp_retransmit_timer
      is called before receiving a first ack, the connection is closed.
      
      This patch initializes rcv_tstamp to a timestamp, when a socket was
      restored.
      
      Cc: Pavel Emelyanov <xemul@parallels.com>
      Cc: Eric Dumazet <eric.dumazet@gmail.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>
      Cc: James Morris <jmorris@namei.org>
      Cc: Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>
      Cc: Patrick McHardy <kaber@trash.net>
      Reported-by: default avatarCyrill Gorcunov <gorcunov@openvz.org>
      Signed-off-by: default avatarAndrey Vagin <avagin@openvz.org>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      c7781a6e
  3. 28 Aug, 2013 12 commits
  4. 27 Aug, 2013 6 commits
  5. 26 Aug, 2013 3 commits
  6. 23 Aug, 2013 6 commits
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 41a00f79
      Linus Torvalds authored
      Merge networking fixes from David Miller:
      
       1) Revert Johannes Berg's genetlink locking fix, because it causes
          regressions.
      
          Johannes and Pravin Shelar are working on fixing things properly.
      
       2) Do not drop ipv6 ICMP messages without a redirected header option,
          they are legal.  From Duan Jiong.
      
       3) Missing error return propagation in probing of via-ircc driver.
          From Alexey Khoroshilov.
      
       4) Do not clear out broadcast/multicast/unicast/WOL bits in r8169 when
          initializing, from Peter Wu.
      
       5) realtek phy driver programs wrong interrupt status bit, from
          Giuseppe CAVALLARO.
      
       6) Fix statistics regression in AF_PACKET code, from Willem de Bruijn.
      
       7) Bridge code uses wrong bitmap length, from Toshiaki Makita.
      
       8) SFC driver uses wrong indexes to look up MAC filters, from Ben
          Hutchings.
      
       9) Don't pass stack buffers into usb control operations in hso driver,
          from Daniel Gimpelevich.
      
      10) Multiple ipv6 fragmentation headers in one packet is illegal and
          such packets should be dropped, from Hannes Frederic Sowa.
      
      11) When TCP sockets are "repaired" as part of checkpoint/restart, the
          timestamp field of SKBs need to be refreshed otherwise RTOs can be
          wildly off.  From Andrey Vagin.
      
      12) Fix memcpy args (uses 'address of pointer' instead of 'pointer') in
          hostp driver.  From Dan Carpenter.
      
      13) nl80211hdr_put() doesn't return an ERR_PTR, but some code believes
          it does.  From Dan Carpenter.
      
      14) Fix regression in wireless SME disconnects, from Johannes Berg.
      
      15) Don't use a stack buffer for DMA in zd1201 USB wireless driver, from
          Jussi Kivilinna.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (33 commits)
        ipv4: expose IPV4_DEVCONF
        ipv6: handle Redirect ICMP Message with no Redirected Header option
        be2net: fix disabling TX in be_close()
        Revert "genetlink: fix family dump race"
        hso: Fix stack corruption on some architectures
        hso: Earlier catch of error condition
        sfc: Fix lookup of default RX MAC filters when steered using ethtool
        bridge: Use the correct bit length for bitmap functions in the VLAN code
        packet: restore packet statistics tp_packets to include drops
        net: phy: rtl8211: fix interrupt on status link change
        r8169: remember WOL preferences on driver load
        via-ircc: don't return zero if via_ircc_open() failed
        macvtap: Ignore tap features when VNET_HDR is off
        macvtap: Correctly set tap features when IFF_VNET_HDR is disabled.
        macvtap: simplify usage of tap_features
        tcp: set timestamps for restored skb-s
        bnx2x: set VF DMAE when first function has 0 supported VFs
        bnx2x: Protect against VFs' ndos when SR-IOV is disabled
        bnx2x: prevent VF benign attentions
        bnx2x: Consider DCBX remote error
        ...
      41a00f79
    • Linus Torvalds's avatar
      Merge branch 'akpm' (patches from Andrew Morton) · 3db0d4de
      Linus Torvalds authored
      Merge fixes from Andrew Morton:
       "A few fixes.  One is a licensing change and I don't do licensing, so
        please eyeball that one"
      
      Licensing eye-balled.
      
      * emailed patches from Andrew Morton <akpm@linux-foundation.org>:
        lib/lz4: correct the LZ4 license
        memcg: get rid of swapaccount leftovers
        nilfs2: fix issue with counting number of bio requests for BIO_EOPNOTSUPP error detection
        nilfs2: remove double bio_put() in nilfs_end_bio_write() for BIO_EOPNOTSUPP error
        drivers/platform/olpc/olpc-ec.c: initialise earlier
      3db0d4de
    • Richard Laager's avatar
      lib/lz4: correct the LZ4 license · ee8a99bd
      Richard Laager authored
      The LZ4 code is listed as using the "BSD 2-Clause License".
      Signed-off-by: default avatarRichard Laager <rlaager@wiktel.com>
      Acked-by: default avatarKyungsik Lee <kyungsik.lee@lge.com>
      Cc: Chanho Min <chanho.min@lge.com>
      Cc: Richard Yao <ryao@gentoo.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      [ The 2-clause BSD can be just converted into GPL, but that's rude and
        pointless, so don't do it   - Linus ]
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      ee8a99bd
    • Michal Hocko's avatar
      memcg: get rid of swapaccount leftovers · 07555ac1
      Michal Hocko authored
      The swapaccount kernel parameter without any values has been removed by
      commit a2c8990a ("memsw: remove noswapaccount kernel parameter") but
      it seems that we didn't get rid of all the left overs.
      
      Make sure that menuconfig help text and kernel-parameters.txt are clear
      about value for the paramter and remove the stalled comment which is not
      very much useful on its own.
      Signed-off-by: default avatarMichal Hocko <mhocko@suse.cz>
      Reported-by: default avatarGergely Risko <gergely@risko.hu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      07555ac1
    • Vyacheslav Dubeyko's avatar
      nilfs2: fix issue with counting number of bio requests for BIO_EOPNOTSUPP error detection · 4bf93b50
      Vyacheslav Dubeyko authored
      Fix the issue with improper counting number of flying bio requests for
      BIO_EOPNOTSUPP error detection case.
      
      The sb_nbio must be incremented exactly the same number of times as
      complete() function was called (or will be called) because
      nilfs_segbuf_wait() will call wail_for_completion() for the number of
      times set to sb_nbio:
      
        do {
            wait_for_completion(&segbuf->sb_bio_event);
        } while (--segbuf->sb_nbio > 0);
      
      Two functions complete() and wait_for_completion() must be called the
      same number of times for the same sb_bio_event.  Otherwise,
      wait_for_completion() will hang or leak.
      Signed-off-by: default avatarVyacheslav Dubeyko <slava@dubeyko.com>
      Cc: Dan Carpenter <dan.carpenter@oracle.com>
      Acked-by: default avatarRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
      Tested-by: default avatarRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      4bf93b50
    • Vyacheslav Dubeyko's avatar
      nilfs2: remove double bio_put() in nilfs_end_bio_write() for BIO_EOPNOTSUPP error · 2df37a19
      Vyacheslav Dubeyko authored
      Remove double call of bio_put() in nilfs_end_bio_write() for the case of
      BIO_EOPNOTSUPP error detection.  The issue was found by Dan Carpenter
      and he suggests first version of the fix too.
      Signed-off-by: default avatarVyacheslav Dubeyko <slava@dubeyko.com>
      Reported-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Acked-by: default avatarRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
      Tested-by: default avatarRyusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      2df37a19