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

2016-02-02 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 --- No changes from v7. include/trace/events/power.h | 22

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

2016-02-02 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 Reviewed-by: Gautham R. Shenoy Acked-by: Viresh Kumar --- No changes from v7. drivers/cpufreq/powernv-cpuf

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

2016-02-02 Thread Shilpasri G Bhat
pu/cpufreq/chip0/throttle_stat turbo 7 sub-turbo 0 3)/sys/devices/system/cpu/cpufreq/chipX/chip-mask This gives the list of cpus present in the chip. # cat /sys/devices/system/cpu/cpufreq/chip0/chip_mask 0-31 Signed-off-by: Shilpasri G Bhat Cc: linux-...@vger.

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

2016-02-03 Thread Shilpasri G Bhat
Hi, On 02/03/2016 01:57 PM, Viresh Kumar wrote: > On 03-02-16, 01:11, Shilpasri G Bhat wrote: >> static int init_chip_info(void) >> { >> unsigned int chip[256]; >> -unsigned int cpu, i; >> +unsigned int cpu; >> unsigned int prev_chip_id

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

2016-02-03 Thread Shilpasri G Bhat
Hi Rafael, On 02/03/2016 07:10 PM, Rafael J. Wysocki wrote: > Hi, > > On Tue, Feb 2, 2016 at 8:41 PM, Shilpasri G Bhat > wrote: >> In POWER8, OCC(On-Chip-Controller) can throttle the frequency of the >> CPU when the chip crosses its thermal and power limits. Currently, &

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

2016-02-03 Thread Shilpasri G Bhat
> > And now that you have mentioned that to me, why shouldn't this stats > directory be moved to debugfs ? :) > > We are never going to perform a store here, isn't it ? And is just for > information, nothing more. > I would very much like to keep the throttle stats either in cpuX/cpufreq or gl

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

2016-02-08 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 Signed-off-by: Shilpasri G Bhat --- Changes from v8: - Moved the sysfs attributes from cpu/cpufreq/chipX

[PATCH] powernv: powercap: Add hard minimum powercap

2019-02-27 Thread Shilpasri G Bhat
hard minimum powercap limit to allow the user to set the appropriate powercap value that can be managed by the system. Signed-off-by: Shilpasri G Bhat --- .../ABI/testing/sysfs-firmware-opal-powercap | 10 arch/powerpc/platforms/powernv/opal-powercap.c | 66

Re: [PATCH] powernv: powercap: Add hard minimum powercap

2019-02-27 Thread Shilpasri G Bhat
Hi, On 02/28/2019 10:14 AM, Daniel Axtens wrote: > Shilpasri G Bhat writes: > >> In POWER9, OCC(On-Chip-Controller) provides for hard and soft system >> powercapping range. The hard powercap range is guaranteed while soft >> powercap may or may not be asserted due

[PATCH v2] powernv: powercap: Add hard minimum powercap

2019-02-28 Thread Shilpasri G Bhat
export the hard minimum powercap limit to allow the user to set the appropriate powercap value that can be managed by the system. Signed-off-by: Shilpasri G Bhat --- Changes from V1: - s/asserted/enforced by OCC .../ABI/testing/sysfs-firmware-opal-powercap | 10 arch/powerpc/platforms

[PATCH V3] powernv: sensor-groups: Add debugfs file to enable/disable sensor groups

2019-04-10 Thread Shilpasri G Bhat
This patch provides support to disable and enable platform specific sensor groups like performance, utilization and frequency which are not supported in hwmon. Signed-off-by: Shilpasri G Bhat --- Changes from V2: - Rebase on master Changes from V1: - As per Michael Ellerman's suggestion, a

[PATCH v2] powernv: sensor-groups: Add debugfs file to enable/disable sensor groups

2018-10-23 Thread Shilpasri G Bhat
This patch provides support to disable and enable platform specific sensor groups like performance, utilization and frequency which are currently not supported in hwmon. Signed-off-by: Shilpasri G Bhat --- Changes from V1: - As per Michael Ellerman's suggestion, adding the "enable

[PATCH v2 0/2] hwmon: Add attributes to enable/disable sensors

2018-07-04 Thread Shilpasri G Bhat
This patch series adds new attribute to enable or disable a sensor in runtime. v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (2): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attributes to enable/disable sensor groups Documentation

[PATCH v2 1/2] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-04 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v2 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-04 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new per-senor sysfs attribute to disable and enable them. Signed-off-by: Shilpasri G Bhat --- Changes from v1: - Add per-sensor 'enable' attribute - Return -EN

Re: [PATCH v2 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-04 Thread Shilpasri G Bhat
Hi Guenter, Thanks for reviewing the patch. On 07/04/2018 08:16 PM, Guenter Roeck wrote: >> +/* Disable if last sensor in the group */ >> +send_command = true; >> +for (i = 0; i < sg->nr_sensor; i++) { >> +struct sensor_data *sd = sg->sensors[i]; >> + >> +

[PATCH v3 0/3] hwmon: Add attributes to enable/disable sensors

2018-07-05 Thread Shilpasri G Bhat
This patch series adds new attribute to enable or disable a sensor in runtime. v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (3): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attributes to enable

[PATCH v3 1/3] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-05 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v3 2/3] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-05 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new per-senor sysfs attribute to disable and enable them. Signed-off-by: Shilpasri G Bhat --- Changes from v2: - Writes to first 'enable' attribute of the se

[PATCH v3 3/3] hwmon: Document the sensor enable attribute and update ibmpowernv

2018-07-05 Thread Shilpasri G Bhat
Signed-off-by: Shilpasri G Bhat --- Documentation/hwmon/ibmpowernv | 35 +++- Documentation/hwmon/sysfs-interface | 82 + 2 files changed, 115 insertions(+), 2 deletions(-) diff --git a/Documentation/hwmon/ibmpowernv b/Documentation/hwmon

Re: [PATCH v3 2/3] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-05 Thread Shilpasri G Bhat
Hi, On 07/05/2018 09:07 PM, Guenter Roeck wrote: > On 07/05/2018 06:51 AM, Shilpasri G Bhat wrote: >> On-Chip-Controller(OCC) is an embedded micro-processor in POWER9 chip >> which measures various system and chip level sensors. These sensors >> comprises of environmenta

[PATCH v4 0/3] hwmon: Add attributes to enable/disable sensors

2018-07-06 Thread Shilpasri G Bhat
This patch series adds new attribute to enable or disable a sensor in runtime. v3 : https://lkml.org/lkml/2018/7/5/476 v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (3): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon

[PATCH v4 1/3] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-06 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v4 2/3] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-06 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new per-senor sysfs attribute to disable and enable them. Signed-off-by: Shilpasri G Bhat --- Changes from v3: - Add 'enable' attribute for each sensor

[PATCH v4 3/3] hwmon: Document the sensor enable attribute

2018-07-06 Thread Shilpasri G Bhat
Signed-off-by: Shilpasri G Bhat --- Documentation/hwmon/sysfs-interface | 62 + 1 file changed, 62 insertions(+) diff --git a/Documentation/hwmon/sysfs-interface b/Documentation/hwmon/sysfs-interface index fc337c3..f865dd7 100644 --- a/Documentation/hwmon

[PATCH v5 0/2] hwmon/powernv: Add attributes to enable/disable sensors

2018-07-14 Thread Shilpasri G Bhat
https://lkml.org/lkml/2018/7/6/379 v3 : https://lkml.org/lkml/2018/7/5/476 v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (2): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attributes to enable/disable s

[PATCH v5 1/2] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-14 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v5 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-14 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new per-senor sysfs attribute to disable and enable them. Signed-off-by: Shilpasri G Bhat --- Changes from v4: - As per Mpe's suggestion store device_node inste

Re: [PATCH v5 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-17 Thread Shilpasri G Bhat
Hi, On 07/17/2018 07:17 PM, Guenter Roeck wrote: > On 07/14/2018 11:54 PM, Shilpasri G Bhat wrote: >> On-Chip-Controller(OCC) is an embedded micro-processor in POWER9 chip >> which measures various system and chip level sensors. These sensors >> comprises of environmenta

[PATCH v6 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-18 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new per-senor sysfs attribute to disable and enable them. Signed-off-by: Shilpasri G Bhat --- Changes from v5: - Dont store the sensor node and parse the device-tree for

[PATCH v6 1/2] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-18 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v6 0/2] hwmon/powernv: Add attributes to enable/disable sensors

2018-07-18 Thread Shilpasri G Bhat
://lkml.org/lkml/2018/7/5/476 v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (2): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attributes to enable/disable sensor groups Documentation/hwmon/ibmpowernv

[PATCH v7 0/2] hwmon/powernv: Add attributes to enable/disable sensors

2018-07-19 Thread Shilpasri G Bhat
/2018/7/15/15 v4 : https://lkml.org/lkml/2018/7/6/379 v3 : https://lkml.org/lkml/2018/7/5/476 v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (2): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attribut

[PATCH v7 1/2] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-19 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v7 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-19 Thread Shilpasri G Bhat
sensors and maintains their values in main memory. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. Signed-off-by: Shilpasri G Bhat [stew...@linux.vnet.ibm.com: Commit message] --- Changes from v6: - Updated the commit message as per

[PATCH v8 0/2] hwmon/powernv: Add attributes to enable/disable sensors

2018-07-24 Thread Shilpasri G Bhat
/lkml/2018/7/15/15 v4 : https://lkml.org/lkml/2018/7/6/379 v3 : https://lkml.org/lkml/2018/7/5/476 v2 : https://lkml.org/lkml/2018/7/4/263 v1 : https://lkml.org/lkml/2018/3/22/214 Shilpasri G Bhat (2): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add

[PATCH v8 1/2] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-07-24 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH v8 2/2] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-07-24 Thread Shilpasri G Bhat
sensors and maintains their values in main memory. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. Signed-off-by: Shilpasri G Bhat [stew...@linux.vnet.ibm.com: Commit message] --- Changes from v7: - Use of_for_each_phandle() and

[PATCH] powernv: opal-sensor-groups: Add attributes to disable/enable sensors

2018-07-31 Thread Shilpasri G Bhat
This patch provides support to disable and enable plaform specific sensor groups like performance, utilization and frequency which are currently not supported in hwmon. Signed-off-by: Shilpasri G Bhat --- This patch is based on https://git.kernel.org/powerpc/c/04baaf28f40c68c35a413cd9d0db71

[RFC 1/2] powerpc/powernv: Enable support for OCC inband platform sensors

2017-03-09 Thread Shilpasri G Bhat
can be of two types like counter sensor and full sensor. Counter sensor record contains just the counter value. Full sensor contains sample value, min, max, accumulator. It also maintains min/max for three different clients which can be reset at runtime. Signed-off-by: Shilpasri G Bhat --- arch

[RFC 0/2] Add support for OCC inband sensors in P9

2017-03-09 Thread Shilpasri G Bhat
/skiboot/2017-March/006652.html Shilpasri G Bhat (2): powerpc/powernv: Enable support for OCC inband platform sensors hwmon: powernv: Hwmon driver for OCC inband power and temperature sensors .../devicetree/bindings/hwmon/ibmpowernv-occ.txt | 4 + Documentation/hwmon/ibmpowernv-occ

[RFC 2/2] hwmon: powernv: Hwmon driver for OCC inband power and temperature sensors

2017-03-09 Thread Shilpasri G Bhat
Add support to read power and temperature sensors from OCC inband sensors which are copied to main memory by OCC. Signed-off-by: Shilpasri G Bhat CC: Rob Herring CC: Mark Rutland CC: Jean Delvare CC: Guenter Roeck CC: Jonathan Corbet CC: devicet...@vger.kernel.org CC: linux-hw

Re: [RFC 2/2] hwmon: powernv: Hwmon driver for OCC inband power and temperature sensors

2017-03-09 Thread Shilpasri G Bhat
Hi Guenter, On 03/09/2017 05:40 PM, Guenter Roeck wrote: > On Thu, Mar 09, 2017 at 05:19:15PM +0530, Shilpasri G Bhat wrote: >> Add support to read power and temperature sensors from OCC inband >> sensors which are copied to main memory by OCC. >> > > Is this supposed

Re: [v2 PATCH] powernv-cpuidle: Validate DT property array size

2017-03-24 Thread Shilpasri G Bhat
idle states via cpuidle. > > Signed-off-by: Gautham R. Shenoy > --- > v1: https://lkml.org/lkml/2017/2/23/349 > Changes from v1: Print the full property array name in warning message. Reviewed-by: Shilpasri G Bhat > > drivers/cpuidle/cpuidle-powernv.c | 64 > +++

[PATCH] hwmon: (ibmpowernv) Add min/max attributes and current sensors

2017-04-20 Thread Shilpasri G Bhat
Add support for adding min/max values for the inband sensors copied by OCC to main memory. And also add current(mA) sensors to the list. Signed-off-by: Shilpasri G Bhat --- drivers/hwmon/ibmpowernv.c | 55 -- 1 file changed, 53 insertions(+), 2

Re: [PATCH] hwmon: (ibmpowernv) Add min/max attributes and current sensors

2017-04-21 Thread Shilpasri G Bhat
Hi Cedric, On 04/21/2017 05:17 PM, Cédric Le Goater wrote: > Hello Shilpasri, > > On 04/21/2017 06:31 AM, Shilpasri G Bhat wrote: >> Add support for adding min/max values for the inband sensors copied by >> OCC to main memory. And also add current(mA) sensors to the list

[PATCH V2] hwmon: (ibmpowernv) Add min/max attributes and current sensors

2017-04-27 Thread Shilpasri G Bhat
Add support for adding min/max values for the inband sensors copied by OCC to main memory. And also add current(mA) sensors to the list. Signed-off-by: Shilpasri G Bhat --- Changes from V1: - Add functions to get min and max attribute strings - Add function 'populate_sensor' to f

Re: [PATCH V2] hwmon: (ibmpowernv) Add min/max attributes and current sensors

2017-05-01 Thread Shilpasri G Bhat
Hi Guenter, On 04/28/2017 06:59 PM, Guenter Roeck wrote: > On 04/27/2017 10:59 PM, Shilpasri G Bhat wrote: >> Add support for adding min/max values for the inband sensors copied by >> OCC to main memory. And also add current(mA) sensors to the list. >> >> Sign

Re: [PATCH V2] hwmon: (ibmpowernv) Add min/max attributes and current sensors

2017-05-01 Thread Shilpasri G Bhat
On 05/02/2017 10:34 AM, Guenter Roeck wrote: > On 05/01/2017 09:35 PM, Shilpasri G Bhat wrote: >> Hi Guenter, >> >> On 04/28/2017 06:59 PM, Guenter Roeck wrote: >>> On 04/27/2017 10:59 PM, Shilpasri G Bhat wrote: >>>> Add support for adding min/m

[PATCH V3] hwmon: (ibmpowernv) Add highest/lowest attributes to sensors

2017-05-02 Thread Shilpasri G Bhat
OCC provides historical minimum and maximum value for the sensor readings. This patch exports them as highest and lowest attributes for the inband sensors copied by OCC to main memory. Signed-off-by: Shilpasri G Bhat --- Changes from V2: - Dropped "curr" type of sensors to fix the

[PATCH V4] hwmon: (ibmpowernv) Add highest/lowest attributes to sensors

2017-05-06 Thread Shilpasri G Bhat
OCC provides historical minimum and maximum value for the sensor readings. This patch exports them as highest and lowest attributes for the inband sensors copied by OCC to main memory. Signed-off-by: Shilpasri G Bhat --- Changes from V3: - Removed extra variable 'hwmon_index' -

[PATCH V5] hwmon: (ibmpowernv) Add highest/lowest attributes to sensors

2017-05-28 Thread Shilpasri G Bhat
OCC provides historical minimum and maximum value for the sensor readings. This patch exports them as highest and lowest attributes for the inband sensors copied by OCC to main memory. Signed-off-by: Shilpasri G Bhat --- Changes from V4: - Got rid of 'len' variable in populate_a

[RFC 0/2] Add support for OCC command/response interface

2017-06-04 Thread Shilpasri G Bhat
/007542.html Shilpasri G Bhat (2): powerpc/powernv: Get a unique token for async completions powerpc/powernv : Add support for OPAL-OCC command/response interface arch/powerpc/include/asm/opal-api.h| 40 ++- arch/powerpc/include/asm/opal.h| 4 + arch/powerpc

[RFC 1/2] powerpc/powernv: Get a unique token for async completions

2017-06-04 Thread Shilpasri G Bhat
This patch adds support to get a unique token for async completion requests. This will be used for creating non-repititive request handles for consecutive requests in OPAL-OCC command/response interface. Signed-off-by: Shilpasri G Bhat --- arch/powerpc/include/asm/opal.h | 1

[RFC 2/2] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-04 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat --- arch/powerpc/include/asm/opal-api.h| 40 ++- arch/powerpc/include/asm/opal.h| 3 + arch/powerpc/platforms/powernv/Makefile| 2 +- arch/powerpc/platforms/powernv/opal-occ.c | 349

[PATCH V2 0/2] Add support for OCC command/response interface

2017-06-13 Thread Shilpasri G Bhat
/007705.html Shilpasri G Bhat (2): powerpc/powernv: Get a unique token for async completions powerpc/powernv : Add support for OPAL-OCC command/response interface arch/powerpc/include/asm/opal-api.h| 41 +++- arch/powerpc/include/asm/opal.h| 4 + arch/powerpc

[PATCH V2 1/2] powerpc/powernv: Get a unique token for async completions

2017-06-13 Thread Shilpasri G Bhat
This patch adds support to get a unique token for async completion requests. This will be used for creating non-repititive request handles for consecutive requests in OPAL-OCC command/response interface. Signed-off-by: Shilpasri G Bhat --- No changes from V1 arch/powerpc/include/asm/opal.h

[PATCH V2 2/2] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-13 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat --- Changes from V2: - Remove spinlock and use atomic_t for setting and clearing flags - Fix endian swapping - Use pa() and va() before and after opal call for accessing buffer data - Replace (u8 *) with __be64 for buffer pointers - User

[PATCH V3 0/2] Add support for OCC command/response interface

2017-06-18 Thread Shilpasri G Bhat
/007705.html Shilpasri G Bhat (2): powerpc/powernv: Get a unique token for async completions powerpc/powernv : Add support for OPAL-OCC command/response interface arch/powerpc/include/asm/opal-api.h| 41 +++- arch/powerpc/include/asm/opal.h| 4 + arch/powerpc

[PATCH V3 1/2] powerpc/powernv: Get a unique token for async completions

2017-06-18 Thread Shilpasri G Bhat
This patch adds support to get a unique token for async completion requests. This will be used for creating non-repititive request handles for consecutive requests in OPAL-OCC command/response interface. Signed-off-by: Shilpasri G Bhat --- No changes from V2. arch/powerpc/include/asm/opal.h

[PATCH V3 2/2] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-18 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat --- Changes from V2: - Use atomic_set while dropping locks - Add rsp_consumed flag to protect the read() - Change the logging level of prints - Add MAX_POSSIBLE_CHIPS - Move the endian conversion of data to opal_occ_cmd_prepare() arch/powerpc

[PATCH] hwmon: (ibmpowernv) Add current(A) sensors

2017-06-19 Thread Shilpasri G Bhat
This patch exports current(A) sensors in inband sensors copied to main memory by OCC. Signed-off-by: Shilpasri G Bhat --- drivers/hwmon/ibmpowernv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/hwmon/ibmpowernv.c b/drivers/hwmon/ibmpowernv.c index 862b832

Re: [PATCH] hwmon: (ibmpowernv) Add current(A) sensors

2017-06-19 Thread Shilpasri G Bhat
Hi Cedric, On 06/19/2017 06:22 PM, Cédric Le Goater wrote: > On 06/19/2017 11:25 AM, Shilpasri G Bhat wrote: >> This patch exports current(A) sensors in inband sensors copied to >> main memory by OCC. >> >> Signed-off-by: Shilpasri G Bhat >> --- >> drivers

[PATCH V2 0/2] hwmon: (ibmpowernv) Add support for current(A) sensors

2017-06-19 Thread Shilpasri G Bhat
The first patch from Cedric in the patchset cleans up the driver to provide a neater way to define new sensor types. The second patch adds current sensor. Cédric Le Goater (1): hwmon: (ibmpowernv) introduce a legacy_compatibles array Shilpasri G Bhat (1): hwmon: (ibmpowernv) Add current(A

[PATCH V2 1/2] hwmon: (ibmpowernv) introduce a legacy_compatibles array

2017-06-19 Thread Shilpasri G Bhat
uce new sensor types. Let's introduce two different arrays (legacy and current) to make things easier for new sensor types. Signed-off-by: Cédric Le Goater Tested-by: Shilpasri G Bhat --- drivers/hwmon/ibmpowernv.c | 26 ++ 1 file changed, 18 insertions(+), 8 deletions

[PATCH V2 2/2] hwmon: (ibmpowernv) Add current(A) sensor

2017-06-19 Thread Shilpasri G Bhat
This patch exports current(A) sensors in inband sensors copied to main memory by OCC. Signed-off-by: Shilpasri G Bhat --- Changes from V1: - Rebased on top of Cedric's patch to remove legay-compatible type for the current(A) sensor. drivers/hwmon/ibmpowernv.c | 4 +++- 1 file chang

Re: [PATCH V2 1/2] hwmon: (ibmpowernv) introduce a legacy_compatibles array

2017-06-20 Thread Shilpasri G Bhat
On 06/20/2017 11:36 AM, Cédric Le Goater wrote: > On 06/20/2017 07:08 AM, Shilpasri G Bhat wrote: >> From: Cédric Le Goater >> >> Today, the type of a PowerNV sensor system is determined with the >> "compatible" property for legacy Firmwares and with the

[PATCH V4 0/2] Add support for OCC command/response interface

2017-06-21 Thread Shilpasri G Bhat
/007705.html Shilpasri G Bhat (2): powerpc/powernv: Get a unique token for async completions powerpc/powernv : Add support for OPAL-OCC command/response interface arch/powerpc/include/asm/opal-api.h| 41 +++- arch/powerpc/include/asm/opal.h| 4 + arch/powerpc

[PATCH V4 1/2] powerpc/powernv: Get a unique token for async completions

2017-06-21 Thread Shilpasri G Bhat
This patch adds support to get a unique token for async completion requests. This will be used for creating non-repititive request handles for consecutive requests in OPAL-OCC command/response interface. Signed-off-by: Shilpasri G Bhat --- - No changes from V3 arch/powerpc/include/asm/opal.h

[PATCH V4 2/2] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-21 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat --- - Hold occ->cmd_in_progress in read() - Reset occ->rsp_consumed if copy_to_user() fails arch/powerpc/include/asm/opal-api.h| 41 +++- arch/powerpc/include/asm/opal.h| 3 + arch/powerpc/platforms/p

Re: [PATCH V4 2/2] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-21 Thread Shilpasri G Bhat
Hi Cyril, On 06/22/2017 06:28 AM, Cyril Bur wrote: > On Wed, 2017-06-21 at 13:36 +0530, Shilpasri G Bhat wrote: >> In P9, OCC (On-Chip-Controller) supports shared memory based >> commad-response interface. Within the shared memory there is an OPAL >> command buffer and OCC

[PATCH V5] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-25 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat --- The skiboot patch for the interface is posted here: https://lists.ozlabs.org/pipermail/skiboot/2017-June/007960.html Changes from V4: - Add token as a parameter to the opal_occ_command() - Use per-occ counter for command request_id instead

Re: [PATCH V5] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-29 Thread Shilpasri G Bhat
On 06/27/2017 10:05 AM, Cyril Bur wrote: > On Mon, 2017-06-26 at 11:02 +0530, Shilpasri G Bhat wrote: >> In P9, OCC (On-Chip-Controller) supports shared memory based >> commad-response interface. Within the shared memory there is an OPAL >> command buffer and OCC response bu

[PATCH V6] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-29 Thread Shilpasri G Bhat
between OCC and the host. Signed-off-by: Shilpasri G Bhat Reviewed-by: Cyril Bur --- Changes from V5: - Rebased the opal_call to match the skiboot-master. Not sure if I need to add the IMC based OPAL call numbers [148-151] so I have not included them in this patch (which are already upstream in

Re: [PATCH V6] powerpc/powernv : Add support for OPAL-OCC command/response interface

2017-06-29 Thread Shilpasri G Bhat
Hi, On 06/30/2017 12:02 AM, Shilpasri G Bhat wrote: > In P9, OCC (On-Chip-Controller) supports shared memory based > commad-response interface. Within the shared memory there is an OPAL > command buffer and OCC response buffer that can be used to send > inband commands to OCC. This

[PATCH V7 0/3] powernv : Add support for OPAL-OCC command/response interface

2017-07-19 Thread Shilpasri G Bhat
power shifting ratio 3) Clear min/max for OCC sensor groups The skiboot patch for this interface is posted here: https://lists.ozlabs.org/pipermail/skiboot/2017-July/008293.html Shilpasri G Bhat (3): powernv: powercap: Add support for powercap framework powernv: Add support to set power-shifting

[PATCH V7 1/3] powernv: powercap: Add support for powercap framework

2017-07-19 Thread Shilpasri G Bhat
Adds a generic powercap framework to change the system powercap inband through OPAL-OCC command/response interface. Signed-off-by: Shilpasri G Bhat --- arch/powerpc/include/asm/opal-api.h| 5 +- arch/powerpc/include/asm/opal.h| 4 + arch/powerpc/platforms/powernv

[PATCH V7 2/3] powernv: Add support to set power-shifting-ratio

2017-07-19 Thread Shilpasri G Bhat
This patch adds support to set power-shifting-ratio for CPU-GPU which is used by OCC power capping algorithm. Signed-off-by: Shilpasri G Bhat --- arch/powerpc/include/asm/opal-api.h| 4 +- arch/powerpc/include/asm/opal.h| 3 + arch/powerpc/platforms/powernv

[PATCH V7 3/3] powernv : Add support to clear sensor groups data

2017-07-19 Thread Shilpasri G Bhat
Adds support for clearing different sensor groups. OCC inband sensor groups like CSM, Profiler, Job Scheduler can be cleared using this driver. The min/max of all sensors belonging to these sensor groups will be cleared. Signed-off-by: Shilpasri G Bhat --- Changes from V6: - Removed a generic

[PATCH] powernv: Add OCC driver to mmap sensor area

2017-09-28 Thread Shilpasri G Bhat
This driver provides interface to mmap the OCC sensor area to userspace to parse and read OCC inband sensors. Signed-off-by: Shilpasri G Bhat --- - The skiboot patch for this is posted here: https://lists.ozlabs.org/pipermail/skiboot/2017-September/009209.html arch/powerpc/platforms/powernv

[PATCH] powerpc/powernv : Add support to enable sensor groups

2017-11-26 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat --- The

Re: [PATCH] powerpc/powernv : Add support to enable sensor groups

2017-11-28 Thread Shilpasri G Bhat
Hi, On 11/28/2017 05:07 PM, Michael Ellerman wrote: > Shilpasri G Bhat writes: > >> Adds support to enable/disable a sensor group. This can be used to >> select the sensor groups that needs to be copied to main memory by >> OCC. Sensor groups like power, tempe

[PATCH] cpufreq: powernv: Define methods to parse positive & negative pstates

2017-11-29 Thread Shilpasri G Bhat
From: "Gautham R. Shenoy" Pstates are 8bit values but on POWER8 they are negative and on POWER9 they are positive. This patch adds helper routines to differentiate the sign to read the correct pstate value. Signed-off-by: Gautham R. Shenoy Tested-by: Shilpasri G Bhat --- drive

[PATCH] cpufreq: powernv: Add boost files to export ultra-turbo frequencies

2016-12-16 Thread Shilpasri G Bhat
boost sysfs file which can be used to disable/enable ultra-turbo frequencies. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 48 --- 1 file changed, 45 insertions(+), 3 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b

[PATCH V2] cpufreq: powernv: Add boost files to export ultra-turbo frequencies

2017-01-03 Thread Shilpasri G Bhat
boost sysfs file which can be used to disable/enable ultra-turbo frequencies. Signed-off-by: Shilpasri G Bhat Reviewed-by: Gautham R. Shenoy --- Changes from v1: - Print if WOF is enabled - s/clean_notifiers/cleanup_notifiers drivers/cpufreq/powernv-cpufreq.c | 50

Re: [PATCH] powerpc/powernv : Add support to enable sensor groups

2017-12-20 Thread Shilpasri G Bhat
Hi, On 12/04/2017 10:11 AM, Stewart Smith wrote: > Shilpasri G Bhat writes: >> On 11/28/2017 05:07 PM, Michael Ellerman wrote: >>> Shilpasri G Bhat writes: >>> >>>> Adds support to enable/disable a sensor group. This can be used to >>>> selec

[PATCH] cpufreq: powernv: Dont assume distinct pstate values for nominal and pmin

2018-01-11 Thread Shilpasri G Bhat
ernv: Replacing pstate_id with frequency table index") Reported-by: Alvin Wang Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpu

[PATCH] cpufreq: powernv: Check negative value returned by cpufreq_table_find_index_dl()

2018-02-12 Thread Shilpasri G Bhat
;. 1008freq_data.pstate_id = powernv_freqs[index].driver_data; 1009freq_data.gpstate_id = powernv_freqs[index].driver_data; 1010set_pstate(&freq_data); 1011 1012return powernv_freqs[index].frequency; 1013 } Signed-off-by: Shilpasri G Bhat --- dr

Re: [PATCH] cpufreq: powernv: Check negative value returned by cpufreq_table_find_index_dl()

2018-02-12 Thread Shilpasri G Bhat
Hi, On 02/12/2018 03:59 PM, Viresh Kumar wrote: > On 12-02-18, 15:51, Shilpasri G Bhat wrote: >> This patch fixes the below Coverity warning: >> >> *** CID 182816: Memory - illegal accesses (NEGATIVE_RETURNS) >> /drivers/cpufreq/powernv-cpufreq.c: 1008 in po

[PATCH V2] powerpc/powernv : Add support to enable sensor groups

2018-02-21 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH 0/3] Add support to disable sensor groups in P9

