18 Jun, 2015

1 commit

  • Driver authors seem to get the ordering of irq_set_chained_handler()
    and irq_set_handler_data() wrong - ordering the former before the
    latter. This opens a race window where, if there is an interrupt
    pending, the handler will be called between these two calls,
    potentially resulting in an oops.

    Provide a single interface to set both of these together, especially
    as that's commonly what is required.

    Signed-off-by: Russell King
    Cc: Alexandre Courbot
    Cc: Hans Ulli Kroll
    Cc: Jason Cooper
    Cc: Lee Jones
    Cc: Linus Walleij
    Cc: Thierry Reding
    Cc: linux-arm-kernel@lists.infradead.org
    Link: http://lkml.kernel.org/r/E1Z4yzs-0002Rw-4B@rmk-PC.arm.linux.org.uk
    Signed-off-by: Thomas Gleixner

    Russell King
     

06 Jun, 2015

1 commit


23 May, 2015

4 commits

  • Pull networking fixes from David Miller:

    1) Don't leak ipvs->sysctl_tbl, from Tommi Rentala.

    2) Fix neighbour table entry leak in rocker driver, from Ying Xue.

    3) Do not emit bonding notifications for unregistered interfaces, from
    Nicolas Dichtel.

    4) Set ipv6 flow label properly when in TIME_WAIT state, from Florent
    Fourcot.

    5) Fix regression in ipv6 multicast filter test, from Henning Rogge.

    6) do_replace() in various footables netfilter modules is missing a
    check for 0 counters in the datastructure provided by the user. Fix
    from Dave Jones, and found with trinity.

    7) Fix RCU bug in packet scheduler classifier module unloads, from
    Daniel Borkmann.

    8) Avoid deadlock in tcp_get_info() by using u64_sync. From Eric
    Dumzaet.

    9) Input packet processing can race with inetdev_destroy() teardown,
    fix potential OOPS in ip_error() by explicitly testing whether the
    inetdev is still attached. From Eric W Biederman.

    10) MLDv2 parser in bridge multicast code breaks too early while
    parsing. Fix from Thadeu Lima de Souza Cascardo.

    11) Asking for settings on non-zero PHYID doesn't work because we do not
    import the command structure from the user and use the PHYID
    provided there. Fix from Arun Parameswaran.

    12) Fix UDP checksums with IPV6 RAW sockets, from Vlad Yasevich.

    13) Missing NF_TABLES depends for TPROXY etc can cause build failures,
    fix from Florian Westphal.

    14) Fix netfilter conntrack to handle RFC5961 challenge ACKs properly,
    from Jesper Dangaard Brouer.

    15) If netlink autobind retry fails, we have to reset the sockets portid
    back to zero. From Herbert Xu.

    16) VXLAN netns exit code unregisters using wrong device, from John W
    Linville.

    17) Add some USB device IDs to ath3k and btusb bluetooth drivers, from
    Dmitry Tunin and Wen-chien Jesse Sung.

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (44 commits)
    bridge: fix lockdep splat
    net: core: 'ethtool' issue with querying phy settings
    bridge: fix parsing of MLDv2 reports
    ARM: zynq: DT: Use the zynq binding with macb
    net: macb: Disable half duplex gigabit on Zynq
    net: macb: Document zynq gem dt binding
    ipv4: fill in table id when replacing a route
    cdc_ncm: Fix tx_bytes statistics
    ipv4: Avoid crashing in ip_error
    tcp: fix a potential deadlock in tcp_get_info()
    net: sched: fix call_rcu() race on classifier module unloads
    net: phy: Make sure phy_start() always re-enables the phy interrupts
    ipv6: fix ECMP route replacement
    ipv6: do not delete previously existing ECMP routes if add fails
    Revert "netfilter: bridge: query conntrack about skb dnat"
    netfilter: ensure number of counters is >0 in do_replace()
    netfilter: nfnetlink_{log,queue}: Register pernet in first place
    tcp: don't over-send F-RTO probes
    tcp: only undo on partial ACKs in CA_Loss
    net/ipv6/udp: Fix ipv6 multicast socket filter regression
    ...

    Linus Torvalds
     
  • Pull block fixes from Jens Axboe:
    "Three small fixes that have been picked up the last few weeks.
    Specifically:

    - Fix a memory corruption issue in NVMe with malignant user
    constructed request. From Christoph.

    - Kill (now) unused blk_queue_bio(), dm was changed to not need this
    anymore. From Mike Snitzer.

    - Always use blk_schedule_flush_plug() from the io_schedule() path
    when flushing a plug, fixing a !TASK_RUNNING warning with md. From
    Shaohua"

    * 'for-linus' of git://git.kernel.dk/linux-block:
    sched: always use blk_schedule_flush_plug in io_schedule_out
    nvme: fix kernel memory corruption with short INQUIRY buffers
    block: remove export for blk_queue_bio

    Linus Torvalds
     
  • Pablo Neira Ayuso says:

    ====================
    Netfilter fixes for net

    The following patchset contain Netfilter fixes for your net tree, they are:

    1) Fix a race in nfnetlink_log and nfnetlink_queue that can lead to a crash.
    This problem is due to wrong order in the per-net registration and netlink
    socket events. Patch from Francesco Ruggeri.

    2) Make sure that counters that userspace pass us are higher than 0 in all the
    x_tables frontends. Discovered via Trinity, patch from Dave Jones.

    3) Revert a patch for br_netfilter to rely on the conntrack status bits. This
    breaks stateless IPv6 NAT transformations. Patch from Florian Westphal.
    ====================

    Signed-off-by: David S. Miller

    David S. Miller
     
  • Taking socket spinlock in tcp_get_info() can deadlock, as
    inet_diag_dump_icsk() holds the &hashinfo->ehash_locks[i],
    while packet processing can use the reverse locking order.

    We could avoid this locking for TCP_LISTEN states, but lockdep would
    certainly get confused as all TCP sockets share same lockdep classes.

    [ 523.722504] ======================================================
    [ 523.728706] [ INFO: possible circular locking dependency detected ]
    [ 523.734990] 4.1.0-dbg-DEV #1676 Not tainted
    [ 523.739202] -------------------------------------------------------
    [ 523.745474] ss/18032 is trying to acquire lock:
    [ 523.750002] (slock-AF_INET){+.-...}, at: [] tcp_get_info+0x2c4/0x360
    [ 523.758129]
    [ 523.758129] but task is already holding lock:
    [ 523.763968] (&(&hashinfo->ehash_locks[i])->rlock){+.-...}, at: [] inet_diag_dump_icsk+0x1d5/0x6c0
    [ 523.774661]
    [ 523.774661] which lock already depends on the new lock.
    [ 523.774661]
    [ 523.782850]
    [ 523.782850] the existing dependency chain (in reverse order) is:
    [ 523.790326]
    -> #1 (&(&hashinfo->ehash_locks[i])->rlock){+.-...}:
    [ 523.796599] [] lock_acquire+0xbb/0x270
    [ 523.802565] [] _raw_spin_lock+0x38/0x50
    [ 523.808628] [] __inet_hash_nolisten+0x78/0x110
    [ 523.815273] [] tcp_v4_syn_recv_sock+0x24b/0x350
    [ 523.822067] [] tcp_check_req+0x3c1/0x500
    [ 523.828199] [] tcp_v4_do_rcv+0x239/0x3d0
    [ 523.834331] [] tcp_v4_rcv+0xa8e/0xc10
    [ 523.840202] [] ip_local_deliver_finish+0x133/0x3e0
    [ 523.847214] [] ip_local_deliver+0xaa/0xc0
    [ 523.853440] [] ip_rcv_finish+0x168/0x5c0
    [ 523.859624] [] ip_rcv+0x307/0x420

    Lets use u64_sync infrastructure instead. As a bonus, 64bit
    arches get optimized, as these are nop for them.

    Fixes: 0df48c26d841 ("tcp: add tcpi_bytes_acked to tcp_info")
    Signed-off-by: Eric Dumazet
    Signed-off-by: David S. Miller

    Eric Dumazet
     

