1. 05 Dec, 2016 3 commits
    • Guenter Roeck's avatar
      usb: hub: Wait for connection to be reestablished after port reset · 22547c4c
      Guenter Roeck authored
      On a system with a defective USB device connected to an USB hub,
      an endless sequence of port connect events was observed. The sequence
      of events as observed is as follows:
      
      - Port reports connected event (port status=USB_PORT_STAT_CONNECTION).
      - Event handler debounces port and resets it by calling hub_port_reset().
      - hub_port_reset() calls hub_port_wait_reset() to wait for the reset
        to complete.
      - The reset completes, but USB_PORT_STAT_CONNECTION is not immediately
        set in the port status register.
      - hub_port_wait_reset() returns -ENOTCONN.
      - Port initialization sequence is aborted.
      - A few milliseconds later, the port again reports a connected event,
        and the sequence repeats.
      
      This continues either forever or, randomly, stops if the connection
      is already re-established when the port status is read. It results in
      a high rate of udev events. This in turn destabilizes userspace since
      the above sequence holds the device mutex pretty much continuously
      and prevents userspace from actually reading the device status.
      
      To prevent the problem from happening, let's wait for the connection
      to be re-established after a port reset. If the device was actually
      disconnected, the code will still return an error, but it will do so
      only after the long reset timeout.
      
      Cc: Douglas Anderson <dianders@chromium.org>
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Acked-by: default avatarAlan Stern <stern@rowland.harvard.edu>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      22547c4c
    • Krzysztof Opasiak's avatar
      usbip: vudc: Refactor init_vudc_hw() to be more obvious · b282a118
      Krzysztof Opasiak authored
      Current implementation of init_vudc_hw() adds ep0 to ep_list
      and then after looping through all endpoints removes it from
      that list.
      
      As this may be misleading let's refactor this function
      and avoid adding and removing ep0 to eplist and place it
      immediately in correct place.
      
      In addition let's remove redundant 0 assignments as ep
      array is zeroed during allocation.
      Signed-off-by: default avatarKrzysztof Opasiak <k.opasiak@samsung.com>
      Acked-by: default avatarShuah Khan <shuahkh@osg.samsung.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      b282a118
    • Krzysztof Opasiak's avatar
      usbip: vudc: fix: Clear already_seen flag also for ep0 · 3e448e13
      Krzysztof Opasiak authored
      ep_list inside gadget structure doesn't contain ep0.
      It is stored separately in ep0 field.
      
      This causes an urb hang if gadget driver decides to
      delay setup handling. On host side this is visible as
      timeout error when setting configuration.
      
      This bug can be reproduced using for example any gadget
      with mass storage function.
      
      Fixes: abdb2957 ("usbip: vudc: Add vudc_transfer")
      Signed-off-by: default avatarKrzysztof Opasiak <k.opasiak@samsung.com>
      Cc: stable <stable@vger.kernel.org>
      Acked-by: default avatarShuah Khan <shuahkh@osg.samsung.com>
      Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
      3e448e13
  2. 01 Dec, 2016 1 commit
  3. 30 Nov, 2016 2 commits
  4. 29 Nov, 2016 13 commits
  5. 28 Nov, 2016 4 commits
  6. 27 Nov, 2016 5 commits
  7. 26 Nov, 2016 12 commits
    • Linus Torvalds's avatar
      Merge branch 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux · e3480312
      Linus Torvalds authored
      Pull i2c fixes from Wolfram Sang:
       "Here is a revert and two bugfixes for the I2C designware driver.
      
        Please note that we are still hunting down a regression for the
        i2c-octeon driver. While there is a fix pending, we have unclear
        feedback from the testers currently. An rc8 would be quite helpful
        for this case"
      
      * 'i2c/for-current' of git://git.kernel.org/pub/scm/linux/kernel/git/wsa/linux:
        Revert "i2c: designware: do not disable adapter after transfer"
        i2c: designware: fix rx fifo depth tracking
        i2c: designware: report short transfers
      e3480312
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm · a56f3eb2
      Linus Torvalds authored
      Pull ARM fix from Russell King:
       "This resolves the ksyms issues by reverting the commit which
        introduced the breakage"
      
      There was what I consider to be a better fix, but it's late in the rc
      game, so I'll take the revert.
      
      * 'fixes' of git://git.armlinux.org.uk/~rmk/linux-arm:
        Revert "arm: move exports to definitions"
      a56f3eb2
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · a0d60e62
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) Fix leak in fsl/fman driver, from Dan Carpenter.
      
       2) Call flow dissector initcall earlier than any networking driver can
          register and start to use it, from Eric Dumazet.
      
       3) Some dup header fixes from Geliang Tang.
      
       4) TIPC link monitoring compat fix from Jon Paul Maloy.
      
       5) Link changes require EEE re-negotiation in bcm_sf2 driver, from
          Florian Fainelli.
      
       6) Fix bogus handle ID passed into tfilter_notify_chain(), from Roman
          Mashak.
      
       7) Fix dump size calculation in rtnl_calcit(), from Zhang Shengju.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (26 commits)
        tipc: resolve connection flow control compatibility problem
        mvpp2: use correct size for memset
        net/mlx5: drop duplicate header delay.h
        net: ieee802154: drop duplicate header delay.h
        ibmvnic: drop duplicate header seq_file.h
        fsl/fman: fix a leak in tgec_free()
        net: ethtool: don't require CAP_NET_ADMIN for ETHTOOL_GLINKSETTINGS
        tipc: improve sanity check for received domain records
        tipc: fix compatibility bug in link monitoring
        net: ethernet: mvneta: Remove IFF_UNICAST_FLT which is not implemented
        dwc_eth_qos: drop duplicate headers
        net sched filters: fix filter handle ID in tfilter_notify_chain()
        net: dsa: bcm_sf2: Ensure we re-negotiate EEE during after link change
        bnxt: do not busy-poll when link is down
        udplite: call proper backlog handlers
        ipv6: bump genid when the IFA_F_TENTATIVE flag is clear
        net/mlx4_en: Free netdev resources under state lock
        net: revert "net: l2tp: Treat NET_XMIT_CN as success in l2tp_eth_dev_xmit"
        rtnetlink: fix the wrong minimal dump size getting from rtnl_calcit()
        bnxt_en: Fix a VXLAN vs GENEVE issue
        ...
      a0d60e62
    • Linus Torvalds's avatar
      Merge branch 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm · 30e2b7cf
      Linus Torvalds authored
      Pull libnvdimm fixes from Dan Williams:
      
       - Fix a crash that occurs at driver initialization if the memory region
         is already busy (request_mem_region() fails).
      
       - Fix a vma validation check that mistakenly allows a private device-
         dax mapping to be established. Device-dax explicitly forbids private
         mappings so it can guarantee a given fault granularity and backing
         memory type.
      
       Both of these fixes have soaked in -next and are tagged for -stable.
      
      * 'libnvdimm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/nvdimm/nvdimm:
        device-dax: fail all private mapping attempts
        device-dax: check devm_nsio_enable() return value
      30e2b7cf
    • Linus Torvalds's avatar
      Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm · fc13ca19
      Linus Torvalds authored
      Pull KVM fixes from Radim Krčmář:
       "Four fixes for bugs found by syzkaller on x86, all for stable"
      
      * tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
        KVM: x86: check for pic and ioapic presence before use
        KVM: x86: fix out-of-bounds accesses of rtc_eoi map
        KVM: x86: drop error recovery in em_jmp_far and em_ret_far
        KVM: x86: fix out-of-bounds access in lapic
      fc13ca19
    • Linus Torvalds's avatar
      Merge tag 'powerpc-4.9-6' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux · 39c15737
      Linus Torvalds authored
      Pull powerpc fixes from Michael Ellerman:
       "Fixes marked for stable:
         - Set missing wakeup bit in LPCR on POWER9
         - Fix the early OPAL console wrappers
         - Fixup kernel read only mapping
      
        Fixes for code merged this cycle:
         - Fix missing CRCs, add more asm-prototypes.h declarations"
      
      * tag 'powerpc-4.9-6' of git://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux:
        powerpc/mm: Fixup kernel read only mapping
        powerpc/boot: Fix the early OPAL console wrappers
        powerpc: Fix missing CRCs, add more asm-prototypes.h declarations
        powerpc: Set missing wakeup bit in LPCR on POWER9
      39c15737
    • Jon Paul Maloy's avatar
      tipc: resolve connection flow control compatibility problem · 6998cc6e
      Jon Paul Maloy authored
      In commit 10724cc7 ("tipc: redesign connection-level flow control")
      we replaced the previous message based flow control with one based on
      1k blocks. In order to ensure backwards compatibility the mechanism
      falls back to using message as base unit when it senses that the peer
      doesn't support the new algorithm. The default flow control window,
      i.e., how many units can be sent before the sender blocks and waits
      for an acknowledge (aka advertisement) is 512. This was tested against
      the previous version, which uses an acknowledge frequency of on ack per
      256 received message, and found to work fine.
      
      However, we missed the fact that versions older than Linux 3.15 use an
      acknowledge frequency of 512, which is exactly the limit where a 4.6+
      sender will stop and wait for acknowledge. This would also work fine if
      it weren't for the fact that if the first sent message on a 4.6+ server
      side is an empty SYNACK, this one is also is counted as a sent message,
      while it is not counted as a received message on a legacy 3.15-receiver.
      This leads to the sender always being one step ahead of the receiver, a
      scenario causing the sender to block after 512 sent messages, while the
      receiver only has registered 511 read messages. Hence, the legacy
      receiver is not trigged to send an acknowledge, with a permanently
      blocked sender as result.
      
      We solve this deadlock by simply allowing the sender to send one more
      message before it blocks, i.e., by a making minimal change to the
      condition used for determining connection congestion.
      Signed-off-by: default avatarJon Maloy <jon.maloy@ericsson.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      6998cc6e
    • Arnd Bergmann's avatar
      mvpp2: use correct size for memset · e8f967c3
      Arnd Bergmann authored
      gcc-7 detects a short memset in mvpp2, introduced in the original
      merge of the driver:
      
      drivers/net/ethernet/marvell/mvpp2.c: In function 'mvpp2_cls_init':
      drivers/net/ethernet/marvell/mvpp2.c:3296:2: error: 'memset' used with length equal to number of elements without multiplication by element size [-Werror=memset-elt-size]
      
      The result seems to be that we write uninitialized data into the
      flow table registers, although we did not get any warning about
      that uninitialized data usage.
      
      Using sizeof() lets us initialize then entire array instead.
      
      Fixes: 3f518509 ("ethernet: Add new driver for Marvell Armada 375 network unit")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      e8f967c3
    • Geliang Tang's avatar
      net/mlx5: drop duplicate header delay.h · 5e7dfeb7
      Geliang Tang authored
      Drop duplicate header delay.h from mlx5/core/main.c.
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Acked-by: default avatarMatan Barak <matanb@mellanox.com>
      Acked-by: default avatarSaeed Mahameed <saeedm@mellanox.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      5e7dfeb7
    • Geliang Tang's avatar
      net: ieee802154: drop duplicate header delay.h · 8f8a8b13
      Geliang Tang authored
      Drop duplicate header delay.h from adf7242.c.
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Acked-by: default avatarStefan Schmidt <stefan@osg.samsung.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      8f8a8b13
    • Geliang Tang's avatar
      ibmvnic: drop duplicate header seq_file.h · 4ee12efa
      Geliang Tang authored
      Drop duplicate header seq_file.h from ibmvnic.c.
      Signed-off-by: default avatarGeliang Tang <geliangtang@gmail.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      4ee12efa
    • Dan Carpenter's avatar
      fsl/fman: fix a leak in tgec_free() · 1f1e70ef
      Dan Carpenter authored
      We set "tgec->cfg" to NULL before passing it to kfree().  There is no
      need to set it to NULL at all.  Let's just delete it.
      
      Fixes: 57ba4c9b ("fsl/fman: Add FMan MAC support")
      Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
      1f1e70ef