[PATCH 1/2] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-04-22 Thread Shilpasri G Bhat
for reducing Pmax is also queued along with the message. Additional opal message type OPAL_MSG_PRD is added to maintain compatibility between opal and kernel definition of opal_message_type. Signed-off-by: Shilpasri G Bhat --- arch/powerpc/include/asm/opal-api.h | 8 1 file changed, 8

[PATCH 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-22 Thread Shilpasri G Bhat
power or thermal reasons. We are also notified of unthrottling after an OCC reset or if OCC restores Pmax on the chip. Signed-off-by: Shilpasri G Bhat CC: "Rafael J. Wysocki" CC: Viresh Kumar CC: linux...@vger.kernel.org --- drivers/cpufreq/powernv-cpuf

Re: [PATCH 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-27 Thread Shilpasri G Bhat
Hi Viresh, On 04/27/2015 10:02 AM, Viresh Kumar wrote: > On 22 April 2015 at 22:34, Shilpasri G Bhat > wrote: >> diff --git a/drivers/cpufreq/powernv-cpufreq.c >> b/drivers/cpufreq/powernv-cpufreq.c > >> +static char throttle_reason[6][50] = { "No throttling&quo

Re: [PATCH 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-27 Thread Shilpasri G Bhat
Hi Preeti, On 04/23/2015 05:28 PM, Preeti U Murthy wrote: > Hi Shilpa, > > On 04/22/2015 10:34 PM, Shilpasri G Bhat wrote: >> OCC is an On-Chip-Controller which takes care of power and thermal >> safety of the chip. During runtime due to power failure or >> overtempe

[PATCH v2 0/2] powernv: cpufreq: Report frequency throttle by OCC

2015-04-27 Thread Shilpasri G Bhat
limit the max allowed frequency. The patchset will report such conditions so as to keep the user informed about reason for the drop in performance of workloads when frequency is throttled. Shilpasri G Bhat (2): powerpc/powernv: Add definition of OPAL_MSG_OCC message type cpufreq: powernv: Register

[PATCH v2 1/2] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-04-27 Thread Shilpasri G Bhat
opal_message_type. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- Changes from v1: - Update the commit changelog arch/powerpc/include/asm/opal-api.h | 8 1 file changed, 8 insertions(+) diff --git a/arch/powerpc/include/asm/opal-api.h b/arch/powerpc/include/asm/opal-api.h

[PATCH v2 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-27 Thread Shilpasri G Bhat
power or thermal reasons. We are also notified of unthrottling after an OCC reset or if OCC restores Pmax on the chip. Signed-off-by: Shilpasri G Bhat CC: "Rafael J. Wysocki" CC: Viresh Kumar CC: Preeti U Murthy CC: linux...@vger.kernel.org --- Changes from v1: - Add macros to define

Re: [PATCH v2 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-28 Thread Shilpasri G Bhat
Hi Viresh, On 04/28/2015 12:18 PM, Viresh Kumar wrote: > On 28 April 2015 at 11:53, Shilpasri G Bhat > wrote: > >> Changes from v1: >> - Add macros to define OCC_RESET, OCC_LOAD and OCC_THROTTLE >> - Define a structure to store chip id, chip mask which has bits set &

Re: [PATCH v2 2/2] cpufreq: powernv: Register for OCC related opal_message notification

2015-04-28 Thread Shilpasri G Bhat
On 04/28/2015 02:23 PM, Viresh Kumar wrote: > On 28 April 2015 at 13:48, Shilpasri G Bhat > wrote: >> My bad I haven't added explicit comment to state reason behind this change. >> >> I modified the definition of *throttle_check() to match the function >

[PATCH v3 0/6] powernv: cpufreq: Report frequency throttle by OCC

2015-05-04 Thread Shilpasri G Bhat
limit the max allowed frequency. The patchset will report such conditions so as to keep the user informed about reason for the drop in performance of workloads when frequency is throttled. Changes from v2: - Split into multiple patches - Semantic fixes Shilpasri G Bhat (6): cpufreq: poowernv

[PATCH v3 1/6] cpufreq: poowernv: Handle throttling due to Pmax capping at chip level

2015-05-04 Thread Shilpasri G Bhat
7; on Pmax capping instead set the per-chip throttled variable. Report unthrottling if Pmax is restored after throttling. This patch adds a structure to store chip id and throttled state of the chip. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpuf

[PATCH v3 2/6] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-05-04 Thread Shilpasri G Bhat
opal_message_type. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- No change from V2 Change from v1: - Update the commit changelog arch/powerpc/include/asm/opal-api.h | 8 1 file changed, 8 insertions(+) diff --git a/arch/powerpc/include/asm/opal-api.h b/arch/powerpc/include

[PATCH v3 4/6] cpufreq: powernv: Call throttle_check() on receiving OCC_THROTTLE

2015-05-04 Thread Shilpasri G Bhat
ned-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 28 ++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index 9268424..9618813 100644 --- a/drivers/cpufreq/powernv

[PATCH v3 3/6] cpufreq: powernv: Register for OCC related opal_message notification

2015-05-04 Thread Shilpasri G Bhat
to power or thermal reasons. We are also notified of unthrottling after an OCC reset or if OCC restores Pmax on the chip. Signed-off-by: Shilpasri G Bhat --- Changes from v2: - Patch split in to multiple patches. - This patch contains only the opal_message notification handler Changes from v1

[PATCH v3 5/6] cpufreq: powernv: Report Psafe only if PMSR.psafe_mode_active bit is set

2015-05-04 Thread Shilpasri G Bhat
this bit for reporting throttling. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index 9618813..0a59d5b 100644 --- a

[PATCH v3 6/6] cpufreq: powernv: Restore cpu frequency to policy->cur on unthrottling

2015-05-04 Thread Shilpasri G Bhat
-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 31 +-- 1 file changed, 29 insertions(+), 2 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index 0a59d5b..b2915bc 100644 --- a/drivers/cpufreq/powernv-cpufre

Re: [PATCH v3 1/6] cpufreq: poowernv: Handle throttling due to Pmax capping at chip level

2015-05-04 Thread Shilpasri G Bhat
Hi Preeti, On 05/05/2015 09:21 AM, Preeti U Murthy wrote: > Hi Shilpa, > > On 05/04/2015 02:24 PM, Shilpasri G Bhat wrote: >> The On-Chip-Controller(OCC) can throttle cpu frequency by reducing the >> max allowed frequency for that chip if the chip exceeds its power or >

Re: [PATCH v3 4/6] cpufreq: powernv: Call throttle_check() on receiving OCC_THROTTLE

2015-05-04 Thread Shilpasri G Bhat
Hi Preeti, On 05/05/2015 09:30 AM, Preeti U Murthy wrote: > Hi Shilpa, > > On 05/04/2015 02:24 PM, Shilpasri G Bhat wrote: >> Re-evaluate the chip's throttled state on recieving OCC_THROTTLE >> notification by executing *throttle_check() on any one of the cpu on >

Re: [PATCH v3 1/6] cpufreq: poowernv: Handle throttling due to Pmax capping at chip level

2015-05-07 Thread Shilpasri G Bhat
On 05/05/2015 02:08 PM, Preeti U Murthy wrote: > On 05/05/2015 11:36 AM, Shilpasri G Bhat wrote: >> Hi Preeti, >> >> On 05/05/2015 09:21 AM, Preeti U Murthy wrote: >>> Hi Shilpa, >>> >>> On 05/04/2015 02:24 PM, Shilpasri G Bhat wrote: >>>

[PATCH] cpuidle: powernv/pseries: Decrease the snooze residency

2015-05-29 Thread Shilpasri G Bhat
the cpu to promote it to deeper idle states. Signed-off-by: Shilpasri G Bhat --- drivers/cpuidle/cpuidle-powernv.c | 12 drivers/cpuidle/cpuidle-pseries.c | 11 +++ 2 files changed, 23 insertions(+) diff --git a/drivers/cpuidle/cpuidle-powernv.c b/drivers/cpuidle/cpuidle

[PATCH v2] cpufreq: powernv: Set the cpus to nominal frequency during reboot/kexec

2014-08-28 Thread Shilpasri G Bhat
oke .target() driver callback to set the cpus to nominal frequency in reboot notifier, instead of calling cpufreq_suspend() as suggested by Viresh Kumar. Modified the commit message. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- drivers/cpufreq/powernv-cpufreq.c |

[PATCH v3] cpufreq: powernv: Set the cpus to nominal frequency during reboot/kexec

2014-09-11 Thread Shilpasri G Bhat
cause the target kernel to perform poorly. It will also increase the boot up time of the target kernel. So set the cpus to high pstate, in this case to nominal frequency before rebooting to avoid such scenarios. The reboot notifier will set the cpus to nominal frequncy. Signed-off-by: Shilpasri G

[PATCH v2] cpuidle: powernv/pseries: Auto-promotion of snooze to deeper idle state

2015-06-18 Thread Shilpasri G Bhat
the cpu to promote it to deeper idle states. Signed-off-by: Shilpasri G Bhat --- Changes from v1: -Modified commit message drivers/cpuidle/cpuidle-powernv.c | 12 drivers/cpuidle/cpuidle-pseries.c | 11 +++ 2 files changed, 23 insertions(+) diff --git a/drivers/cpuidle

[PATCH v4 0/6] powernv: cpufreq: Report frequency throttle by OCC

2015-07-13 Thread Shilpasri G Bhat
Split into multiple patches - Semantic fixes Shilpasri G Bhat (6): cpufreq: powernv: Handle throttling due to Pmax capping at chip level powerpc/powernv: Add definition of OPAL_MSG_OCC message type cpufreq: powernv: Register for OCC related opal_message notification cpufreq: pow

[PATCH v4 1/6] cpufreq: powernv: Handle throttling due to Pmax capping at chip level

2015-07-13 Thread Shilpasri G Bhat
7; on Pmax capping instead set the per-chip throttled variable. Report unthrottling if Pmax is restored after throttling. This patch adds a structure to store chip id and throttled state of the chip. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- No change from v3 drive

[PATCH v4 2/6] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-07-13 Thread Shilpasri G Bhat
respectively. The throttle OCC event indicates that the Pmax of the chip is reduced. The chip_id and throttle reason for reducing Pmax is also queued along with the message. CC: Stewart Smith Signed-off-by: Shilpasri G Bhat --- Changes from v3: - '0d7cd8550d3 powerpc/powernv: Add opal-prd ch

[PATCH v4 3/6] cpufreq: powernv: Register for OCC related opal_message notification

2015-07-13 Thread Shilpasri G Bhat
to power or thermal reasons. We are also notified of unthrottling after an OCC reset or if OCC restores Pmax on the chip. Signed-off-by: Shilpasri G Bhat --- Changes from v3: - Move the macro definitions of OCC_RESET, OCC_LOAD, OCC_THROTTLE to arch/powerpc/include/asm/opal-api.h - Use 's

[PATCH v4 4/6] cpufreq: powernv: Call throttle_check() on receiving OCC_THROTTLE

2015-07-13 Thread Shilpasri G Bhat
ned-off-by: Shilpasri G Bhat --- Changes from v3: - Refer to the members of 'struct opal_occ_msg' in the patch. Replace 'chip_id' with 'omsg.chip' drivers/cpufreq/powernv-cpufreq.c | 28 ++-- 1 file changed, 26 insertions(+), 2 deletions(

[PATCH v4 6/6] cpufreq: powernv: Restore cpu frequency to policy->cur on unthrottling

2015-07-13 Thread Shilpasri G Bhat
-by: Shilpasri G Bhat --- Changes from v3: - Refer to the members of 'struct opal_occ_msg' in the patch. Replace 'reason' with 'omsg.throttle_status' drivers/cpufreq/powernv-cpufreq.c | 31 +-- 1 file changed, 29 insertions(+), 2 d

[PATCH v4 5/6] cpufreq: powernv: Report Psafe only if PMSR.psafe_mode_active bit is set

2015-07-13 Thread Shilpasri G Bhat
this bit for reporting throttling. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- No changes from v3 drivers/cpufreq/powernv-cpufreq.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv

Re: [PATCH v4 3/6] cpufreq: powernv: Register for OCC related opal_message notification

2015-07-15 Thread Shilpasri G Bhat
Hi Joel, On 07/15/2015 11:47 AM, Joel Stanley wrote: > Hello, > > On Mon, 2015-07-13 at 19:39 +0530, Shilpasri G Bhat wrote: >> diff --git a/drivers/cpufreq/powernv-cpufreq.c >> b/drivers/cpufreq/powernv-cpufreq.c >> index d0c18c9..1f59958 100644 >> --- a/

[PATCH v5 3/6] cpufreq: powernv: Register for OCC related opal_message notification

2015-07-16 Thread Shilpasri G Bhat
to power or thermal reasons. We are also notified of unthrottling after an OCC reset or if OCC restores Pmax on the chip. Signed-off-by: Shilpasri G Bhat Acked-by: Viresh Kumar --- Changes from v4: - Replace memcpy() with be64_to_cpu() to copy the msg->params[] Changes from v3: - Move the ma

[PATCH v5 4/6] cpufreq: powernv: Call throttle_check() on receiving OCC_THROTTLE

2015-07-16 Thread Shilpasri G Bhat
ned-off-by: Shilpasri G Bhat Acked-by: Viresh Kumar --- No changes from v4 Changes from v3: - Refer to the members of 'struct opal_occ_msg' in the patch. Replace 'chip_id' with 'omsg.chip' drivers/cpufreq/powernv-cpufreq.c | 28 ++-- 1 fil

[PATCH v5 5/6] cpufreq: powernv: Report Psafe only if PMSR.psafe_mode_active bit is set

2015-07-16 Thread Shilpasri G Bhat
this bit for reporting throttling. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy Acked-by: Viresh Kumar --- No changes from v4 drivers/cpufreq/powernv-cpufreq.c | 12 +++- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b

[PATCH v5 1/6] cpufreq: powernv: Handle throttling due to Pmax capping at chip level

2015-07-16 Thread Shilpasri G Bhat
7; on Pmax capping instead set the per-chip throttled variable. Report unthrottling if Pmax is restored after throttling. This patch adds a structure to store chip id and throttled state of the chip. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy Acked-by: Viresh Kumar --- No chan

[PATCH v5 2/6] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-07-16 Thread Shilpasri G Bhat
respectively. The throttle OCC event indicates that the Pmax of the chip is reduced. The chip_id and throttle reason for reducing Pmax is also queued along with the message. CC: Stewart Smith Signed-off-by: Shilpasri G Bhat Acked-by: Viresh Kumar --- No change from v4 Changes from v3

[PATCH v5 0/6] powernv: cpufreq: Report frequency throttle by OCC

2015-07-16 Thread Shilpasri G Bhat
build error due to which this series was initially dropped ERROR: ".opal_message_notifier_register" drivers/cpufreq/powernv-cpufreq.ko] undefined! Changes from v2: - Split into multiple patches - Semantic fixes Shilpasri G Bhat (6): cpufreq: powernv: Handle throttling due to Pmax

[PATCH v5 6/6] cpufreq: powernv: Restore cpu frequency to policy->cur on unthrottling

2015-07-16 Thread Shilpasri G Bhat
-by: Shilpasri G Bhat Acked-by: Viresh Kumar --- No changes from v4 Changes from v3: - Refer to the members of 'struct opal_occ_msg' in the patch. Replace 'reason' with 'omsg.throttle_status' drivers/cpufreq/powernv-cpufreq.c | 31 +

Re: [PATCH v5 2/6] powerpc/powernv: Add definition of OPAL_MSG_OCC message type

2015-08-10 Thread Shilpasri G Bhat
Hi Stewart, On 08/10/2015 05:53 AM, Stewart Smith wrote: > Shilpasri G Bhat writes: >> Add OPAL_MSG_OCC message definition to opal_message_type to receive >> OCC events like reset, load and throttled. Host performance can be >> affected when OCC is reset or OCC throttles

Re: [PATCH v5 3/6] cpufreq: powernv: Register for OCC related opal_message notification

2015-08-10 Thread Shilpasri G Bhat
On 08/10/2015 07:11 AM, Stewart Smith wrote: > Shilpasri G Bhat writes: >> diff --git a/drivers/cpufreq/powernv-cpufreq.c >> b/drivers/cpufreq/powernv-cpufreq.c >> index d0c18c9..a634199 100644 >> --- a/drivers/cpufreq/powernv-cpufreq.c >> +++ b/drivers/cpuf

[PATCH] cpufreq: powernv: Register the driver with reboot notifier

2014-08-14 Thread Shilpasri G Bhat
set during a reboot/kexec similar to the suspend operartion. Signed-off-by: Shilpasri G Bhat Reviewed-by: Preeti U Murthy --- drivers/cpufreq/powernv-cpufreq.c | 16 1 file changed, 16 insertions(+) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv

Re: [PATCH] cpufreq: powernv: Register the driver with reboot notifier

2014-08-20 Thread Shilpasri G Bhat
On 08/18/2014 01:16 PM, Viresh Kumar wrote: On 14 August 2014 16:49, Shilpasri G Bhat wrote: This patch ensures the cpus to kexec/reboot at nominal frequency. Nominal frequency is the highest cpu frequency on PowerPC at which the cores can run without getting throttled. If the host kernel

[PATCH v10 0/2] cpufreq: powernv: Export throttle stat attributes and a bug fix

2016-02-26 Thread Shilpasri G Bhat
powernv_cpufreq_exit() as suggested by Viresh. - Patch[2/2] is rebased on top of Patch[1/2]. Shilpasri G Bhat (2): cpufreq: powernv: Fix bugs in powernv_cpufreq_{init/exit} cpufreq: powernv: Add sysfs attributes to show throttle stats Documentation/ABI/testing/sysfs-devices-system-cpu | 69

[PATCH v10 1/2] cpufreq: powernv: Fix bugs in powernv_cpufreq_{init/exit}

2016-02-26 Thread Shilpasri G Bhat
Unregister the notifiers if cpufreq_driver_register() fails in powernv_cpufreq_init(). Re-arrange the unregistration and cleanup routines in powernv_cpufreq_exit() to free all the resources after the driver has unregistered. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c

[PATCH v10 2/2] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-02-26 Thread Shilpasri G Bhat
/throttle_stats/overcurrent 8)/sys/devices/system/cpu/cpuX/cpufreq/throttle_stats/occ_reset Detailed explanation of each attribute is added to Documentation/ABI/testing/sysfs-devices-system-cpu CC: linux-...@vger.kernel.org Signed-off-by: Shilpasri G Bhat --- Changes from v9: - Modified

[PATCH] cpufreq: powernv: Define per_cpu chip pointer to optimize hot-path

2016-03-18 Thread Shilpasri G Bhat
a neater and simpler solution. Signed-off-by: Michael Neuling Tested-by: Shilpasri G Bhat --- - Rebased the patch on top of linux-pm/linux-next - nr_chips is defined static, so it will be initialized to zero - Moved the initialization of the per_cpu variable after 'chips' is allocat

[PATCH RESEND] cpufreq: powernv: Define per_cpu chip pointer to optimize hot-path

2016-03-21 Thread Shilpasri G Bhat
nd provides a neater and simpler solution. Signed-off-by: Michael Neuling Signed-off-by: Shilpasri G Bhat Acked-by: Viresh Kumar --- - Included S-o-b and ACK tags - Added the commit id to the commit log drivers/cpufreq/powernv-cpufreq.c | 50 +-- 1 file ch

[PATCH v11] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-03-21 Thread Shilpasri G Bhat
/throttle_stats/overcurrent 8)/sys/devices/system/cpu/cpuX/cpufreq/throttle_stats/occ_reset Detailed explanation of each attribute is added to Documentation/ABI/testing/sysfs-devices-system-cpu CC: linux-...@vger.kernel.org Signed-off-by: Shilpasri G Bhat --- Changes from v10: - Removed

[PATCH v12] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-03-22 Thread Shilpasri G Bhat
/throttle_stats/overcurrent 8)/sys/devices/system/cpu/cpuX/cpufreq/throttle_stats/occ_reset Detailed explanation of each attribute is added to Documentation/ABI/testing/sysfs-devices-system-cpu CC: linux-...@vger.kernel.org Signed-off-by: Shilpasri G Bhat --- Changes from v11: - Removed

[PATCH v13] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-03-22 Thread Shilpasri G Bhat
/throttle_stats/overcurrent 8)/sys/devices/system/cpu/cpuX/cpufreq/throttle_stats/occ_reset Detailed explanation of each attribute is added to Documentation/ABI/testing/sysfs-devices-system-cpu CC: linux-...@vger.kernel.org Signed-off-by: Shilpasri G Bhat --- Changes from v12: - Removed (void

[PATCH] cpufreq: powernv: Fixes initialization of chip and chip mask

2016-04-20 Thread Shilpasri G Bhat
his bug by scanning all the possible cpus and sets the cpu in the chip mask. It also fixes the chip discovery with non-contiguous cpu mask. This patch creates a list of chips 'powernv_chip_list' to replace the chip array for cleaner initialization. Signed-off-by: Shilpasri G Bhat Re

[PATCH] cpufreq: powernv: Increase the verbosity of OCC console messages

2015-08-27 Thread Shilpasri G Bhat
Modify the OCC reset/load/active event message to make it clearer for the user to understand the event and effect of the event. Suggested-by: Stewart Smith Signed-off-by: Shilpasri G Bhat --- This patch is based on top of linux-next/master drivers/cpufreq/powernv-cpufreq.c | 9 + 1

[PATCH] cpufreq: powernv: Export frequency throttle state of the chip through sysfs

2015-08-27 Thread Shilpasri G Bhat
-sensitive applications can monitor the throttle state using this attribute. Following file is created in sysfs: /sys/devices/system/node/nodeN/throttle 'throttle' attribute has the following values: 0 : frequency is unthrottled 1 : frequency is throttled Suggested-by: Stewart Smith Signed-off-

Re: [PATCH] cpufreq: powernv: Export frequency throttle state of the chip through sysfs

2015-08-27 Thread Shilpasri G Bhat
On 08/27/2015 03:01 PM, Michael Ellerman wrote: > On Thu, 2015-08-27 at 14:43 +0530, Shilpasri G Bhat wrote: >> Create a sysfs 'throttle' attribute per-chip(per-numa-node) to reflect >> the throttle state of the chip. The usersapce programs can poll on >> this

[PATCH] cpufreq : powernv: Report Pmax throttling if capped below nominal frequency

2015-09-13 Thread Shilpasri G Bhat
ments. So report the pmax throttling with severity when Pmax is dipped below nominal frequency. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufr

[PATCH v2] cpufreq : powernv: Report Pmax throttling if capped below nominal frequency

2015-09-14 Thread Shilpasri G Bhat
ments. So report the pmax throttling with severity when Pmax is dipped below nominal frequency. Signed-off-by: Shilpasri G Bhat --- Changes from v1: - Modified the printk messages as per Viresh's suggestion. drivers/cpufreq/powernv-cpufreq.c | 10 -- 1 file changed, 8 insertions

[PATCH] cpufreq: powernv: Redesign the presentation of throttle notification

2015-12-13 Thread Shilpasri G Bhat
) range of frequencies. # cat /sys/devices/system/node/node0/throttle_stat Turbo 7 Nominal 0 Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 186 +- include/trace/events/power.h | 22 + 2 files changed, 166 inserti

[PATCH v2 0/2] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-01 Thread Shilpasri G Bhat
ys/devices/system/cpu/cpufreq/chipN. Shilpasri G Bhat (2): cpufreq: powernv/tracing: Add powernv_throttle tracepoint cpufreq: powernv: Redesign the presentation of throttle notification drivers/cpufreq/powernv-cpufreq.c | 247 +++--- include/trace/even

[PATCH v2 1/2] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-01 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat CC: Ingo Molnar CC: Steven Rostedt --- Changes from v1: - Export the tracepoint include/trace/events/power.h

[PATCH v2 2/2] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-01 Thread Shilpasri G Bhat
s/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpasri G Bhat --- Changes from v1: - Added a kobject to struct chip - Grouped the throttle reasons under a separate attribute_group and exported each reason as individual file. - Moved the sysfs files from /sys

Re: [PATCH] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-01 Thread Shilpasri G Bhat
Hi, On 12/15/2015 02:59 AM, Paul Clarke wrote: > On 12/13/2015 12:17 PM, Shilpasri G Bhat wrote: >> Replace the throttling event console messages to perf trace event >> "power:powernv_throttle" and throttle counter stats which are >> exported in sysfs. The newly a

[PATCH v3 0/2] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-04 Thread Shilpasri G Bhat
ys/devices/system/cpu/cpufreq/chipN. Changes from v2: - Fixed kbuild test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (2): cpufreq: powernv/tracing:

[PATCH v3 2/2] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-04 Thread Shilpasri G Bhat
s/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpasri G Bhat --- Changes from v2: - Fixed kbuild test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wu

[PATCH v3 1/2] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-04 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat CC: Ingo Molnar CC: Steven Rostedt --- No changes from v2. Changes from v1: - Export the tracepoint include

[PATCH v4 0/4] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-11 Thread Shilpasri G Bhat
chip id. - Break patch2 in to two patches separating the tracepoint and sysfs attribute changes. Changes from v2: - Fixed kbuild test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result]

[PATCH v4 1/4] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-01-11 Thread Shilpasri G Bhat
cpu_to_chip_id() does a DT walk through to find out the chip id by taking a contended device tree lock. This adds an unnecessary overhead in a hot-path. So instead of cpu_to_chip_id() use PIR of the cpu to find the chip id. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat

[PATCH v4 2/4] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-11 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat CC: Ingo Molnar CC: Steven Rostedt --- No changes from v2 and v3. include/trace/events/power.h | 22

[PATCH v4 3/4] cpufreq: powernv: Add a trace print for the throttle event

2016-01-11 Thread Shilpasri G Bhat
Record the throttle event with a trace print replacing the printk, except for events like throttling below nominal and occ reset event which print a warning message. Signed-off-by: Shilpasri G Bhat --- Changes from v3: - Separate this patch to contain trace_point changes - Move struct chip

[PATCH v4 4/4] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-11 Thread Shilpasri G Bhat
gives the total number of events of max frequency throttling to lower frequencies in the turbo range of frequencies and the sub-turbo(at and below nominal) range of frequencies. # cat /sys/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpa

[PATCH RESEND v4 0/4] cpufreq: powernv: Redesign the presentation of throttle notification

2016-01-12 Thread Shilpasri G Bhat
cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (4): cpufreq: powernv: Remove cpu_to_chip_id() from hot-path cpufreq: powernv/tracing: Add powernv_throttle tracepoint cpufreq: powernv:

[PATCH RESEND v4 1/4] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-01-12 Thread Shilpasri G Bhat
cpu_to_chip_id() does a DT walk through to find out the chip id by taking a contended device tree lock. This adds an unnecessary overhead in a hot-path. So instead of cpu_to_chip_id() use PIR of the cpu to find the chip id. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat

[PATCH RESEND v4 3/4] cpufreq: powernv: Add a trace print for the throttle event

2016-01-12 Thread Shilpasri G Bhat
Record the throttle event with a trace print replacing the printk, except for events like throttling below nominal and occ reset event which print a warning message. Signed-off-by: Shilpasri G Bhat --- Changes from v3: - Separate this patch to contain trace_point changes - Move struct chip

[PATCH RESEND v4 2/4] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-12 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat CC: Ingo Molnar CC: Steven Rostedt --- No changes from v2 and v3. include/trace/events/power.h | 22

[PATCH RESEND v4 4/4] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-12 Thread Shilpasri G Bhat
gives the total number of events of max frequency throttling to lower frequencies in the turbo range of frequencies and the sub-turbo(at and below nominal) range of frequencies. # cat /sys/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpa

[PATCH v5 0/5] cpufreq: powernv: Redesign the presentation of throttle notification and solve bug-fixes in the driver

2016-01-21 Thread Shilpasri G Bhat
tches separating the tracepoint and sysfs attribute changes. Changes from v2: - Fixed kbuild test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (5): cpufr

[PATCH v5 1/5] cpufreq: powernv: Hot-plug safe the kworker thread

2016-01-21 Thread Shilpasri G Bhat
Suggested-by: Gautham R Shenoy Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- drivers/cpufreq/powernv-cpufreq.c | 18 ++ 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index

[PATCH v5 2/5] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-01-21 Thread Shilpasri G Bhat
he hotpath. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- Changes from v4: - Taken care of Shreyas's comments to add a core_to_chip_map array to store the chip id. drivers/cpufreq/powernv-cpufreq.c | 24 +--- 1 file changed

[PATCH v5 3/5] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-21 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy CC: Ingo Molnar CC: Steven Rostedt --- No changes since v2. include/trace/events

[PATCH v5 4/5] cpufreq: powernv: Replace pr_info with trace print for throttle event

2016-01-21 Thread Shilpasri G Bhat
/pr_warn_once as pointed by MFG to not mark them as critical messages. This patch adds 'throt_reason' to struct chip to store the throttle reason. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- Changes from v4: - Taken care of Gautham's comments to remove t

[PATCH v5 5/5] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-21 Thread Shilpasri G Bhat
gives the total number of events of max frequency throttling to lower frequencies in the turbo range of frequencies and the sub-turbo(at and below nominal) range of frequencies. # cat /sys/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpa

[PATCH v6 0/5] cpufreq: powernv: Redesign the presentation of throttle notification and solve bug-fixes in the driver

2016-01-21 Thread Shilpasri G Bhat
/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (5): cpufreq: powernv: Hot-plug safe the kworker thread cpufreq: powernv: Remove cpu_to_chip_id() from hot-path cpufre

[PATCH v6 1/5] cpufreq: powernv: Hot-plug safe the kworker thread

2016-01-21 Thread Shilpasri G Bhat
Suggested-by: Gautham R Shenoy Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- Changes form v5: - Fix the kbuild-error: drivers/cpufreq/powernv-cpufreq.c:428:2: error: implicit declaration of function 'get_online_cpus' [-Werror=implicit-function-declaration drive

[PATCH v6 2/5] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-01-21 Thread Shilpasri G Bhat
he hotpath. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- No changes from v5. Changes from v4: - Taken care of Shreyas's comments to add a core_to_chip_map array to store the chip id. drivers/cpufreq/powernv-cpufreq.c | 24 +

[PATCH v6 4/5] cpufreq: powernv: Replace pr_info with trace print for throttle event

2016-01-21 Thread Shilpasri G Bhat
/pr_warn_once as pointed by MFG to not mark them as critical messages. This patch adds 'throt_reason' to struct chip to store the throttle reason. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- No changes from v5. Changes from v4: - Taken care of Gautham's comments to

[PATCH v6 3/5] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-21 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy CC: Ingo Molnar CC: Steven Rostedt --- No changes since v2. include/trace/events

[PATCH v6 5/5] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-21 Thread Shilpasri G Bhat
gives the total number of events of max frequency throttling to lower frequencies in the turbo range of frequencies and the sub-turbo(at and below nominal) range of frequencies. # cat /sys/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpasri G Bhat

Re: [PATCH v6 5/5] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-24 Thread Shilpasri G Bhat
Hi, On 01/23/2016 02:10 PM, Balbir Singh wrote: > On Fri, 22 Jan 2016 12:49:05 +0530 > Shilpasri G Bhat wrote: > >> Create sysfs attributes to export throttle information in >> /sys/devices/system/cpu/cpufreq/chipN. The newly added sysfs files are as >> follows: >

[PATCH v7 0/6] cpufreq: powernv: Redesign the presentation of throttle notification and solve bug-fixes in the driver

2016-01-27 Thread Shilpasri G Bhat
separating the tracepoint and sysfs attribute changes. Changes from v2: - Fixed kbuild test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (6): cpuf

[PATCH v7 1/6] cpufreq: powernv: Free 'chips' on module exit

2016-01-27 Thread Shilpasri G Bhat
This will free the dynamically allocated memory of'chips' on module exit. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index 547890

[PATCH v7 2/6] cpufreq: powernv: Hot-plug safe the kworker thread

2016-01-27 Thread Shilpasri G Bhat
Suggested-by: Gautham R Shenoy Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy Acked-by: Viresh Kumar --- No changes from v6. Changes form v5: - Fix the kbuild-error: drivers/cpufreq/powernv-cpufreq.c:428:2: error: implicit declaration of function 'get_online_cpus'

[PATCH v7 3/6] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-01-27 Thread Shilpasri G Bhat
he hotpath. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat --- Changes from v6: - Minor changes to move the code 'cpumask_copy()' after 'core_to_chip_map' is allocated. - Move 'kfree(chips)' to a separate patch. No changes from v5. Changes from v4: - T

[PATCH v7 4/6] cpufreq: powernv/tracing: Add powernv_throttle tracepoint

2016-01-27 Thread Shilpasri G Bhat
This patch adds the powernv_throttle tracepoint to trace the CPU frequency throttling event, which is used by the powernv-cpufreq driver in POWER8. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy CC: Ingo Molnar CC: Steven Rostedt --- No changes since v2. include/trace/events

[PATCH v7 5/6] cpufreq: powernv: Replace pr_info with trace print for throttle event

2016-01-27 Thread Shilpasri G Bhat
/pr_warn_once as pointed by MFG to not mark them as critical messages. This patch adds 'throttle_reason' to struct chip to store the throttle reason. Signed-off-by: Shilpasri G Bhat --- Changes from v6: - Rename struct chip member 'throt_reason' to 'throttle_reason' No cha

[PATCH v7 6/6] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-27 Thread Shilpasri G Bhat
This gives the total number of events of max frequency throttling to lower frequencies in the turbo range of frequencies and the sub-turbo(at and below nominal) range of frequencies. # cat /sys/devices/system/cpu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 Signed-off-by: Shilpasri

Re: [PATCH v7 6/6] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-28 Thread Shilpasri G Bhat
Hi Viresh, On 01/28/2016 02:10 PM, Viresh Kumar wrote: > On 28-01-16, 12:55, Shilpasri G Bhat wrote: >> diff --git a/Documentation/ABI/testing/sysfs-devices-system-cpu >> b/Documentation/ABI/testing/sysfs-devices-system-cpu >> index b683e8e..dea4620 100644 >> ---

Re: [PATCH v7 6/6] cpufreq: powernv: Add sysfs attributes to show throttle stats

2016-01-28 Thread Shilpasri G Bhat
On 01/28/2016 03:11 PM, Viresh Kumar wrote: > On 28-01-16, 15:06, Shilpasri G Bhat wrote: >> No these stats are not per-policy. They are per-chip. The throttle event is >> common for all cores in the chip. > > How do you define a chip? And how is it different the

[PATCH v8 0/6] cpufreq: powernv: Redesign the presentation of throttle notification and solve bug-fixes in the driver

2016-02-02 Thread Shilpasri G Bhat
test warning. drivers/cpufreq/powernv-cpufreq.c:609:2: warning: ignoring return value of 'kstrtoint', declared with attribute warn_unused_result [-Wunused-result] Shilpasri G Bhat (6): cpufre: powernv: Free 'chips' on module exit cpufreq: powernv: Hot-plug safe the kworke

[PATCH v8 1/6] cpufreq: powernv: Free 'chips' on module exit

2016-02-02 Thread Shilpasri G Bhat
This will free the dynamically allocated memory of 'chips' on module exit. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy Acked-by: Viresh Kumar --- Changes from v7: - Minor typo fix in the commit message drivers/cpufreq/powernv-cpufreq.c | 1 + 1 file changed, 1

[PATCH v8 2/6] cpufreq: powernv: Hot-plug safe the kworker thread

2016-02-02 Thread Shilpasri G Bhat
Suggested-by: Gautham R Shenoy Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy Acked-by: Viresh Kumar --- No changes from v7. drivers/cpufreq/powernv-cpufreq.c | 19 +++ 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/drivers/cpufreq/powernv

[PATCH v8 3/6] cpufreq: powernv: Remove cpu_to_chip_id() from hot-path

2016-02-02 Thread Shilpasri G Bhat
he hotpath. Reported-by: Anton Blanchard Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy Acked-by: Viresh Kumar --- No changes from v7. drivers/cpufreq/powernv-cpufreq.c | 23 --- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/drivers/cpufr

  1   2   3   >