22 May, 2015

3 commits

  • Pull two xen bugfixes from David Vrabel:

    - fix ARM build regression.

    - fix VIRQ_CONSOLE related oops.

    * tag 'for-linus-4.1b-rc4-tag' of git://git.kernel.org/pub/scm/linux/kernel/git/xen/tip:
    xen/events: don't bind non-percpu VIRQs with percpu chip
    xen/arm: Define xen_arch_suspend()

    Linus Torvalds
     
  • Pull HID fixes from Jiri Kosina:
    "Bugfixes for HID subsystem that should go in 4.1. Important
    highlights:

    - the patch that extended support for HID++ protocol for TK820
    touchpad turns out to be causing regressions due to firmware
    issues; patch reverting back to basic support from Benjamin
    Tissoires

    - Wacom driver can oops for devices that report non-touch data on
    touch interfaces. Fix from Ping Cheng

    - gpiolib is not mandatory for i2c-hid, so the driver shouldn't fail
    if gpiolib is not enabled. Fix from Mika Westerberg"

    * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid:
    HID: wacom: fix an Oops caused by wacom_wac_finger_count_touches
    HID: usbhid: Add HID_QUIRK_NOGET for Aten DVI KVM switch
    HID: hid-sensor-hub: Fix debug lock warning
    Revert "HID: logitech-hidpp: support combo keyboard touchpad TK820"
    HID: i2c-hid: Do not fail probing if gpiolib is not enabled

    Linus Torvalds
     
  • Pull clk fixes from Michael Turquette:
    "The first set of clk fixes for 4.1 are all driver bugs, with the
    exception of a single locking fix in the core code.

    All driver fixes are for code that was merged recently. The Samsung
    stuff is mostly fixes around suspend/resume, the Qualcomm fixes are
    for invalid hardware configuration data and the Silicon Labs patches
    are fixes following their move away from platform_data to Device Tree"

    * tag 'clk-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/clk/linux:
    clk: si5351: Do not pass struct clk in platform_data
    clk: si5351: Mention clock-names in the binding documentation
    clk: add missing lock when call clk_core_enable in clk_set_parent
    clk: exynos5420: Restore GATE_BUS_TOP on suspend
    clk: qcom: Fix MSM8916 gfx3d_clk_src configuration
    clk: qcom: Fix MSM8916 venus divider value
    clk: exynos5433: Fix wrong PMS value of exynos5433_pll_rates
    clk: exynos5433: Fix wrong parent clock of sclk_apollo clock
    clk: exynos5433: Fix CLK_PCLK_MONOTONIC_CNT clk register assignment
    clk: exynos5433: Fix wrong offset of PCLK_MSCL_SECURE_SMMU_JPEG
    clk: Use CONFIG_ARCH_EXYNOS instead of CONFIG_ARCH_EXYNOS5433

    Linus Torvalds
     

