summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/compaction-times.py
diff options
context:
space:
mode:
authorKai Shen <shenkai8@huawei.com>2019-11-07 05:08:17 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-11-28 18:26:19 +0100
commit71941ad643fd18ef59b00b745e6b9967feffaccb (patch)
tree3f14c44e9a6fa9512075a6fd9c6c5ef9bc1676cf /tools/perf/scripts/python/compaction-times.py
parent7f8286d2b526a86d9bbdf20690b4245d0ea1fac3 (diff)
cpufreq: Add NULL checks to show() and store() methods of cpufreq
commit e6e8df07268c1f75dd9215536e2ce4587b70f977 upstream. Add NULL checks to show() and store() in cpufreq.c to avoid attempts to invoke a NULL callback. Though some interfaces of cpufreq are set as read-only, users can still get write permission using chmod which can lead to a kernel crash, as follows: chmod +w /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq echo 1 > /sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq This bug was found in linux 4.19. Signed-off-by: Kai Shen <shenkai8@huawei.com> Reported-by: Feilong Lin <linfeilong@huawei.com> Reviewed-by: Feilong Lin <linfeilong@huawei.com> Acked-by: Viresh Kumar <viresh.kumar@linaro.org> [ rjw: Subject & changelog ] Cc: All applicable <stable@vger.kernel.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python/compaction-times.py')
0 files changed, 0 insertions, 0 deletions