1. 19 Nov, 2020 8 commits
    • Linus Torvalds's avatar
      Merge tag 'xtensa-20201119' of git://github.com/jcmvbkbc/linux-xtensa · 3494d588
      Linus Torvalds authored
      Pull xtensa fixes from Max Filippov:
      
       - fix placement of cache alias remapping area
      
       - disable preemption around cache alias management calls
      
       - add missing __user annotation to strncpy_from_user argument
      
      * tag 'xtensa-20201119' of git://github.com/jcmvbkbc/linux-xtensa:
        xtensa: uaccess: Add missing __user to strncpy_from_user() prototype
        xtensa: disable preemption around cache alias management calls
        xtensa: fix TLBTEMP area placement
      3494d588
    • Linus Torvalds's avatar
      Merge tag 'acpi-5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 131ad0b6
      Linus Torvalds authored
      Pull ACPI fixes from Rafael Wysocki:
       "These fix recent regression in the APEI code and initialization issue
        in the ACPI fan driver.
      
        Specifics:
      
         - Make the APEI code avoid attempts to obtain logical addresses for
           registers located in the I/O address space to fix initialization
           issues (Aili Yao)
      
         - Fix sysfs attribute initialization in the ACPI fan driver (Guenter
           Roeck)"
      
      * tag 'acpi-5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        ACPI, APEI, Fix error return value in apei_map_generic_address()
        ACPI: fan: Initialize performance state sysfs attribute
      131ad0b6
    • Linus Torvalds's avatar
      Merge tag 'pm-5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm · 4ca35b4f
      Linus Torvalds authored
      Pull power management fixes from Rafael Wysocki:
       "These fix two issues in ARM cpufreq drivers and one cpuidle driver
        issue.
      
        Specifics:
      
         - Add missing RCU_NONIDLE() annotations to the Tegra cpuidle driver
           (Dmitry Osipenko)
      
         - Fix boot frequency computation in the tegra186 cpufreq driver (Jon
           Hunter)
      
         - Make the SCMI cpufreq driver register a dummy clock provider to
           avoid OPP addition failures (Sudeep Holla)"
      
      * tag 'pm-5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
        cpufreq: scmi: Fix OPP addition failure with a dummy clock provider
        cpufreq: tegra186: Fix get frequency callback
        cpuidle: tegra: Annotate tegra_pm_set_cpu_in_lp2() with RCU_NONIDLE
      4ca35b4f
    • Linus Torvalds's avatar
      Merge tag 'spi-fix-v5.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi · fee3c824
      Linus Torvalds authored
      Pull spi fixes from Mark Brown:
       "This is a relatively large set of fixes, the bulk of it being a series
        from Lukas Wunner which fixes confusion with the lifetime of driver
        data allocated along with the SPI controller structure that's been
        created as part of the conversion to devm APIs.
      
        The simplest fix, explained in detail in Lukas' commit message, is to
        move to a devm_ function for allocation of the controller and hence
        driver data in order to push the free of that after anything tries to
        reference the driver data in the remove path. This results in a
        relatively large diff due to the addition of a new function but isn't
        particularly complex.
      
        There's also a fix from Sven van Asbroeck which fixes yet more fallout
        from the conflicts between the various different places one can
        configure the polarity of GPIOs in modern systems.
      
        Otherwise everything is fairly small and driver specific"
      
      * tag 'spi-fix-v5.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi:
        spi: npcm-fiu: Don't leak SPI master in probe error path
        spi: dw: Set transfer handler before unmasking the IRQs
        spi: cadence-quadspi: Fix error return code in cqspi_probe
        spi: bcm2835aux: Restore err assignment in bcm2835aux_spi_probe
        spi: lpspi: Fix use-after-free on unbind
        spi: bcm-qspi: Fix use-after-free on unbind
        spi: bcm2835aux: Fix use-after-free on unbind
        spi: bcm2835: Fix use-after-free on unbind
        spi: Introduce device-managed SPI controller allocation
        spi: fsi: Fix transfer returning without finalizing message
        spi: fix client driver breakages when using GPIO descriptors
      fee3c824
    • Linus Torvalds's avatar
      Merge tag 'regulator-fix-v5.10-rc4' of... · d748287a
      Linus Torvalds authored
      Merge tag 'regulator-fix-v5.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator
      
      Pull regulator fixes from Mark Brown:
       "Mostly core fixes here, one set from Michał Mirosław which cleans up
        some issues introduced as part of the coupled regulators work, one
        memory leak during probe and two due to regulators which have an input
        supply name and regulator name which are identical, which is very
        unusual.
      
        There's also a fix for our handling of the similarly unusual case
        where we can't determine if a regulator is enabled during boot"
      
      * tag 'regulator-fix-v5.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator:
        regulator: ti-abb: Fix array out of bound read access on the first transition
        regulator: workaround self-referent regulators
        regulator: avoid resolve_supply() infinite recursion
        regulator: fix memory leak with repeated set_machine_constraints()
        regulator: pfuze100: limit pfuze-support-disable-sw to pfuze{100,200}
        regulator: core: don't disable regulator if is_enabled return error.
      d748287a
    • Linus Torvalds's avatar
      Merge tag 'thermal-v5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/thermal/linux · 841d6e9e
      Linus Torvalds authored
      Pull thermal fix from Daniel Lezcano:
       "Disable the CPU PM notifier for OMAP4430 for suspend in order to
        prevent wrong temperature leading to a critical shutdown (Peter
        Ujfalusi)"
      
      * tag 'thermal-v5.10-rc5' of git://git.kernel.org/pub/scm/linux/kernel/git/thermal/linux:
        thermal: ti-soc-thermal: Disable the CPU PM notifier for OMAP4430
      841d6e9e
    • Rafael J. Wysocki's avatar
      Merge branch 'acpi-fan' · de15e20f
      Rafael J. Wysocki authored
      * acpi-fan:
        ACPI: fan: Initialize performance state sysfs attribute
      de15e20f
    • Rafael J. Wysocki's avatar
      Merge branch 'pm-cpuidle' · 3a8ac4d3
      Rafael J. Wysocki authored
      * pm-cpuidle:
        cpuidle: tegra: Annotate tegra_pm_set_cpu_in_lp2() with RCU_NONIDLE
      3a8ac4d3
  2. 18 Nov, 2020 5 commits
  3. 17 Nov, 2020 13 commits
  4. 16 Nov, 2020 14 commits
    • Linus Torvalds's avatar
      Merge tag 'arm-soc-fixes-v5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc · 9c87c9f4
      Linus Torvalds authored
      Pull ARM SoC fixes from Arnd Bergmann:
       "Around one third of the fixes this time are for dts files that list
        their ethernet controller as using 'phy-mode="rgmii"' but are changed
        to 'phy-mode="rgmii-id"' now, because the PHY drivers (realtek,
        ksz9031, dp83867, ...) now configure the internal delay based on that
        when they used to stay on the hardware default.
      
        The long story is archived at
      
          https://lore.kernel.org/netdev/CAMj1kXEEF_Un-4NTaD5iUN0NoZYaJQn-rPediX0S6oRiuVuW-A@mail.gmail.com/
      
        I was trying to hold off on the bugfixes until there was a solution
        that would avoid breaking all boards, but that does not seem to be
        happening any time soon, so I am now sending the correct version of
        the dts files to ensure that at least these machines can use their
        network devices again.
      
        The other changes this time are:
      
         - Updating the MAINTAINER lists for Allwinner and Samsung SoCs
      
         - Multiple i.MX8MN machines get updates for their CPU operating
           points to match the data sheet
      
         - A revert for a dts patch that caused a regression in USB support on
           Odroid U3
      
         - Two fixes for the AMD Tee driver, addressing a memory leak and
           missing locking
      
         - Mark the network subsystem on qoriq-fman3 as cache coherent for
           correctness as better performance.
      
         - Minor dts fixes elsewhere, addressing dtc warnings and similar
           problems"
      
      * tag 'arm-soc-fixes-v5.10-2' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: (48 commits)
        ARM: dts: exynos: revert "add input clock to CMU in Exynos4412 Odroid"
        ARM: dts: imx50-evk: Fix the chip select 1 IOMUX
        arm64: dts: imx8mm: fix voltage for 1.6GHz CPU operating point
        ARM: dts: stm32: Keep VDDA LDO1 always on on DHCOM
        ARM: dts: stm32: Enable thermal sensor support on stm32mp15xx-dhcor
        ARM: dts: stm32: Define VIO regulator supply on DHCOM
        ARM: dts: stm32: Fix LED5 on STM32MP1 DHCOM PDK2
        ARM: dts: stm32: Fix TA3-GPIO-C key on STM32MP1 DHCOM PDK2
        arm64: dts: renesas: r8a774e1: Add missing audio_clk_b
        tee: amdtee: synchronize access to shm list
        tee: amdtee: fix memory leak due to reset of global shm list
        arm64: dts: agilex/stratix10: Fix qspi node compatible
        ARM: dts: imx6q-prti6q: fix PHY address
        ARM: dts: vf610-zii-dev-rev-b: Fix MDIO over clocking
        arm: dts: imx6qdl-udoo: fix rgmii phy-mode for ksz9031 phy
        arm64: dts imx8mn: Remove non-existent USB OTG2
        arm64: dts: imx8mm-beacon-som: Fix Choppy BT audio
        arm64: dts: fsl: DPAA FMan DMA operations are coherent
        arm64: dts: fsl: fix endianness issue of rcpm
        arm64: dts: imx8mn-evk: fix missing PMIC's interrupt line pull-up
        ...
      9c87c9f4
    • Linus Torvalds's avatar
      Merge tag 'hyperv-fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux · a5698b38
      Linus Torvalds authored
      Pull Hyper-V fix from Wei Liu:
       "One patch from Chris to fix kexec on Hyper-V"
      
      * tag 'hyperv-fixes-signed' of git://git.kernel.org/pub/scm/linux/kernel/git/hyperv/linux:
        Drivers: hv: vmbus: Allow cleanup of VMBUS_CONNECT_CPU if disconnected
      a5698b38
    • Linus Torvalds's avatar
      Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost · a08f4523
      Linus Torvalds authored
      Pull vhost fixes from Michael Tsirkin:
       "Fixes all over the place, most notably vhost scsi IO error fixes"
      
      * tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost:
        vhost scsi: Add support for LUN resets.
        vhost scsi: add lun parser helper
        vhost scsi: fix cmd completion race
        vhost scsi: alloc cmds per vq instead of session
        vhost: add helper to check if a vq has been setup
        vdpasim: fix "mac_pton" undefined error
        swiotlb: using SIZE_MAX needs limits.h included
      a08f4523
    • Zhihao Cheng's avatar
      spi: cadence-quadspi: Fix error return code in cqspi_probe · ac9978fc
      Zhihao Cheng authored
      Fix to return the error code from
      devm_reset_control_get_optional_exclusive() instaed of 0
      in cqspi_probe().
      
      Fixes: 31fb632b ("spi: Move cadence-quadspi driver to drivers/spi/")
      Reported-by: default avatarHulk Robot <hulkci@huawei.com>
      Signed-off-by: default avatarZhihao Cheng <chengzhihao1@huawei.com>
      Reviewed-by: default avatarPhilipp Zabel <p.zabel@pengutronix.de>
      Link: https://lore.kernel.org/r/20201116141836.2970579-1-chengzhihao1@huawei.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
      ac9978fc
    • Aili Yao's avatar
      ACPI, APEI, Fix error return value in apei_map_generic_address() · 4fba15fb
      Aili Yao authored
      From commit 6915564d ("ACPI: OSL: Change the type of
      acpi_os_map_generic_address() return value"),
      acpi_os_map_generic_address() will return logical address or NULL
      for error, but for ACPI_ADR_SPACE_SYSTEM_IO case, it should be also
      return 0 as it's a normal case, but now it will return -ENXIO.
      
      So check it out for such case to avoid einj module initialization
      fail.
      
      Fixes: 6915564d ("ACPI: OSL: Change the type of acpi_os_map_generic_address() return value")
      Cc: <stable@vger.kernel.org>
      Reviewed-by: default avatarJames Morse <james.morse@arm.com>
      Tested-by: default avatarTony Luck <tony.luck@intel.com>
      Signed-off-by: default avatarAili Yao <yaoaili@kingsoft.com>
      Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
      4fba15fb
    • Ian Rogers's avatar
      perf test: Avoid an msan warning in a copied stack. · 568beb27
      Ian Rogers authored
      This fix is for a failure that occurred in the DWARF unwind perf test.
      
      Stack unwinders may probe memory when looking for frames.
      
      Memory sanitizer will poison and track uninitialized memory on the
      stack, and on the heap if the value is copied to the heap.
      
      This can lead to false memory sanitizer failures for the use of an
      uninitialized value.
      
      Avoid this problem by removing the poison on the copied stack.
      
      The full msan failure with track origins looks like:
      
      ==2168==WARNING: MemorySanitizer: use-of-uninitialized-value
          #0 0x559ceb10755b in handle_cfi elfutils/libdwfl/frame_unwind.c:648:8
          #1 0x559ceb105448 in __libdwfl_frame_unwind elfutils/libdwfl/frame_unwind.c:741:4
          #2 0x559ceb0ece90 in dwfl_thread_getframes elfutils/libdwfl/dwfl_frame.c:435:7
          #3 0x559ceb0ec6b7 in get_one_thread_frames_cb elfutils/libdwfl/dwfl_frame.c:379:10
          #4 0x559ceb0ec6b7 in get_one_thread_cb elfutils/libdwfl/dwfl_frame.c:308:17
          #5 0x559ceb0ec6b7 in dwfl_getthreads elfutils/libdwfl/dwfl_frame.c:283:17
          #6 0x559ceb0ec6b7 in getthread elfutils/libdwfl/dwfl_frame.c:354:14
          #7 0x559ceb0ec6b7 in dwfl_getthread_frames elfutils/libdwfl/dwfl_frame.c:388:10
          #8 0x559ceaff6ae6 in unwind__get_entries tools/perf/util/unwind-libdw.c:236:8
          #9 0x559ceabc9dbc in test_dwarf_unwind__thread tools/perf/tests/dwarf-unwind.c:111:8
          #10 0x559ceabca5cf in test_dwarf_unwind__compare tools/perf/tests/dwarf-unwind.c:138:26
          #11 0x7f812a6865b0 in bsearch (libc.so.6+0x4e5b0)
          #12 0x559ceabca871 in test_dwarf_unwind__krava_3 tools/perf/tests/dwarf-unwind.c:162:2
          #13 0x559ceabca926 in test_dwarf_unwind__krava_2 tools/perf/tests/dwarf-unwind.c:169:9
          #14 0x559ceabca946 in test_dwarf_unwind__krava_1 tools/perf/tests/dwarf-unwind.c:174:9
          #15 0x559ceabcae12 in test__dwarf_unwind tools/perf/tests/dwarf-unwind.c:211:8
          #16 0x559ceabbc4ab in run_test tools/perf/tests/builtin-test.c:418:9
          #17 0x559ceabbc4ab in test_and_print tools/perf/tests/builtin-test.c:448:9
          #18 0x559ceabbac70 in __cmd_test tools/perf/tests/builtin-test.c:669:4
          #19 0x559ceabbac70 in cmd_test tools/perf/tests/builtin-test.c:815:9
          #20 0x559cea960e30 in run_builtin tools/perf/perf.c:313:11
          #21 0x559cea95fbce in handle_internal_command tools/perf/perf.c:365:8
          #22 0x559cea95fbce in run_argv tools/perf/perf.c:409:2
          #23 0x559cea95fbce in main tools/perf/perf.c:539:3
      
        Uninitialized value was stored to memory at
          #0 0x559ceb106acf in __libdwfl_frame_reg_set elfutils/libdwfl/frame_unwind.c:77:22
          #1 0x559ceb106acf in handle_cfi elfutils/libdwfl/frame_unwind.c:627:13
          #2 0x559ceb105448 in __libdwfl_frame_unwind elfutils/libdwfl/frame_unwind.c:741:4
          #3 0x559ceb0ece90 in dwfl_thread_getframes elfutils/libdwfl/dwfl_frame.c:435:7
          #4 0x559ceb0ec6b7 in get_one_thread_frames_cb elfutils/libdwfl/dwfl_frame.c:379:10
          #5 0x559ceb0ec6b7 in get_one_thread_cb elfutils/libdwfl/dwfl_frame.c:308:17
          #6 0x559ceb0ec6b7 in dwfl_getthreads elfutils/libdwfl/dwfl_frame.c:283:17
          #7 0x559ceb0ec6b7 in getthread elfutils/libdwfl/dwfl_frame.c:354:14
          #8 0x559ceb0ec6b7 in dwfl_getthread_frames elfutils/libdwfl/dwfl_frame.c:388:10
          #9 0x559ceaff6ae6 in unwind__get_entries tools/perf/util/unwind-libdw.c:236:8
          #10 0x559ceabc9dbc in test_dwarf_unwind__thread tools/perf/tests/dwarf-unwind.c:111:8
          #11 0x559ceabca5cf in test_dwarf_unwind__compare tools/perf/tests/dwarf-unwind.c:138:26
          #12 0x7f812a6865b0 in bsearch (libc.so.6+0x4e5b0)
          #13 0x559ceabca871 in test_dwarf_unwind__krava_3 tools/perf/tests/dwarf-unwind.c:162:2
          #14 0x559ceabca926 in test_dwarf_unwind__krava_2 tools/perf/tests/dwarf-unwind.c:169:9
          #15 0x559ceabca946 in test_dwarf_unwind__krava_1 tools/perf/tests/dwarf-unwind.c:174:9
          #16 0x559ceabcae12 in test__dwarf_unwind tools/perf/tests/dwarf-unwind.c:211:8
          #17 0x559ceabbc4ab in run_test tools/perf/tests/builtin-test.c:418:9
          #18 0x559ceabbc4ab in test_and_print tools/perf/tests/builtin-test.c:448:9
          #19 0x559ceabbac70 in __cmd_test tools/perf/tests/builtin-test.c:669:4
          #20 0x559ceabbac70 in cmd_test tools/perf/tests/builtin-test.c:815:9
          #21 0x559cea960e30 in run_builtin tools/perf/perf.c:313:11
          #22 0x559cea95fbce in handle_internal_command tools/perf/perf.c:365:8
          #23 0x559cea95fbce in run_argv tools/perf/perf.c:409:2
          #24 0x559cea95fbce in main tools/perf/perf.c:539:3
      
        Uninitialized value was stored to memory at
          #0 0x559ceb106a54 in handle_cfi elfutils/libdwfl/frame_unwind.c:613:9
          #1 0x559ceb105448 in __libdwfl_frame_unwind elfutils/libdwfl/frame_unwind.c:741:4
          #2 0x559ceb0ece90 in dwfl_thread_getframes elfutils/libdwfl/dwfl_frame.c:435:7
          #3 0x559ceb0ec6b7 in get_one_thread_frames_cb elfutils/libdwfl/dwfl_frame.c:379:10
          #4 0x559ceb0ec6b7 in get_one_thread_cb elfutils/libdwfl/dwfl_frame.c:308:17
          #5 0x559ceb0ec6b7 in dwfl_getthreads elfutils/libdwfl/dwfl_frame.c:283:17
          #6 0x559ceb0ec6b7 in getthread elfutils/libdwfl/dwfl_frame.c:354:14
          #7 0x559ceb0ec6b7 in dwfl_getthread_frames elfutils/libdwfl/dwfl_frame.c:388:10
          #8 0x559ceaff6ae6 in unwind__get_entries tools/perf/util/unwind-libdw.c:236:8
          #9 0x559ceabc9dbc in test_dwarf_unwind__thread tools/perf/tests/dwarf-unwind.c:111:8
          #10 0x559ceabca5cf in test_dwarf_unwind__compare tools/perf/tests/dwarf-unwind.c:138:26
          #11 0x7f812a6865b0 in bsearch (libc.so.6+0x4e5b0)
          #12 0x559ceabca871 in test_dwarf_unwind__krava_3 tools/perf/tests/dwarf-unwind.c:162:2
          #13 0x559ceabca926 in test_dwarf_unwind__krava_2 tools/perf/tests/dwarf-unwind.c:169:9
          #14 0x559ceabca946 in test_dwarf_unwind__krava_1 tools/perf/tests/dwarf-unwind.c:174:9
          #15 0x559ceabcae12 in test__dwarf_unwind tools/perf/tests/dwarf-unwind.c:211:8
          #16 0x559ceabbc4ab in run_test tools/perf/tests/builtin-test.c:418:9
          #17 0x559ceabbc4ab in test_and_print tools/perf/tests/builtin-test.c:448:9
          #18 0x559ceabbac70 in __cmd_test tools/perf/tests/builtin-test.c:669:4
          #19 0x559ceabbac70 in cmd_test tools/perf/tests/builtin-test.c:815:9
          #20 0x559cea960e30 in run_builtin tools/perf/perf.c:313:11
          #21 0x559cea95fbce in handle_internal_command tools/perf/perf.c:365:8
          #22 0x559cea95fbce in run_argv tools/perf/perf.c:409:2
          #23 0x559cea95fbce in main tools/perf/perf.c:539:3
      
        Uninitialized value was stored to memory at
          #0 0x559ceaff8800 in memory_read tools/perf/util/unwind-libdw.c:156:10
          #1 0x559ceb10f053 in expr_eval elfutils/libdwfl/frame_unwind.c:501:13
          #2 0x559ceb1060cc in handle_cfi elfutils/libdwfl/frame_unwind.c:603:18
          #3 0x559ceb105448 in __libdwfl_frame_unwind elfutils/libdwfl/frame_unwind.c:741:4
          #4 0x559ceb0ece90 in dwfl_thread_getframes elfutils/libdwfl/dwfl_frame.c:435:7
          #5 0x559ceb0ec6b7 in get_one_thread_frames_cb elfutils/libdwfl/dwfl_frame.c:379:10
          #6 0x559ceb0ec6b7 in get_one_thread_cb elfutils/libdwfl/dwfl_frame.c:308:17
          #7 0x559ceb0ec6b7 in dwfl_getthreads elfutils/libdwfl/dwfl_frame.c:283:17
          #8 0x559ceb0ec6b7 in getthread elfutils/libdwfl/dwfl_frame.c:354:14
          #9 0x559ceb0ec6b7 in dwfl_getthread_frames elfutils/libdwfl/dwfl_frame.c:388:10
          #10 0x559ceaff6ae6 in unwind__get_entries tools/perf/util/unwind-libdw.c:236:8
          #11 0x559ceabc9dbc in test_dwarf_unwind__thread tools/perf/tests/dwarf-unwind.c:111:8
          #12 0x559ceabca5cf in test_dwarf_unwind__compare tools/perf/tests/dwarf-unwind.c:138:26
          #13 0x7f812a6865b0 in bsearch (libc.so.6+0x4e5b0)
          #14 0x559ceabca871 in test_dwarf_unwind__krava_3 tools/perf/tests/dwarf-unwind.c:162:2
          #15 0x559ceabca926 in test_dwarf_unwind__krava_2 tools/perf/tests/dwarf-unwind.c:169:9
          #16 0x559ceabca946 in test_dwarf_unwind__krava_1 tools/perf/tests/dwarf-unwind.c:174:9
          #17 0x559ceabcae12 in test__dwarf_unwind tools/perf/tests/dwarf-unwind.c:211:8
          #18 0x559ceabbc4ab in run_test tools/perf/tests/builtin-test.c:418:9
          #19 0x559ceabbc4ab in test_and_print tools/perf/tests/builtin-test.c:448:9
          #20 0x559ceabbac70 in __cmd_test tools/perf/tests/builtin-test.c:669:4
          #21 0x559ceabbac70 in cmd_test tools/perf/tests/builtin-test.c:815:9
          #22 0x559cea960e30 in run_builtin tools/perf/perf.c:313:11
          #23 0x559cea95fbce in handle_internal_command tools/perf/perf.c:365:8
          #24 0x559cea95fbce in run_argv tools/perf/perf.c:409:2
          #25 0x559cea95fbce in main tools/perf/perf.c:539:3
      
        Uninitialized value was stored to memory at
          #0 0x559cea9027d9 in __msan_memcpy llvm/llvm-project/compiler-rt/lib/msan/msan_interceptors.cpp:1558:3
          #1 0x559cea9d2185 in sample_ustack tools/perf/arch/x86/tests/dwarf-unwind.c:41:2
          #2 0x559cea9d202c in test__arch_unwind_sample tools/perf/arch/x86/tests/dwarf-unwind.c:72:9
          #3 0x559ceabc9cbd in test_dwarf_unwind__thread tools/perf/tests/dwarf-unwind.c:106:6
          #4 0x559ceabca5cf in test_dwarf_unwind__compare tools/perf/tests/dwarf-unwind.c:138:26
          #5 0x7f812a6865b0 in bsearch (libc.so.6+0x4e5b0)
          #6 0x559ceabca871 in test_dwarf_unwind__krava_3 tools/perf/tests/dwarf-unwind.c:162:2
          #7 0x559ceabca926 in test_dwarf_unwind__krava_2 tools/perf/tests/dwarf-unwind.c:169:9
          #8 0x559ceabca946 in test_dwarf_unwind__krava_1 tools/perf/tests/dwarf-unwind.c:174:9
          #9 0x559ceabcae12 in test__dwarf_unwind tools/perf/tests/dwarf-unwind.c:211:8
          #10 0x559ceabbc4ab in run_test tools/perf/tests/builtin-test.c:418:9
          #11 0x559ceabbc4ab in test_and_print tools/perf/tests/builtin-test.c:448:9
          #12 0x559ceabbac70 in __cmd_test tools/perf/tests/builtin-test.c:669:4
          #13 0x559ceabbac70 in cmd_test tools/perf/tests/builtin-test.c:815:9
          #14 0x559cea960e30 in run_builtin tools/perf/perf.c:313:11
          #15 0x559cea95fbce in handle_internal_command tools/perf/perf.c:365:8
          #16 0x559cea95fbce in run_argv tools/perf/perf.c:409:2
          #17 0x559cea95fbce in main tools/perf/perf.c:539:3
      
        Uninitialized value was created by an allocation of 'bf' in the stack frame of function 'perf_event__synthesize_mmap_events'
          #0 0x559ceafc5f60 in perf_event__synthesize_mmap_events tools/perf/util/synthetic-events.c:445
      
      SUMMARY: MemorySanitizer: use-of-uninitialized-value elfutils/libdwfl/frame_unwind.c:648:8 in handle_cfi
      Signed-off-by: default avatarIan Rogers <irogers@google.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: clang-built-linux@googlegroups.com
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Sandeep Dasgupta <sdasgup@google.com>
      Cc: Stephane Eranian <eranian@google.com>
      Link: http://lore.kernel.org/lkml/20201113182053.754625-1-irogers@google.comSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      568beb27
    • Al Grant's avatar
      perf inject: Fix file corruption due to event deletion · 1c756cd4
      Al Grant authored
      "perf inject" can create corrupt files when synthesizing sample events from AUX
      data. This happens when in the input file, the first event (for the AUX data)
      has a different sample_type from the second event (generally dummy).
      
      Specifically, they differ in the bits that indicate the standard fields
      appended to perf records in the mmap buffer. "perf inject" deletes the first
      event and moves up the second event to first position.
      
      The problem is with the synthetic PERF_RECORD_MMAP (etc.) events created
      by "perf record".
      
      Since these are synthetic versions of events which are normally produced
      by the kernel, they have to have the standard fields appended as
      described by sample_type.
      
      "perf record" fills these in with zeroes, including the IDENTIFIER
      field; perf readers interpret records with zero IDENTIFIER using the
      descriptor for the first event in the file.
      
      Since "perf inject" changes the first event, these synthetic records are
      then processed with the wrong value of sample_type, and the perf reader
      reads bad data, reports on incorrect length records etc.
      
      Mismatching sample_types are seen with "perf record -e cs_etm//", where the AUX
      event has TID|TIME|CPU|IDENTIFIER and the dummy event has TID|TIME|IDENTIFIER.
      
      Perhaps they could be the same, but it isn't normally a problem if they aren't
      - perf has no problems reading the file.
      
      The sample_types have to agree on the position of IDENTIFIER, because
      that's how perf finds the right event descriptor in the first place, but
      they don't normally have to agree on other fields, and perf doesn't
      check that they do.
      
      The problem is specific to the way "perf inject" reorganizes the events
      and the way synthetic MMAP events are recorded with a zero identifier. A
      simple solution is to stop "perf inject" deleting the tracing event.
      
      Committer testing
      
      Removed the now unused 'evsel' variable, update the comment about the
      evsel removal not being performed anymore, and apply the patch manually
      as it failed with this warning:
      
        warning: Patch sent with format=flowed; space at the end of lines might be lost.
      
      Testing it with:
      
        $ perf bench internals inject-build-id
        # Running 'internals/inject-build-id' benchmark:
          Average build-id injection took: 8.543 msec (+- 0.130 msec)
          Average time per event: 0.838 usec (+- 0.013 usec)
          Average memory usage: 12717 KB (+- 9 KB)
          Average build-id-all injection took: 5.710 msec (+- 0.058 msec)
          Average time per event: 0.560 usec (+- 0.006 usec)
          Average memory usage: 12079 KB (+- 7 KB)
        $
      Signed-off-by: default avatarAl Grant <al.grant@arm.com>
      Acked-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
      Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      LPU-Reference: b9cf5611-daae-2390-3439-6617f8f0a34b@foss.arm.com
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      1c756cd4
    • Arnd Bergmann's avatar
      Merge tag 'imx-fixes-5.10-4' of... · cc05af8e
      Arnd Bergmann authored
      Merge tag 'imx-fixes-5.10-4' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux into arm/fixes
      
      i.MX fixes for 5.10, round 4:
      
      - Fix MDIO over clocking on vf610-zii-dev-rev-b board to get switch
        device work reliably.
      - Fix imx50-evk IOMUX for the chip select 1 to use GPIO4_13 instead of
        the native CSPI_SSI function.
      - Fix voltage for 1.6GHz CPU operating point on i.MX8MM to match
        hardware datasheet.
      - Fix phy-mode for KSZ9031 PHY on imx6qdl-udoo board.
      
      * tag 'imx-fixes-5.10-4' of git://git.kernel.org/pub/scm/linux/kernel/git/shawnguo/linux:
        ARM: dts: imx50-evk: Fix the chip select 1 IOMUX
        arm64: dts: imx8mm: fix voltage for 1.6GHz CPU operating point
        ARM: dts: vf610-zii-dev-rev-b: Fix MDIO over clocking
        arm: dts: imx6qdl-udoo: fix rgmii phy-mode for ksz9031 phy
      
      Link: https://lore.kernel.org/r/20201116090702.GM5849@dragonSigned-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      cc05af8e
    • Arnd Bergmann's avatar
      Merge tag 'renesas-fixes-for-v5.10-tag1' of... · 39c8d39c
      Arnd Bergmann authored
      Merge tag 'renesas-fixes-for-v5.10-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel into arm/fixes
      
      Renesas fixes for v5.10
      
        - Add missing audio clock on RZ/G2H.
      
      * tag 'renesas-fixes-for-v5.10-tag1' of git://git.kernel.org/pub/scm/linux/kernel/git/geert/renesas-devel:
        arm64: dts: renesas: r8a774e1: Add missing audio_clk_b
      
      Link: https://lore.kernel.org/r/20201113151229.3924165-1-geert+renesas@glider.beSigned-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      39c8d39c
    • Guenter Roeck's avatar
      ACPI: fan: Initialize performance state sysfs attribute · 7dc7a8b0
      Guenter Roeck authored
      The following warning is reported if lock debugging is enabled.
      
      DEBUG_LOCKS_WARN_ON(1)
      WARNING: CPU: 1 PID: 1 at kernel/locking/lockdep.c:4617 lockdep_init_map_waits+0x141/0x222
      ...
      Call Trace:
       __kernfs_create_file+0x7a/0xd8
       sysfs_add_file_mode_ns+0x135/0x189
       sysfs_create_file_ns+0x70/0xa0
       acpi_fan_probe+0x547/0x621
       platform_drv_probe+0x67/0x8b
       ...
      
      Dynamically allocated sysfs attributes need to be initialized to avoid
      the warning.
      
      Fixes: d19e470b ("ACPI: fan: Expose fan performance state information")
      Signed-off-by: default avatarGuenter Roeck <linux@roeck-us.net>
      Cc: 5.6+ <stable@vger.kernel.org> # 5.6+
      Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
      7dc7a8b0
    • Dmitry Osipenko's avatar
      cpuidle: tegra: Annotate tegra_pm_set_cpu_in_lp2() with RCU_NONIDLE · c39de538
      Dmitry Osipenko authored
      Annotate tegra_pm_set[clear]_cpu_in_lp2() with RCU_NONIDLE in order to
      fix lockdep warning about suspicious RCU usage of a spinlock during late
      idling phase.
      
       WARNING: suspicious RCU usage
       ...
       include/trace/events/lock.h:13 suspicious rcu_dereference_check() usage!
       ...
        (dump_stack) from (lock_acquire)
        (lock_acquire) from (_raw_spin_lock)
        (_raw_spin_lock) from (tegra_pm_set_cpu_in_lp2)
        (tegra_pm_set_cpu_in_lp2) from (tegra_cpuidle_enter)
        (tegra_cpuidle_enter) from (cpuidle_enter_state)
        (cpuidle_enter_state) from (cpuidle_enter_state_coupled)
        (cpuidle_enter_state_coupled) from (cpuidle_enter)
        (cpuidle_enter) from (do_idle)
       ...
      Tested-by: default avatarPeter Geis <pgwipeout@gmail.com>
      Reported-by: default avatarPeter Geis <pgwipeout@gmail.com>
      Signed-off-by: default avatarDmitry Osipenko <digetx@gmail.com>
      Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
      c39de538
    • Max Filippov's avatar
      xtensa: disable preemption around cache alias management calls · 3a860d16
      Max Filippov authored
      Although cache alias management calls set up and tear down TLB entries
      and fast_second_level_miss is able to restore TLB entry should it be
      evicted they absolutely cannot preempt each other because they use the
      same TLBTEMP area for different purposes.
      Disable preemption around all cache alias management calls to enforce
      that.
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      3a860d16
    • Max Filippov's avatar
      xtensa: fix TLBTEMP area placement · 481535c5
      Max Filippov authored
      fast_second_level_miss handler for the TLBTEMP area has an assumption
      that page table directory entry for the TLBTEMP address range is 0. For
      it to be true the TLBTEMP area must be aligned to 4MB boundary and not
      share its 4MB region with anything that may use a page table. This is
      not true currently: TLBTEMP shares space with vmalloc space which
      results in the following kinds of runtime errors when
      fast_second_level_miss loads page table directory entry for the vmalloc
      space instead of fixing up the TLBTEMP area:
      
       Unable to handle kernel paging request at virtual address c7ff0e00
        pc = d0009275, ra = 90009478
       Oops: sig: 9 [#1] PREEMPT
       CPU: 1 PID: 61 Comm: kworker/u9:2 Not tainted 5.10.0-rc3-next-20201110-00007-g1fe4962fa983-dirty #58
       Workqueue: xprtiod xs_stream_data_receive_workfn
       a00: 90009478 d11e1dc0 c7ff0e00 00000020 c7ff0000 00000001 7f8b8107 00000000
       a08: 900c5992 d11e1d90 d0cc88b8 5506e97c 00000000 5506e97c d06c8074 d11e1d90
       pc: d0009275, ps: 00060310, depc: 00000014, excvaddr: c7ff0e00
       lbeg: d0009275, lend: d0009287 lcount: 00000003, sar: 00000010
       Call Trace:
         xs_stream_data_receive_workfn+0x43c/0x770
         process_one_work+0x1a1/0x324
         worker_thread+0x1cc/0x3c0
         kthread+0x10d/0x124
         ret_from_kernel_thread+0xc/0x18
      
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarMax Filippov <jcmvbkbc@gmail.com>
      481535c5
    • Linus Torvalds's avatar
      Linux 5.10-rc4 · 09162bc3
      Linus Torvalds authored
      09162bc3