20 May, 2015

2 commits

  • This reverts commit c055d5b03bb4cb69d349d787c9787c0383abd8b2.

    There are two issues:
    'dnat_took_place' made me think that this is related to
    -j DNAT/MASQUERADE.

    But thats only one part of the story. This is also relevant for SNAT
    when we undo snat translation in reverse/reply direction.

    Furthermore, I originally wanted to do this mainly to avoid
    storing ipv6 addresses once we make DNAT/REDIRECT work
    for ipv6 on bridges.

    However, I forgot about SNPT/DNPT which is stateless.

    So we can't escape storing address for ipv6 anyway. Might as
    well do it for ipv4 too.

    Reported-and-tested-by: Bernhard Thaler
    Signed-off-by: Florian Westphal
    Signed-off-by: Pablo Neira Ayuso

    Florian Westphal
     
  • A non-percpu VIRQ (e.g., VIRQ_CONSOLE) may be freed on a different
    VCPU than it is bound to. This can result in a race between
    handle_percpu_irq() and removing the action in __free_irq() because
    handle_percpu_irq() does not take desc->lock. The interrupt handler
    sees a NULL action and oopses.

    Only use the percpu chip/handler for per-CPU VIRQs (like VIRQ_TIMER).

    # cat /proc/interrupts | grep virq
    40: 87246 0 xen-percpu-virq timer0
    44: 0 0 xen-percpu-virq debug0
    47: 0 20995 xen-percpu-virq timer1
    51: 0 0 xen-percpu-virq debug1
    69: 0 0 xen-dyn-virq xen-pcpu
    74: 0 0 xen-dyn-virq mce
    75: 29 0 xen-dyn-virq hvc_console

    Signed-off-by: David Vrabel
    Cc:

    David Vrabel
     

19 May, 2015