2018-03-22 Thread Shilpasri G Bhat
://lists.ozlabs.org/pipermail/skiboot/2018-March/010812.html Shilpasri G Bhat (3): powernv:opal-sensor-groups: Add support to enable sensor groups hwmon: ibmpowernv: Add attributes to enable/disable sensor groups powernv: opal-sensor-groups: Add attributes to disable/enable sensors .../ABI

[PATCH 1/3] powernv:opal-sensor-groups: Add support to enable sensor groups

2018-03-22 Thread Shilpasri G Bhat
Adds support to enable/disable a sensor group at runtime. This can be used to select the sensor groups that needs to be copied to main memory by OCC. Sensor groups like power, temperature, current, voltage, frequency, utilization can be enabled/disabled at runtime. Signed-off-by: Shilpasri G Bhat

[PATCH 3/3] powernv: opal-sensor-groups: Add attributes to disable/enable sensors

2018-03-22 Thread Shilpasri G Bhat
This patch provides support to disable and enable plaform specific sensor groups like performance, utilization and frequency. Signed-off-by: Shilpasri G Bhat --- .../ABI/testing/sysfs-firmware-opal-sensor-groups | 34 + .../powerpc/platforms/powernv/opal-sensor-groups.c | 80

[PATCH 2/3] hwmon: ibmpowernv: Add attributes to enable/disable sensor groups

