1. Jan 11, 2022
    • Rafael J. Wysocki's avatar
      Merge branches 'pm-cpuidle', 'pm-core' and 'pm-sleep' · c001a52d
      Rafael J. Wysocki authored
      Merge cpuidle updates, PM core updates and one hiberation-related
      update for 5.17-rc1:
      
       - Make cpuidle use default_groups in kobj_type (Greg Kroah-Hartman).
      
       - Fix two comments in cpuidle code (Jason Wang, Yang Li).
      
       - Simplify locking in pm_runtime_put_suppliers() (Rafael Wysocki).
      
       - Add safety net to supplier device release in the runtime PM core
         code (Rafael Wysocki).
      
       - Capture device status before disabling runtime PM for it (Rafael
         Wysocki).
      
       - Add new macros for declaring PM operations to allow drivers to
         avoid guarding them with CONFIG_PM #ifdefs or __maybe_unused and
         update some drivers to use these macros (Paul Cercueil).
      
       - Allow ACPI hardware signature to be honoured during restore from
         hibernation (David Woodhouse).
      
      * pm-cpuidle:
        cpuidle: use default_groups in kobj_type
        cpuidle: Fix cpuidle_remove_state_sysfs() kerneldoc comment
        cpuidle: menu: Fix typo in a comment
      
      * pm-core:
        PM: runtime: Simplify locking in pm_runtime_put_suppliers()
        mmc: mxc: Use the new PM macros
        mmc: jz4740: Use the new PM macros
        PM: runtime: Add safety net to supplier device release
        PM: runtime: Capture device status before disabling runtime PM
        PM: core: Add new *_PM_OPS macros, deprecate old ones
        PM: core: Redefine pm_ptr() macro
        r8169: Avoid misuse of pm_ptr() macro
      
      * pm-sleep:
        PM: hibernate: Allow ACPI hardware signature to be honoured
      c001a52d
    • Rafael J. Wysocki's avatar
      Merge branch 'pm-cpufreq' · 5561f25b
      Rafael J. Wysocki authored
      Merge cpufreq updates for 5.17-rc1:
      
       - Add new P-state driver for AMD processors (Huang Rui).
      
       - Fix initialization of min and max frequency QoS requests in the
         cpufreq core (Rafael Wysocki).
      
       - Fix EPP handling on Alder Lake in intel_pstate (Srinivas Pandruvada).
      
       - Make intel_pstate update cpuinfo.max_freq when notified of HWP
         capabilities changes and drop a redundant function call from that
         driver (Rafael Wysocki).
      
       - Improve IRQ support in the Qcom cpufreq driver (Ard Biesheuvel,
         Stephen Boyd, Vladimir Zapolskiy).
      
       - Fix double devm_remap() in the Mediatek cpufreq driver (Hector Yuan).
      
       - Introduce thermal pressure helpers for cpufreq CPU cooling (Lukasz
         Luba).
      
       - Make cpufreq use default_groups in kobj_type (Greg Kroah-Hartman).
      
      * pm-cpufreq: (32 commits)
        x86, sched: Fix undefined reference to init_freq_invariance_cppc() build error
        cpufreq: amd-pstate: Fix Kconfig dependencies for AMD P-State
        cpufreq: amd-pstate: Fix struct amd_cpudata kernel-doc comment
        MAINTAINERS: Add AMD P-State driver maintainer entry
        Documentation: amd-pstate: Add AMD P-State driver introduction
        cpufreq: amd-pstate: Add AMD P-State performance attributes
        cpufreq: amd-pstate: Add AMD P-State frequencies attributes
        cpufreq: amd-pstate: Add boost mode support for AMD P-State
        cpufreq: amd-pstate: Add trace for AMD P-State module
        cpufreq: amd-pstate: Introduce the support for the processors with shared memory solution
        cpufreq: amd-pstate: Add fast switch function for AMD P-State
        cpufreq: amd-pstate: Introduce a new AMD P-State driver to support future processors
        ACPI: CPPC: Add CPPC enable register function
        ACPI: CPPC: Check present CPUs for determining _CPC is valid
        ACPI: CPPC: Implement support for SystemIO registers
        x86/msr: Add AMD CPPC MSR definitions
        x86/cpufeatures: Add AMD Collaborative Processor Performance Control feature flag
        cpufreq: use default_groups in kobj_type
        cpufreq: mediatek-hw: Fix double devm_remap in hotplug case
        cpufreq: intel_pstate: Update cpuinfo.max_freq on HWP_CAP changes
        ...
      5561f25b
  2. Jan 07, 2022
  3. Jan 06, 2022
  4. Jan 04, 2022
  5. Jan 03, 2022
  6. Jan 02, 2022
    • yaowenbin's avatar
      perf top: Fix TUI exit screen refresh race condition · 64f18d2d
      yaowenbin authored
      
      
      When the following command is executed several times, a coredump file is
      generated.
      
      	$ timeout -k 9 5 perf top -e task-clock
      	*******
      	*******
      	*******
      	0.01%  [kernel]                  [k] __do_softirq
      	0.01%  libpthread-2.28.so        [.] __pthread_mutex_lock
      	0.01%  [kernel]                  [k] __ll_sc_atomic64_sub_return
      	double free or corruption (!prev) perf top --sort comm,dso
      	timeout: the monitored command dumped core
      
      When we terminate "perf top" using sending signal method,
      SLsmg_reset_smg() called. SLsmg_reset_smg() resets the SLsmg screen
      management routines by freeing all memory allocated while it was active.
      
      However SLsmg_reinit_smg() maybe be called by another thread.
      
      SLsmg_reinit_smg() will free the same memory accessed by
      SLsmg_reset_smg(), thus it results in a double free.
      
      SLsmg_reinit_smg() is called already protected by ui__lock, so we fix
      the problem by adding pthread_mutex_trylock of ui__lock when calling
      SLsmg_reset_smg().
      
      Signed-off-by: default avatarWenyu Liu <liuwenyu7@huawei.com>
      Tested-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.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: wuxu.wu@huawei.com
      Link: http://lore.kernel.org/lkml/a91e3943-7ddc-f5c0-a7f5-360f073c20e6@huawei.com
      
      
      Signed-off-by: default avatarHewenliang <hewenliang4@huawei.com>
      Signed-off-by: default avataryaowenbin <yaowenbin1@huawei.com>
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      64f18d2d
    • John Garry's avatar
      perf pmu: Fix alias events list · e0257a01
      John Garry authored
      Commit 0e0ae874 ("perf list: Display hybrid PMU events with cpu
      type") changes the event list for uncore PMUs or arm64 heterogeneous CPU
      systems, such that duplicate aliases are incorrectly listed per PMU
      (which they should not be), like:
      
        # perf list
        ...
        unc_cbo_cache_lookup.any_es
        [Unit: uncore_cbox L3 Lookup any request that access cache and found
        line in E or S-state]
        unc_cbo_cache_lookup.any_es
        [Unit: uncore_cbox L3 Lookup any request that access cache and found
        line in E or S-state]
        unc_cbo_cache_lookup.any_i
        [Unit: uncore_cbox L3 Lookup any request that access cache and found
        line in I-state]
        unc_cbo_cache_lookup.any_i
        [Unit: uncore_cbox L3 Lookup any request that access cache and found
        line in I-state]
        ...
      
      Notice how the events are listed twice.
      
      The named commit changed how we remove duplicate events, in that events
      for different PMUs are not treated as duplicates. I suppose this is to
      handle how "Each hybrid pmu event has been assigned with a pmu name".
      
      Fix PMU alias listing by restoring behaviour to remove duplicates for
      non-hybrid PMUs.
      
      Fixes: 0e0ae874
      
       ("perf list: Display hybrid PMU events with cpu type")
      Signed-off-by: default avatarJohn Garry <john.garry@huawei.com>
      Tested-by: default avatarZhengjun Xing <zhengjun.xing@linux.intel.com>
      Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
      Cc: Ian Rogers <irogers@google.com>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Kan Liang <kan.liang@linux.intel.com>
      Cc: Mark Rutland <mark.rutland@arm.com>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Link: https://lore.kernel.org/r/1640103090-140490-1-git-send-email-john.garry@huawei.com
      
      
      Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
      e0257a01
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input · 278218f6
      Linus Torvalds authored
      Pull input fixes from Dmitry Torokhov:
       "Two small fixups for spaceball joystick driver and appletouch touchpad
        driver"
      
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
        Input: spaceball - fix parsing of movement data packets
        Input: appletouch - initialize work before device registration
      278218f6
  7. Jan 01, 2022
  8. Dec 31, 2021