4 commits

  • tcp_illinois and upcoming tcp_cdg require 64bit alignment of
    icsk_ca_priv

    x86 does not care, but other architectures might.

    Fixes: 05cbc0db03e82 ("ipv4: Create probe timer for tcp PMTU as per RFC4821")
    Signed-off-by: Eric Dumazet
    Cc: Fan Du
    Acked-by: Fan Du
    Signed-off-by: David S. Miller

    Eric Dumazet
     
  • Pull in the branch which can be consumed by x86 to build their changes
    on top.

    Thomas Gleixner
     
  • With Posted-Interrupts support in Intel CPU and IOMMU, an external
    interrupt from assigned-devices could be directly delivered to a
    virtual CPU in a virtual machine. Instead of hacking KVM and Intel
    IOMMU drivers, we propose a platform independent interface to target
    an interrupt to a specific virtual CPU in a virtual machine, or set
    virtual CPU affinity for an interrupt.

    By adopting this new interface and the hierarchy irqdomain, we could
    easily support posted-interrupts on Intel platforms, and also provide
    flexible enough interfaces for other platforms to support similar
    features.

    Here is the usage scenario for this interface:
    Guest update MSI/MSI-X interrupt configuration
    -->QEMU and KVM handle this
    -->KVM call this interface (passing posted interrupts descriptor
    and guest vector)
    -->irq core will transfer the control to IOMMU
    -->IOMMU will do the real work of updating IRTE (IRTE has new
    format for VT-d Posted-Interrupts)

    Signed-off-by: Jiang Liu
    Signed-off-by: Feng Wu
    Link: http://lkml.kernel.org/r/1432026437-16560-2-git-send-email-feng.wu@intel.com
    Signed-off-by: Thomas Gleixner

    Jiang Liu
     
  • Pull in the branch which can be consumed by ARM to build their changes
    on top.

    Thomas Gleixner
     

18 May, 2015

2 commits

  • Add helper irq_chip_enable_parent and irq_chip_disable_parent. The
    helper implement the default behavior in case irq_enable or irq_disable
    is not implemented for the parent interrupt chip, which is calling the
    irq_mask or irq_unmask respectively.

    Signed-off-by: Stefan Agner
    Cc: marc.zyngier@arm.com
    Cc: linux@arm.linux.org.uk
    Cc: u.kleine-koenig@pengutronix.de
    Cc: olof@lixom.net
    Cc: arnd@arndb.de
    Cc: daniel.lezcano@linaro.org
    Cc: mark.rutland@arm.com
    Cc: pawel.moll@arm.com
    Cc: robh+dt@kernel.org
    Cc: ijc+devicetree@hellion.org.uk
    Cc: galak@codeaurora.org
    Cc: mcoquelin.stm32@gmail.com
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: shawn.guo@linaro.org
    Cc: kernel@pengutronix.de
    Cc: jason@lakedaemon.net
    Link: http://lkml.kernel.org/r/1431769465-26867-3-git-send-email-stefan@agner.ch
    Signed-off-by: Thomas Gleixner

    Stefan Agner
     
  • This adds the helper irq_domain_set_info() in a non-domain hierarchy
    variant. This allows to use the helper for generic chip since not
    all chips using generic chip support domain hierarchy.

    Signed-off-by: Stefan Agner
    Cc: marc.zyngier@arm.com
    Cc: linux@arm.linux.org.uk
    Cc: u.kleine-koenig@pengutronix.de
    Cc: olof@lixom.net
    Cc: arnd@arndb.de
    Cc: daniel.lezcano@linaro.org
    Cc: mark.rutland@arm.com
    Cc: pawel.moll@arm.com
    Cc: robh+dt@kernel.org
    Cc: ijc+devicetree@hellion.org.uk
    Cc: galak@codeaurora.org
    Cc: mcoquelin.stm32@gmail.com
    Cc: linux-arm-kernel@lists.infradead.org
    Cc: shawn.guo@linaro.org
    Cc: kernel@pengutronix.de
    Cc: jason@lakedaemon.net
    Link: http://lkml.kernel.org/r/1431769465-26867-2-git-send-email-stefan@agner.ch
    Signed-off-by: Thomas Gleixner

    Stefan Agner
     

17 May, 2015