2018-03-22 Thread Shilpasri G Bhat
. This patch provides support for enabling/disabling the sensor groups like power, temperature, current and voltage. This patch adds new sysfs attributes to disable and enable them. Signed-off-by: Shilpasri G Bhat --- - Should the new attributes be added to hwmon_chip_attrs[]? Documentation/hwmon

[PATCH] cpufreq: powernv: Fix the hardlockup by synchronus smp_call in timer interrupt

2018-04-23 Thread Shilpasri G Bhat
ff-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/cpufreq/powernv-cpufreq.c b/drivers/cpufreq/powernv-cpufreq.c index 0591874..7e0c752 100644 --- a/drivers/cpufreq/powernv-cpufreq.c +++ b/drivers/cpufreq/powernv-cpuf

Re: [PATCH] cpufreq: powernv: Fix the hardlockup by synchronus smp_call in timer interrupt

2018-04-23 Thread Shilpasri G Bhat
Hi, On 04/24/2018 10:40 AM, Stewart Smith wrote: > Shilpasri G Bhat writes: >> gpstate_timer_handler() uses synchronous smp_call to set the pstate >> on the requested core. This causes the below hard lockup: >> >> [c03fe566b320] [c01d5340] smp_call_

Re: [PATCH] cpufreq: powernv: Fix the hardlockup by synchronus smp_call in timer interrupt

