1. 10 Apr, 2019 4 commits
    • Bart Van Assche's avatar
      locking/lockdep: Zap lock classes even with lock debugging disabled · 90c1cba2
      Bart Van Assche authored
      The following commit:
      
        a0b0fd53 ("locking/lockdep: Free lock classes that are no longer in use")
      
      changed the behavior of lockdep_free_key_range() from
      unconditionally zapping lock classes into only zapping lock classes if
      debug_lock == true. Not zapping lock classes if debug_lock == false leaves
      dangling pointers in several lockdep datastructures, e.g. lock_class::name
      in the all_lock_classes list.
      
      The shell command "cat /proc/lockdep" causes the kernel to iterate the
      all_lock_classes list. Hence the "unable to handle kernel paging request" cash
      that Shenghui encountered by running cat /proc/lockdep.
      
      Since the new behavior can cause cat /proc/lockdep to crash, restore the
      pre-v5.1 behavior.
      
      This patch avoids that cat /proc/lockdep triggers the following crash
      with debug_lock == false:
      
        BUG: unable to handle kernel paging request at fffffbfff40ca448
        RIP: 0010:__asan_load1+0x28/0x50
        Call Trace:
         string+0xac/0x180
         vsnprintf+0x23e/0x820
         seq_vprintf+0x82/0xc0
         seq_printf+0x92/0xb0
         print_name+0x34/0xb0
         l_show+0x184/0x200
         seq_read+0x59e/0x6c0
         proc_reg_read+0x11f/0x170
         __vfs_read+0x4d/0x90
         vfs_read+0xc5/0x1f0
         ksys_read+0xab/0x130
         __x64_sys_read+0x43/0x50
         do_syscall_64+0x71/0x210
         entry_SYSCALL_64_after_hwframe+0x49/0xbe
      Reported-by: default avatarshenghui <shhuiw@foxmail.com>
      Signed-off-by: default avatarBart Van Assche <bvanassche@acm.org>
      Signed-off-by: default avatarPeter Zijlstra (Intel) <peterz@infradead.org>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Thomas Gleixner <tglx@linutronix.de>
      Cc: Waiman Long <longman@redhat.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Fixes: a0b0fd53 ("locking/lockdep: Free lock classes that are no longer in use") # v5.1-rc1.
      Link: https://lkml.kernel.org/r/20190403233552.124673-1-bvanassche@acm.orgSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
      90c1cba2
    • Brian Norris's avatar
      Bluetooth: btusb: request wake pin with NOAUTOEN · 771acc7e
      Brian Norris authored
      Badly-designed systems might have (for example) active-high wake pins
      that default to high (e.g., because of external pull ups) until they
      have an active firmware which starts driving it low.  This can cause an
      interrupt storm in the time between request_irq() and disable_irq().
      
      We don't support shared interrupts here, so let's just pre-configure the
      interrupt to avoid auto-enabling it.
      
      Fixes: fd913ef7 ("Bluetooth: btusb: Add out-of-band wakeup support")
      Fixes: 5364a0b4 ("arm64: dts: rockchip: move QCA6174A wakeup pin into its USB node")
      Signed-off-by: default avatarBrian Norris <briannorris@chromium.org>
      Reviewed-by: default avatarMatthias Kaehlcke <mka@chromium.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      771acc7e
    • Linus Torvalds's avatar
      Merge tag 'mips_fixes_5.1_2' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux · 0ee7fb36
      Linus Torvalds authored
      Pull MIPS fixes from Paul Burton:
       "A few minor MIPS fixes:
      
         - Provide struct pt_regs * from get_irq_regs() to kgdb_nmicallback()
           when handling an IPI triggered by kgdb_roundup_cpus(), matching the
           behavior of other architectures & resolving kgdb issues for SMP
           systems.
      
         - Defer a pointer dereference until after a NULL check in the
           irq_shutdown callback for SGI IP27 HUB interrupts.
      
         - A defconfig update for the MSCC Ocelot to enable some necessary
           drivers"
      
      * tag 'mips_fixes_5.1_2' of git://git.kernel.org/pub/scm/linux/kernel/git/mips/linux:
        MIPS: generic: Add switchdev, pinctrl and fit to ocelot_defconfig
        MIPS: SGI-IP27: Fix use of unchecked pointer in shutdown_bridge_irq
        MIPS: KGDB: fix kgdb support for SMP platforms.
      0ee7fb36
    • Linus Torvalds's avatar
      Merge branch 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs · 972acfb4
      Linus Torvalds authored
      Pull misc fixes from Al Viro:
       "A few regression fixes from this cycle"
      
      * 'fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
        aio: use kmem_cache_free() instead of kfree()
        iov_iter: Fix build error without CONFIG_CRYPTO
        aio: Fix an error code in __io_submit_one()
      972acfb4
  2. 09 Apr, 2019 3 commits
    • Linus Torvalds's avatar
      Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net · 869e3305
      Linus Torvalds authored
      Pull networking fixes from David Miller:
      
       1) Off by one and bounds checking fixes in NFC, from Dan Carpenter.
      
       2) There have been many weird regressions in r8169 since we turned ASPM
          support on, some are still not understood nor completely resolved.
          Let's turn this back off for now. From Heiner Kallweit.
      
       3) Signess fixes for ethtool speed value handling, from Michael
          Zhivich.
      
       4) Handle timestamps properly in macb driver, from Paul Thomas.
      
       5) Two erspan fixes, it's the usual "skb ->data potentially reallocated
          and we're holding a stale protocol header pointer". From Lorenzo
          Bianconi.
      
      * git://git.kernel.org/pub/scm/linux/kernel/git/davem/net:
        bnxt_en: Reset device on RX buffer errors.
        bnxt_en: Improve RX consumer index validity check.
        net: macb driver, check for SKBTX_HW_TSTAMP
        qlogic: qlcnic: fix use of SPEED_UNKNOWN ethtool constant
        broadcom: tg3: fix use of SPEED_UNKNOWN ethtool constant
        ethtool: avoid signed-unsigned comparison in ethtool_validate_speed()
        net: ip6_gre: fix possible use-after-free in ip6erspan_rcv
        net: ip_gre: fix possible use-after-free in erspan_rcv
        r8169: disable ASPM again
        MAINTAINERS: ieee802154: update documentation file pattern
        net: vrf: Fix ping failed when vrf mtu is set to 0
        selftests: add a tc matchall test case
        nfc: nci: Potential off by one in ->pipes[] array
        NFC: nci: Add some bounds checking in nci_hci_cmd_received()
      869e3305
    • Linus Torvalds's avatar
      Merge branch 'fixes-v5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security · a556810d
      Linus Torvalds authored
      Pull TPM fixes from James Morris:
       "From Jarkko: These are critical fixes for v5.1. Contains also couple
        of new selftests for v5.1 features (partial reads in /dev/tpm0)"
      
      * 'fixes-v5.1' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/linux-security:
        selftests/tpm2: Open tpm dev in unbuffered mode
        selftests/tpm2: Extend tests to cover partial reads
        KEYS: trusted: fix -Wvarags warning
        tpm: Fix the type of the return value in calc_tpm2_event_size()
        KEYS: trusted: allow trusted.ko to initialize w/o a TPM
        tpm: fix an invalid condition in tpm_common_poll
        tpm: turn on TPM on suspend for TPM 1.x
      a556810d
    • Linus Torvalds's avatar
      Merge tag 'xtensa-20190408' of git://github.com/jcmvbkbc/linux-xtensa · 10d43397
      Linus Torvalds authored
      Pull xtensa fixes from Max Filippov:
      
       - fix syscall number passed to trace_sys_exit
      
       - fix syscall number initialization in start_thread
      
       - fix level interpretation in the return_address
      
       - fix format string warning in init_pmd
      
      * tag 'xtensa-20190408' of git://github.com/jcmvbkbc/linux-xtensa:
        xtensa: fix format string warning in init_pmd
        xtensa: fix return_address
        xtensa: fix initialization of pt_regs::syscall in start_thread
        xtensa: use actual syscall number in do_syscall_trace_leave
      10d43397
  3. 08 Apr, 2019 25 commits
  4. 07 Apr, 2019 8 commits
    • Linus Torvalds's avatar
      Merge tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc · d8491223
      Linus Torvalds authored
      Pull ARM SoC fixes from Olof Johansson:
       "A collection of fixes from the last few weeks. Most of them are
        smaller tweaks and fixes to DT and hardware descriptions for boards.
        Some of the more significant ones are:
      
         - eMMC and RGMII stability tweaks for rk3288
      
         - DDC fixes for Rock PI 4
      
         - Audio fixes for two TI am335x eval boards
      
         - D_CAN clock fix for am335x
      
         - Compilation fixes for clang
      
         - !HOTPLUG_CPU compilation fix for one of the new platforms this
           release (milbeaut)
      
         - A revert of a gpio fix for nomadik that instead was fixed in the
           gpio subsystem
      
         - Whitespace fix for the DT JSON schema (no tabs allowed)"
      
      * tag 'armsoc-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (25 commits)
        ARM: milbeaut: fix build with !CONFIG_HOTPLUG_CPU
        ARM: iop: don't use using 64-bit DMA masks
        ARM: orion: don't use using 64-bit DMA masks
        Revert "ARM: dts: nomadik: Fix polarity of SPI CS"
        dt-bindings: cpu: Fix JSON schema
        arm/mach-at91/pm : fix possible object reference leak
        ARM: dts: at91: Fix typo in ISC_D0 on PC9
        ARM: dts: Fix dcan clkctrl clock for am3
        reset: meson-audio-arb: Fix missing .owner setting of reset_controller_dev
        dt-bindings: reset: meson-g12a: Add missing USB2 PHY resets
        ARM: dts: rockchip: Remove #address/#size-cells from rk3288-veyron gpio-keys
        ARM: dts: rockchip: Remove #address/#size-cells from rk3288 mipi_dsi
        ARM: dts: rockchip: Fix gpu opp node names for rk3288
        ARM: dts: am335x-evmsk: Correct the regulators for the audio codec
        ARM: dts: am335x-evm: Correct the regulators for the audio codec
        ARM: OMAP2+: add missing of_node_put after of_device_is_available
        ARM: OMAP1: ams-delta: Fix broken GPIO ID allocation
        arm64: dts: stratix10: add the sysmgr-syscon property from the gmac's
        arm64: dts: rockchip: fix rk3328 sdmmc0 write errors
        arm64: dts: rockchip: fix rk3328 rgmii high tx error rate
        ...
      d8491223
    • Linus Torvalds's avatar
      Merge tag 'for-linus-20190407' of git://git.kernel.dk/linux-block · 429fba10
      Linus Torvalds authored
      Pull block fixes from Jens Axboe:
      
       - Fixups for the pf/pcd queue handling (YueHaibing)
      
       - Revert of the three direct issue changes as they have been proven to
         cause an issue with dm-mpath (Bart)
      
       - Plug rq_count reset fix (Dongli)
      
       - io_uring double free in fileset registration error handling (me)
      
       - Make null_blk handle bad numa node passed in (John)
      
       - BFQ ifdef fix (Konstantin)
      
       - Flush queue leak fix (Shenghui)
      
       - Plug trace fix (Yufen)
      
      * tag 'for-linus-20190407' of git://git.kernel.dk/linux-block:
        xsysace: Fix error handling in ace_setup
        null_blk: prevent crash from bad home_node value
        block: Revert v5.0 blk_mq_request_issue_directly() changes
        paride/pcd: Fix potential NULL pointer dereference and mem leak
        blk-mq: do not reset plug->rq_count before the list is sorted
        paride/pf: Fix potential NULL pointer dereference
        io_uring: fix double free in case of fileset regitration failure
        blk-mq: add trace block plug and unplug for multiple queues
        block: use blk_free_flush_queue() to free hctx->fq in blk_mq_init_hctx
        block/bfq: fix ifdef for CONFIG_BFQ_GROUP_IOSCHED=y
      429fba10
    • Arnd Bergmann's avatar
      ARM: milbeaut: fix build with !CONFIG_HOTPLUG_CPU · 9a8f3203
      Arnd Bergmann authored
      When HOTPLUG_CPU is disabled, some fields in the smp operations
      are not available or needed:
      
      arch/arm/mach-milbeaut/platsmp.c:90:3: error: field designator 'cpu_die' does not refer to any field in type
            'struct smp_operations'
              .cpu_die                = m10v_cpu_die,
               ^
      arch/arm/mach-milbeaut/platsmp.c:91:3: error: field designator 'cpu_kill' does not refer to any field in type
            'struct smp_operations'
              .cpu_kill               = m10v_cpu_kill,
               ^
      
      Hide them in an #ifdef like the other platforms do.
      
      Fixes: 9fb29c73 ("ARM: milbeaut: Add basic support for Milbeaut m10v SoC")
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      9a8f3203
    • Arnd Bergmann's avatar
      ARM: iop: don't use using 64-bit DMA masks · 2125801c
      Arnd Bergmann authored
      clang warns about statically defined DMA masks from the DMA_BIT_MASK
      macro with length 64:
      
       arch/arm/mach-iop13xx/setup.c:303:35: error: shift count >= width of type [-Werror,-Wshift-count-overflow]
       static u64 iop13xx_adma_dmamask = DMA_BIT_MASK(64);
                                        ^~~~~~~~~~~~~~~~
       include/linux/dma-mapping.h:141:54: note: expanded from macro 'DMA_BIT_MASK'
       #define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
                                                            ^ ~~~
      
      The ones in iop shouldn't really be 64 bit masks, so changing them
      to what the driver can support avoids the warning.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      2125801c
    • Arnd Bergmann's avatar
      ARM: orion: don't use using 64-bit DMA masks · cd92d74d
      Arnd Bergmann authored
      clang warns about statically defined DMA masks from the DMA_BIT_MASK
      macro with length 64:
      
      arch/arm/plat-orion/common.c:625:29: error: shift count >= width of type [-Werror,-Wshift-count-overflow]
                      .coherent_dma_mask      = DMA_BIT_MASK(64),
                                                ^~~~~~~~~~~~~~~~
      include/linux/dma-mapping.h:141:54: note: expanded from macro 'DMA_BIT_MASK'
       #define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
      
      The ones in orion shouldn't really be 64 bit masks, so changing them
      to what the driver can support avoids the warning.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      cd92d74d
    • Olof Johansson's avatar
      Revert "ARM: dts: nomadik: Fix polarity of SPI CS" · fbe8758f
      Olof Johansson authored
      This reverts commit fa946356.
      
      Per Linus Walleij:
      
      Dear ARM SoC maintainers,
      
      can you please revert this patch. It was the wrong solution to the
      wrong problem, and I must have acted in stress. Andrey fixed the
      real bug in a proper way in these commits:
      
      commit e5545c94
      "gpio: of: Check propname before applying "cs-gpios" quirks"
      commit 7ce40277
      "gpio: of: Check for "spi-cs-high" in child instead of parent node"
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      fbe8758f
    • Olof Johansson's avatar
      Merge tag 'omap-for-v5.1/fixes-signed' of... · c983f102
      Olof Johansson authored
      Merge tag 'omap-for-v5.1/fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap into arm/fixes
      
      Fixes for omaps for v5.1-rc cycle
      
      Few small fixes for omap variants:
      
      - Fix ams-delta gpio IDs
      - Add missing of_node_put for omapdss platform init code
      - Fix unconfigured audio regulators for two am335x boards
      - Fix use of wrong offset for am335x d_can clocks
      
      * tag 'omap-for-v5.1/fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap:
        ARM: dts: Fix dcan clkctrl clock for am3
        ARM: dts: am335x-evmsk: Correct the regulators for the audio codec
        ARM: dts: am335x-evm: Correct the regulators for the audio codec
        ARM: OMAP2+: add missing of_node_put after of_device_is_available
        ARM: OMAP1: ams-delta: Fix broken GPIO ID allocation
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      c983f102
    • Olof Johansson's avatar
      Merge tag 'at91-5.1-fixes' of... · fccf5166
      Olof Johansson authored
      Merge tag 'at91-5.1-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/at91/linux into arm/fixes
      
      AT91 fixes for 5.1
      
      - fix a typo in sama5d2 pinmuxing which concerns the ISC data 0 signal
      - fix a kobject reference leak
      
      * tag 'at91-5.1-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/at91/linux:
        arm/mach-at91/pm : fix possible object reference leak
        ARM: dts: at91: Fix typo in ISC_D0 on PC9
      Signed-off-by: default avatarOlof Johansson <olof@lixom.net>
      fccf5166