3 commits

  • Pull tty/serial fixes from Greg KH:
    "Here's some TTY and serial driver fixes for reported issues.

    All of these have been in linux-next successfully"

    * tag 'tty-4.1-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty:
    pty: Fix input race when closing
    tty/n_gsm.c: fix a memory leak when gsmtty is removed
    Revert "serial/amba-pl011: Leave the TX IRQ alone when the UART is not open"
    serial: omap: Fix error handling in probe
    earlycon: Revert log warnings

    Linus Torvalds
     
  • We currently have no limit on the number of elements in a hash table.
    This is a problem because some users (tipc) set a ceiling on the
    maximum table size and when that is reached the hash table may
    degenerate. Others may encounter OOM when growing and if we allow
    insertions when that happens the hash table perofrmance may also
    suffer.

    This patch adds a new paramater insecure_max_entries which becomes
    the cap on the table. If unset it defaults to max_size * 2. If
    it is also zero it means that there is no cap on the number of
    elements in the table. However, the table will grow whenever the
    utilisation hits 100% and if that growth fails, you will get ENOMEM
    on insertion.

    As allowing oversubscription is potentially dangerous, the name
    contains the word insecure.

    Note that the cap is not a hard limit. This is done for performance
    reasons as enforcing a hard limit will result in use of atomic ops
    that are heavier than the ones we currently use.

    The reasoning is that we're only guarding against a gross over-
    subscription of the table, rather than a small breach of the limit.

    Signed-off-by: Herbert Xu
    Signed-off-by: David S. Miller

    Herbert Xu
     
  • Pablo Neira Ayuso says:

    ====================
    The following patchset contains Netfilter fixes for your net tree, they are:

    1) Fix a leak in IPVS, the sysctl table is not released accordingly when
    destroying a netns, patch from Tommi Rantala.

    2) Fix a build error when TPROXY and socket are built-in but IPv6 defrag is
    compiled as module, from Florian Westphal.

    3) Fix TCP tracket wrt. RFC5961 challenge ACK when in LAST_ACK state, patch
    from Jesper Dangaard Brouer.

    4) Fix a bogus WARN_ON() in nf_tables when deleting a set element that stores
    a map, from Mirek Kratochvil.
    ====================

    Signed-off-by: David S. Miller

    David S. Miller
     

16 May, 2015