2018-04-24 Thread Shilpasri G Bhat
Hi, On 04/24/2018 11:30 AM, Nicholas Piggin wrote: > On Tue, 24 Apr 2018 10:11:46 +0530 > Shilpasri G Bhat wrote: > >> gpstate_timer_handler() uses synchronous smp_call to set the pstate >> on the requested core. This causes the below hard lockup: >> >> [c0

Re: [PATCH] cpufreq: powernv: Fix the hardlockup by synchronus smp_call in timer interrupt

2018-04-24 Thread Shilpasri G Bhat
On 04/24/2018 01:01 PM, Nicholas Piggin wrote: > On Tue, 24 Apr 2018 12:47:32 +0530 > Shilpasri G Bhat wrote: > >> Hi, >> >> On 04/24/2018 11:30 AM, Nicholas Piggin wrote: >>> On Tue, 24 Apr 2018 10:11:46 +0530 >>> Shilpasri G Bhat wrote: >>

[PATCH] cpufreq: powernv: Remove global pstate ramp-down timer in POWER9

2018-04-24 Thread Shilpasri G Bhat
POWER9 doesnot support global pstate requests for the chip. So remove the timer logic which slowly ramps down the global pstate in P9 platforms. Signed-off-by: Shilpasri G Bhat --- drivers/cpufreq/powernv-cpufreq.c | 23 ++- 1 file changed, 18 insertions(+), 5 deletions

[PATCH V2] cpufreq: powernv: Fix the hardlockup by synchronus smp_call in timer interrupt

2018-04-25 Thread Shilpasri G Bhat
652f13 (timers, cpufreq/powernv: Initialize the gpstate timer as pinned) Cc: [4.8+] Reported-by: Nicholas Piggin Reported-by: Pridhiviraj Paidipeddi Signed-off-by: Shilpasri G Bhat --- Changes from V1: - Remove smp_call in the pstate handler. drivers/cpufreq/powernv-cpufreq.

<    1   2   3   >