Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965082AbcKDQz4 (ORCPT ); Fri, 4 Nov 2016 12:55:56 -0400 Received: from smtp-out-no.shaw.ca ([64.59.134.13]:51418 "EHLO smtp-out-no.shaw.ca" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932283AbcKDQzz (ORCPT ); Fri, 4 Nov 2016 12:55:55 -0400 X-Authority-Analysis: v=2.2 cv=WohbCZXv c=1 sm=1 tr=0 a=6xzog4CasRozao6qlzTIAw==:117 a=6xzog4CasRozao6qlzTIAw==:17 a=L24OOQBejmoA:10 a=Q-fNiiVtAAAA:8 a=D19gQVrFAAAA:8 a=1yzI7aI2VZRVI52qESEA:9 a=Fp8MccfUoT0GBdDC_Lng:22 a=W4TVW4IDbPiebHqcZpNg:22 From: Markus Mayer To: Viresh Kumar , "Rafael J . Wysocki" Cc: Power Management List , Broadcom Kernel List , Linux Kernel Mailing List , Markus Mayer Subject: [PATCH v2 0/2] cpufreq: stats: clear statistics Date: Fri, 4 Nov 2016 09:55:34 -0700 Message-Id: <20161104165536.20088-1-code@mmayer.net> X-Mailer: git-send-email 2.9.2 X-CMAE-Envelope: MS4wfCnUp6GpGoPYg3rAxinMzAztnQYNRfuRWMdyU7IFgkmvk5b05L16xgTzD4i3wIY6YCM8CqSUnjNkGqpaqnAdH2hYDoORt0Ze4PNZvjC8q3dIY1tS3wux CMUajEen38kZCIKMGzbMdK35BxcXc9GcOM9iCO12CfW3fWUZqjtATynAx1aKOFEHpPbnpiCsMNJuh/N08hUOiiTnrkkmDgEw5832Voy7avEiM02+uSZ+ngo/ CHA/VZiRw30M4MOfl6alTLDXYVClNypKif6yG5+XCSW3k2pObL+IJl/pY+gXuV+IQosxxc5TU4NzaNXIPCHjYGmjCAgHA316i97GYKM05wchnBJvjfCTRU64 cmsU+6vyzyM1SMqNykNvfONmV/eTAA== Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 911 Lines: 27 From: Markus Mayer This series lets the user clear the CPUfreq stats by writing to a new sysfs attribute. Changes since v1: - add new cpufreq_freq_attr_wr_perm() macro for write-only attributes (because this is a separate commit, this patch has turned into a series) - remove the Kconfig option, compiling the code unconditionally - remove show_reset() - cpufreq_stats_clear_table() takes a struct cpufreq_stats * as argument rather than a struct cpufreq_policy * For v1, see https://lkml.org/lkml/2016/11/3/581. Markus Mayer (2): cpufreq: add new attribute type cpufreq_freq_attr_wr_perm() cpufreq: stats: clear statistics Documentation/cpu-freq/cpufreq-stats.txt | 6 ++++++ drivers/cpufreq/cpufreq_stats.c | 22 ++++++++++++++++++++++ include/linux/cpufreq.h | 4 ++++ 3 files changed, 32 insertions(+) -- 2.7.4