3 commits

  • Pull scheduler fixes from Ingo Molnar:
    "Two fixes: a suspend/resume related regression fix, and an RT priority
    boosting fix"

    * 'sched-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
    sched/core: Fix regression in cpuset_cpu_inactive() for suspend
    sched: Handle priority boosted tasks proper in setscheduler()

    Linus Torvalds
     
  • In compliance with RFC5961, the network stack send challenge ACK in
    response to spurious SYN packets, since commit 0c228e833c88 ("tcp:
    Restore RFC5961-compliant behavior for SYN packets").

    This pose a problem for netfilter conntrack in state LAST_ACK, because
    this challenge ACK is (falsely) seen as ACKing last FIN, causing a
    false state transition (into TIME_WAIT).

    The challenge ACK is hard to distinguish from real last ACK. Thus,
    solution introduce a flag that tracks the potential for seeing a
    challenge ACK, in case a SYN packet is let through and current state
    is LAST_ACK.

    When conntrack transition LAST_ACK to TIME_WAIT happens, this flag is
    used for determining if we are expecting a challenge ACK.

    Scapy based reproducer script avail here:
    https://github.com/netoptimizer/network-testing/blob/master/scapy/tcp_hacks_3WHS_LAST_ACK.py

    Fixes: 0c228e833c88 ("tcp: Restore RFC5961-compliant behavior for SYN packets")
    Signed-off-by: Jesper Dangaard Brouer
    Acked-by: Jozsef Kadlecsik
    Signed-off-by: Pablo Neira Ayuso

    Jesper Dangaard Brouer
     
  • Pull drm fixes from Dave Airlie:
    "Radeon:
    one oops fix, one bug fix, one pci id addition patch

    i915:
    one suspend/resume regression fix.

    All seems quiet enough."

    * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux:
    drm/radeon: don't do mst probing if MST isn't enabled.
    drm/radeon: add new bonaire pci id
    drm/radeon: fix VM_CONTEXT*_PAGE_TABLE_END_ADDR handling
    drm/i915: Avoid GPU hang when coming out of s3 or s4

    Linus Torvalds
     

15 May, 2015

4 commits

  • radeon minor fixes, and pci id addition.
    * 'drm-fixes-4.1' of git://people.freedesktop.org/~agd5f/linux:
    drm/radeon: don't do mst probing if MST isn't enabled.
    drm/radeon: add new bonaire pci id
    drm/radeon: fix VM_CONTEXT*_PAGE_TABLE_END_ADDR handling

    Dave Airlie
     
  • RTNH_F_EXTERNAL today is printed as "offload" in iproute2 output.

    This patch renames the flag to be consistent with what the user sees.

    Signed-off-by: Roopa Prabhu
    Signed-off-by: David S. Miller

    Roopa Prabhu
     
  • {u,g}id_valid call {u,g}id_eq, which calls __k{u,g}id_val on both
    arguments and compares. With !CONFIG_MULTIUSER, __k{u,g}id_val return a
    constant 0, which makes {u,g}id_valid always return false. Change
    {u,g}id_valid to compare their argument against -1 instead. That produces
    identical results in the normal CONFIG_MULTIUSER=y case, but with
    !CONFIG_MULTIUSER will make {u,g}id_valid constant-fold into "return
    true;" rather than "return false;".

    This fixes uses of devpts without CONFIG_MULTIUSER.

    Signed-off-by: Josh Triplett
    Reported-by: Fengguang Wu ,
    Cc: Peter Hurley
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Josh Triplett
     
  • Not all kmem allocations should be accounted to memcg. The following
    patch gives an example when accounting of a certain type of allocations to
    memcg can effectively result in a memory leak. This patch adds the
    __GFP_NOACCOUNT flag which if passed to kmalloc and friends will force the
    allocation to go through the root cgroup. It will be used by the next
    patch.

    Note, since in case of kmemleak enabled each kmalloc implies yet another
    allocation from the kmemleak_object cache, we add __GFP_NOACCOUNT to
    gfp_kmemleak_mask.

    Alternatively, we could introduce a per kmem cache flag disabling
    accounting for all allocations of a particular kind, but (a) we would not
    be able to bypass accounting for kmalloc then and (b) a kmem cache with
    this flag set could not be merged with a kmem cache without this flag,
    which would increase the number of global caches and therefore
    fragmentation even if the memory cgroup controller is not used.

    Despite its generic name, currently __GFP_NOACCOUNT disables accounting
    only for kmem allocations while user page allocations are always charged.
    To catch abusing of this flag, a warning is issued on an attempt of
    passing it to mem_cgroup_try_charge.

    Signed-off-by: Vladimir Davydov
    Cc: Tejun Heo
    Cc: Johannes Weiner
    Cc: Michal Hocko
    Cc: Christoph Lameter
    Cc: Pekka Enberg
    Cc: David Rientjes
    Cc: Joonsoo Kim
    Cc: Greg Thelen
    Cc: Greg Kroah-Hartman
    Cc: [4.0.x]
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Vladimir Davydov
     

13 May, 2015

4 commits

  • Pull networking fixes from David Miller:

    1) Handle max TX power properly wrt VIFs and the MAC in iwlwifi, from
    Avri Altman.

    2) Use the correct FW API for scan completions in iwlwifi, from Avraham
    Stern.

    3) FW monitor in iwlwifi accidently uses unmapped memory, fix from Liad
    Kaufman.

    4) rhashtable conversion of mac80211 station table was buggy, the
    virtual interface was not taken into account. Fix from Johannes
    Berg.

    5) Fix deadlock in rtlwifi by not using a zero timeout for
    usb_control_msg(), from Larry Finger.

    6) Update reordering state before calculating loss detection, from
    Yuchung Cheng.

    7) Fix off by one in bluetooth firmward parsing, from Dan Carpenter.

    8) Fix extended frame handling in xiling_can driver, from Jeppe
    Ledet-Pedersen.

    9) Fix CODEL packet scheduler behavior in the presence of TSO packets,
    from Eric Dumazet.

    10) Fix NAPI budget testing in fm10k driver, from Alexander Duyck.

    11) macvlan needs to propagate promisc settings down the the lower
    device, from Vlad Yasevich.

    12) igb driver can oops when changing number of rings, from Toshiaki
    Makita.

    13) Source specific default routes not handled properly in ipv6, from
    Markus Stenberg.

    14) Use after free in tc_ctl_tfilter(), from WANG Cong.

    15) Use softirq spinlocking in netxen driver, from Tony Camuso.

    16) Two ARM bpf JIT fixes from Nicolas Schichan.

    17) Handle MSG_DONTWAIT properly in ring based AF_PACKET sends, from
    Mathias Kretschmer.

    18) Fix x86 bpf JIT implementation of FROM_{BE16,LE16,LE32}, from Alexei
    Starovoitov.

    19) ll_temac driver DMA maps TX packet header with incorrect length, fix
    from Michal Simek.

    20) We removed pm_qos bits from netdevice.h, but some indirect
    references remained. Kill them. From David Ahern.

    * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net: (90 commits)
    net: Remove remaining remnants of pm_qos from netdevice.h
    e1000e: Add pm_qos header
    net: phy: micrel: Fix regression in kszphy_probe
    net: ll_temac: Fix DMA map size bug
    x86: bpf_jit: fix FROM_BE16 and FROM_LE16/32 instructions
    netns: return RTM_NEWNSID instead of RTM_GETNSID on a get
    Update be2net maintainers' email addresses
    net_sched: gred: use correct backlog value in WRED mode
    pppoe: drop pppoe device in pppoe_unbind_sock_work
    net: qca_spi: Fix possible race during probe
    net: mdio-gpio: Allow for unspecified bus id
    af_packet / TX_RING not fully non-blocking (w/ MSG_DONTWAIT).
    bnx2x: limit fw delay in kdump to 5s after boot
    ARM: net: delegate filter to kernel interpreter when imm_offset() return value can't fit into 12bits.
    ARM: net fix emit_udiv() for BPF_ALU | BPF_DIV | BPF_K intruction.
    mpls: Change reserved label names to be consistent with netbsd
    usbnet: avoid integer overflow in start_xmit
    netxen_nic: use spin_[un]lock_bh around tx_clean_lock (2)
    net: xgene_enet: Set hardware dependency
    net: amd-xgbe: Add hardware dependency
    ...

    Linus Torvalds
     
  • Commit e2c6544829f removed pm_qos from struct net_device but left the
    comment and header file. Remove those.

    Signed-off-by: David Ahern
    Cc: Thomas Graf
    Signed-off-by: David S. Miller

    David Ahern
     
  • With commit ff36ab345 ("dm: remove request-based logic from
    make_request_fn wrapper") DM no longer calls blk_queue_bio() directly,
    so remove its export. Doing so required a forward declaration in
    blk-core.c.

    Signed-off-by: Mike Snitzer
    Signed-off-by: Jens Axboe

    Mike Snitzer
     
  • Signed-off-by: Alex Deucher
    Cc: stable@vger.kernel.org

    Alex Deucher
     

12 May, 2015

2 commits

  • When CONFIG_DEBUG_LOCK_ALLOC is defined, mutex magic is compared and
    warned for (l->magic != l), here l is the address of mutex pointer.
    In hid-sensor-hub as part of hsdev creation, a per hsdev mutex is
    initialized during MFD cell creation. This hsdev, which contains, mutex
    is part of platform data for the a cell. But platform_data is copied
    in platform_device_add_data() in platform.c. This copy will copy the
    whole hsdev structure including mutex. But once copied the magic
    will no longer match. So when client driver call
    sensor_hub_input_attr_get_raw_value, this will trigger mutex warning.
    So to avoid this allocate mutex dynamically. This will be same even
    after copy.

    Signed-off-by: Srinivas Pandruvada
    Signed-off-by: Jiri Kosina

    Srinivas Pandruvada
     
  • Pull libata fixes from Tejun Heo:
    "Rather big for fixes pull.

    - SCC controllers never lived to see the light of the day. Both
    libata and ide drivers removed.

    - In some configurations, link power management policy changes
    sometimes cause delayed spurious PHY events which can develop into
    noticeable failures. This has been reported several times over the
    years. Gabriele's patches suppress PHY events for a while after
    LPM policy changes which should help most of these failures without
    causing too much problem for hotplug use cases.

    - A few controller specific fixes"

    [ Hmm. I don't think removing SSC support is really a "fix", but hey, it
    removes a lot of lines of code. Which I like. So ... good riddance ]

    * 'for-4.1-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/tj/libata:
    ahci: avoton port-disable reset-quirk
    ata: select DW_DMAC in case of SATA_DWC
    libata: Blacklist queued TRIM on all Samsung 800-series
    libata: Ignore spurious PHY event on LPM policy change
    libata: Add helper to determine when PHY events should be ignored
    ata: ahci_st: fixup layering violations / drvdata errors
    Remove celleb-only SCC PATA drivers

    Linus Torvalds
     

11 May, 2015

1 commit

  • A read() from a pty master may mistakenly indicate EOF (errno == -EIO)
    after the pty slave has closed, even though input data remains to be read.
    For example,

    pty slave | input worker | pty master
    | |
    | | n_tty_read()
    pty_write() | | input avail? no
    add data | | sleep
    schedule worker --->| | .
    |---> flush_to_ldisc() | .
    pty_close() | fill read buffer | .
    wait for worker | wakeup reader --->| .
    | read buffer full? |---> input avail ? yes
    |= 4096 so the ldisc read buffer
    is empty
    3. the subsequent read() occurs before the kicked worker has processed
    more input

    However, the underlying cause of the race is that data is pipelined, while
    tty state is not; ie., data already written by the pty slave end is not
    yet visible to the pty master end, but state changes by the pty slave end
    are visible to the pty master end immediately.

    Pipeline the TTY_OTHER_CLOSED state through input worker to the reader.
    1. Introduce TTY_OTHER_DONE which is set by the input worker when
    TTY_OTHER_CLOSED is set and either the input buffers are flushed or
    input processing has completed. Readers/polls are woken when
    TTY_OTHER_DONE is set.
    2. Reader/poll checks TTY_OTHER_DONE instead of TTY_OTHER_CLOSED.
    3. A new input worker is started from pty_close() after setting
    TTY_OTHER_CLOSED, which ensures the TTY_OTHER_DONE state will be
    set if the last input worker is already finished (or just about to
    exit).

    Remove tty_flush_to_ldisc(); no in-tree callers.

    Fixes: 52bce7f8d4fc ("pty, n_tty: Simplify input processing on final close")
    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=96311
    BugLink: http://bugs.launchpad.net/bugs/1429756
    Cc: # 3.19+
    Reported-by: Andy Whitcroft
    Reported-by: H.J. Lu
    Signed-off-by: Peter Hurley
    Signed-off-by: Greg Kroah-Hartman

    Peter Hurley
     

10 May, 2015

2 commits


09 May, 2015

3 commits

  • Pull block fixes from Jens Axboe:
    "A collection of fixes since the merge window;

    - fix for a double elevator module release, from Chao Yu. Ancient bug.

    - the splice() MORE flag fix from Christophe Leroy.

    - a fix for NVMe, fixing a patch that went in in the merge window.
    From Keith.

    - two fixes for blk-mq CPU hotplug handling, from Ming Lei.

    - bdi vs blockdev lifetime fix from Neil Brown, fixing and oops in md.

    - two blk-mq fixes from Shaohua, fixing a race on queue stop and a
    bad merge issue with FUA writes.

    - division-by-zero fix for writeback from Tejun.

    - a block bounce page accounting fix, making sure we inc/dec after
    bouncing so that pre/post IO pages match up. From Wang YanQing"

    * 'for-linus' of git://git.kernel.dk/linux-block:
    splice: sendfile() at once fails for big files
    blk-mq: don't lose requests if a stopped queue restarts
    blk-mq: fix FUA request hang
    block: destroy bdi before blockdev is unregistered.
    block:bounce: fix call inc_|dec_zone_page_state on different pages confuse value of NR_BOUNCE
    elevator: fix double release of elevator module
    writeback: use |1 instead of +1 to protect against div by zero
    blk-mq: fix CPU hotplug handling
    blk-mq: fix race between timeout and CPU hotplug
    NVMe: Fix VPD B0 max sectors translation

    Linus Torvalds
     
  • …t/rostedt/linux-trace

    Pull tracing fix from Steven Rostedt:
    "The newly added ftrace_print_array_seq() function had a bug in it.
    Luckily, the only user of it didn't make the 4.1 merge window.

    But the helper function should be fixed before 4.2 when the users
    start coming in"

    * tag 'trace-fixes-v4.1-rc2' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace:
    tracing: Make ftrace_print_array_seq compute buf_len

    Linus Torvalds
     
  • When registering clk-si5351 by platform_data, we should not pass struct clk
    for the reference clocks. Drop struct clk from platform_data and rework the
    driver to use devm_clk_get of named clock references.

    While at it, check for at least one valid input clock and properly prepare/
    enable valid reference clocks.

    Signed-off-by: Sebastian Hesselbarth
    Reported-by: Michael Welling
    Reported-by: Jean-Francois Moine
    Reported-by: Russell King
    Tested-by: Michael Welling
    Tested-by: Jean-Francois Moine
    Signed-off-by: Michael Turquette

    Sebastian Hesselbarth
     

08 May, 2015

1 commit

  • Ronny reported that the following scenario is not handled correctly:

    T1 (prio = 10)
    lock(rtmutex);

    T2 (prio = 20)
    lock(rtmutex)
    boost T1

    T1 (prio = 20)
    sys_set_scheduler(prio = 30)
    T1 prio = 30
    ....
    sys_set_scheduler(prio = 10)
    T1 prio = 30

    The last step is wrong as T1 should now be back at prio 20.

    Commit c365c292d059 ("sched: Consider pi boosting in setscheduler()")
    only handles the case where a boosted tasks tries to lower its
    priority.

    Fix it by taking the new effective priority into account for the
    decision whether a change of the priority is required.

    Reported-by: Ronny Meeus
    Tested-by: Steven Rostedt
    Signed-off-by: Thomas Gleixner
    Signed-off-by: Peter Zijlstra (Intel)
    Reviewed-by: Steven Rostedt
    Cc:
    Cc: Borislav Petkov
    Cc: H. Peter Anvin
    Cc: Mike Galbraith
    Fixes: c365c292d059 ("sched: Consider pi boosting in setscheduler()")
    Link: http://lkml.kernel.org/r/alpine.DEB.2.11.1505051806060.4225@nanos
    Signed-off-by: Ingo Molnar

    Thomas Gleixner