On CPU hotplug, dying CPU is checked to see whether it is one of the
designated cpus, if yes, next online cpu from the same chip (for nest
units) is designated as new cpu to read counters. For this purpose, we
introduce a new state : CPUHP_AP_PERF_POWERPC_NEST_ONLINE.
Signed-off-by: Anju T
mc engine in cpuhot plug path
v3 -> v4 :
- Changed the events parser code to discover the PMU and events because
of the changed format of the IMC DTS file (Patch 3).
- Implemented the two TODOs to include core and thread IMC support with
this patchset (Patches 7 through 10).
- Changed t
From: Madhavan Srinivasan
Create a new header file to add the data structures and
macros needed for In-Memory Collection (IMC) counter support.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 99
Code to create platform device for the IMC counters.
Paltform devices are created based on the IMC compatibility
string.
New Config flag "CONFIG_HV_PERF_IMC_CTRS" add to contain the
IMC counter changes.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by
that all events supported by this PMU
inherit the scale and unit properties of the PMU itself. For those
events, we need to set the common unit and scale values.
For failure to initialize any unit or any event, disable that unit and
continue setting up the rest of them.
Signed-off-by: Hemant Kuma
ute and to
register imc pmus. Add a event_init function for nest_imc events.
Since, the IMC counters' data are periodically fed to a memory location,
the functions to read/update, start/stop, add/del can be generic and can
be used by all IMC PMU units.
Signed-off-by: Anju T Sudhakar
Signed-off-b
with the help of the "type" property in the IMC device tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by
Code to add support for detection of thread IMC events. It adds a new
domain IMC_DOMAIN_THREAD and it is determined with the help of the
"type" property in the imc device-tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
ar
ff-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h| 5 +
arch/powerpc/perf/imc-pmu.c | 203 --
arch/powerpc/plat
.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 3 +
arch/powerpc/include/asm/opal-api.h
kexec.
Signed-off-by: Hemant Kumar
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/includ
CPUHP_AP_PERF_POWERPC_THREAD_IMC_ONLINE is added to the list of existing
states.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/perf/imc-pmu.c | 35 +--
include/linux/cpuhotplug.h | 1 +
2 files changed, 34 insertions(+), 2 deletions(-)
diff --git a
Hi Thomas,
Thank you for reviewing the patch.
On Tuesday 06 June 2017 02:09 PM, Thomas Gleixner wrote:
On Mon, 5 Jun 2017, Anju T Sudhakar wrote:
+/*
+ * nest_imc_stop : Does OPAL call to stop nest engine.
+ */
+static void nest_imc_stop(int *cpu_opal_rc)
+{
+ int rc;
+
+ rc
Hi Thomas,
On Tuesday 06 June 2017 03:39 PM, Thomas Gleixner wrote:
On Mon, 5 Jun 2017, Anju T Sudhakar wrote:
+static void cleanup_all_core_imc_memory(struct imc_pmu *pmu_ptr)
+{
+ struct imc_mem_info *ptr = pmu_ptr->mem_info;
+
+ if (!ptr)
+ return;
Tha
On Wednesday 07 June 2017 11:14 AM, Anju T Sudhakar wrote:
Hi Thomas,
On Tuesday 06 June 2017 03:39 PM, Thomas Gleixner wrote:
On Mon, 5 Jun 2017, Anju T Sudhakar wrote:
+static void cleanup_all_core_imc_memory(struct imc_pmu *pmu_ptr)
+{
+struct imc_mem_info *ptr = pmu_ptr->mem_i
to IMC (In-Memory
Collection).
v1 -> v2 :
- Account for the cases where a PMU can have a common scale and unit
values for all its supported events (Patch 3/6).
From: Madhavan Srinivasan
Create a new header file to add the data structures and
macros needed for In-Memory Collection (IMC) counter support.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 99
Code to create platform device for the IMC counters.
Paltform devices are created based on the IMC compatibility
string.
New Config flag "CONFIG_HV_PERF_IMC_CTRS" add to contain the
IMC counter changes.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by
that all events supported by this PMU
inherit the scale and unit properties of the PMU itself. For those
events, we need to set the common unit and scale values.
For failure to initialize any unit or any event, disable that unit and
continue setting up the rest of them.
Signed-off-by: Hemant Kum
ute and to
register imc pmus. Add a event_init function for nest_imc events.
Since, the IMC counters' data are periodically fed to a memory location,
the functions to read/update, start/stop, add/del can be generic and can
be used by all IMC PMU units.
Signed-off-by: Anju T Sudhakar
Signed-off-b
From: Madhavan Srinivasan
This patch adds support for detection of core IMC events along with the
Nest IMC events. It adds a new domain IMC_DOMAIN_CORE and its determined
with the help of the "type" property in the IMC device tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: He
Code to add support for detection of thread IMC events. It adds a new
domain IMC_DOMAIN_THREAD and it is determined with the help of the
"type" property in the imc device-tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
ar
CPUHP_AP_PERF_POWERPC_THREAD_IMC_ONLINE is added to the list of existing
states.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/perf/imc-pmu.c | 38 +-
include/linux/cpuhotplug.h | 1 +
2 files changed, 38 insertions(+), 1 deletion(-)
diff --git a
.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 1 +
arch/powerpc/include/asm/opal-api.h
kexec.
Signed-off-by: Hemant Kumar
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/includ
ff-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h| 4 +
arch/powerpc/perf/imc-pmu.c | 228 +-
arch/po
ation) to IMC (In-Memory
Collection).
v1 -> v2 :
- Account for the cases where a PMU can have a common scale and unit
values for all its supported events (Patch 3/6).
- Fixed a Build error (for maple_defconfig) by enabling imc_pmu.o
only for CONFIG_PPC_POWERNV=y (Patch 4/6)
-
From: Madhavan Srinivasan
Create a new header file to add the data structures and
macros needed for In-Memory Collection (IMC) counter support.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 99
Code to create platform device for the IMC counters.
Paltform devices are created based on the IMC compatibility
string.
New Config flag "CONFIG_HV_PERF_IMC_CTRS" add to contain the
IMC counter changes.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by
that all events supported by this PMU
inherit the scale and unit properties of the PMU itself. For those
events, we need to set the common unit and scale values.
For failure to initialize any unit or any event, disable that unit and
continue setting up the rest of them.
Signed-off-by: Hemant Kum
ute and to
register imc pmus. Add a event_init function for nest_imc events.
Since, the IMC counters' data are periodically fed to a memory location,
the functions to read/update, start/stop, add/del can be generic and can
be used by all IMC PMU units.
Signed-off-by: Anju T Sudhakar
Signed-off-b
From: Madhavan Srinivasan
This patch adds support for detection of core IMC events along with the
Nest IMC events. It adds a new domain IMC_DOMAIN_CORE and its determined
with the help of the "type" property in the IMC device tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: He
Code to add support for detection of thread IMC events. It adds a new
domain IMC_DOMAIN_THREAD and it is determined with the help of the
"type" property in the imc device-tree.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
ar
cpus.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h| 4 +
arch/powerpc/perf/imc-pmu.c | 241 --
arch/powerpc/platforms/powernv/opal-imc.c | 2 +
3 files changed
.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Hemant Kumar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/include/asm/imc-pmu.h | 11 +
arch/powerpc/include/asm/opal-api.h
CPUHP_AP_PERF_POWERPC_THREAD_IMC_ONLINE is added to the list of existing
states.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/perf/imc-pmu.c | 38 +-
include/linux/cpuhotplug.h | 1 +
2 files changed, 38 insertions(+), 1 deletion(-)
diff --git a
kexec.
Signed-off-by: Hemant Kumar
Signed-off-by: Anju T Sudhakar
Signed-off-by: Madhavan Srinivasan
---
arch/powerpc/includ
Hi mpe,
On Thursday 21 September 2017 10:04 AM, Michael Ellerman wrote:
Anju T Sudhakar writes:
Nest/core pmu units are enabled only when it is used. A reference count is
maintained for the events which uses the nest/core pmu units. Currently in
*_imc_counters_release function a WARN() is
the ref count will not hit a negative value.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 28
1 file changed, 28 insertions(+)
diff --
Hi Santosh,
On Thursday 05 October 2017 03:20 PM, Santosh Sivaraj wrote:
* Anju T Sudhakar wrote (on 2017-10-04 06:50:52
+):
Nest/core pmu units are enabled only when it is used. A reference count is
maintained for the events which uses the nest/core pmu units. Currently in
Add a kernel command line parameter option to disable In-Memory Collection
(IMC) counters and add documentation. This helps in debug.
Signed-off-by: Anju T Sudhakar
Reviewed-By: Madhavan Srinivasan
---
Documentation/admin-guide/kernel-parameters.txt | 7 +
arch/powerpc/platforms/powernv
pu >= 0 && ncpu < nr_cpu_ids) {
but
unsigned int ncpu, core_id;
Suggest remove test.
Nice catch. Thanks for mentioning this. I will fix this.
Thanks,
Anju
Thanks.
Notifying the author would be more helpful:
$ git blame -L 599,599 arch/powerpc/perf/imc-pmu.c
39a846db1d574 (Anju T
imc_common_cpuhp_mem_free() to handle
the failing case gracefully.
Signed-off-by: Anju T Sudhakar
Reported-by: Pridhiviraj Paidipeddi
---
arch/powerpc/perf/imc-pmu.c | 23 ---
1 file changed, 16 insertions(+), 7 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch
Hi mpe, stewart,
On Wednesday 11 October 2017 01:55 AM, Stewart Smith wrote:
Michael Ellerman writes:
Anju T Sudhakar writes:
Add a kernel command line parameter option to disable In-Memory Collection
(IMC) counters and add documentation. This helps in debug.
I'd really rather we d
memory from a node which has no memory behind it. Add a ___GFP_NOWARN
flag in allocation request as a fix.
Signed-off-by: Anju T Sudhakar
Reported-by: Michael Ellerman
Reported-by: Venkat R.B
---
arch/powerpc/perf/imc-pmu.c | 8
1 file changed, 4 insertions(+), 4 deletions(-)
diff
prior to dereferencing the attribute
element,
to handle the failing case gracefully.
Signed-off-by: Anju T Sudhakar
Reported-by: Pridhiviraj Paidipeddi
---
arch/powerpc/perf/imc-pmu.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc
division up, fixing the bug.
Signed-off-by: Guilherme G. Piccoli
Acked-by: Anju T Sudhakar
---
Anju, looks good to you? Tested in P9 with latest FW available.
arch/powerpc/perf/imc-pmu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b
Add ldbar spr to sysfs. The spr will hold thread level In-Memory Collection
(IMC)
counter configuration data.
Signed-off-by: Anju T Sudhakar
Acked-by: Madhavan Srinivasan
---
arch/powerpc/kernel/sysfs.c | 8
1 file changed, 8 insertions(+)
diff --git a/arch/powerpc/kernel/sysfs.c b
: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 15 +++
1 file changed, 15 insertions(+)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c
index 8812624..08139f9 100644
--- a/arch/powerpc/perf/imc-pmu.c
+++ b/arch/powerpc/perf/imc-pmu.c
@@ -30,6 +30,7 @@ static
Change the data type for the variable 'ncpu' in ppc_core_imc_cpu_offline(),
since cpumask_any_but() returns an 'int' value.
Signed-off-by: Anju T Sudhakar
Reported-by: David Binderman
---
arch/powerpc/perf/imc-pmu.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-
Factor out memory freeing part for attribute elements from
imc_common_mem_free(),
also handle the memory leak for pmu->events in update_events_in_group().
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 24
1 file changed, 16 insertions(+)
Add ldbar spr to sysfs. The spr will hold thread level In-Memory Collection
(IMC)
counter configuration data.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/kernel/sysfs.c | 8
1 file changed, 8 insertions(+)
diff --git a/arch/powerpc/kernel/sysfs.c b/arch/powerpc/kernel/sysfs.c
Hi,
On Wednesday 01 November 2017 06:22 AM, Michael Ellerman wrote:
Anju T Sudhakar writes:
Call trace observed during boot:
What's the actual oops?
The actual oops is:
[0.750749] PCI: CLS 0 bytes, default 128
[0.750855] Unpacking initramfs...
[1.570445] Freeing i
re-imc counters are not even initialized. Thus creating the
above stack dump.
Add a check to see if core-imc counters are enabled or not in the cpuhotplug
offline path before migrating the context to handle this failing scenario.
Signed-off-by: Madhavan Srinivasan
Signed-off-by: Anju T Sudhakar
---
Hi mpe,
On Wednesday 01 November 2017 06:20 AM, Michael Ellerman wrote:
Anju T Sudhakar writes:
Add ldbar spr to sysfs. The spr will hold thread level In-Memory Collection
(IMC)
counter configuration data.
This is missing any justification for why we would want to expose this,
and in
, microcode could support more nest units (max of 64
nest units). Hence fix the value for the macro.
Fixes:8f95faaac56c1 ('powerpc/powernv: Detect and create IMC device')
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/imc-pmu.h | 2 +-
1 file changed, 1 insertion(+), 1 deletio
or not.
And bit 1 indicates the mode (if 0-Accumulation Mode/if 1-Trace Mode).
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/kernel/sysfs.c | 8
1 file changed, 8 insertions(+)
diff --git a/arch/powerpc/kernel/sysfs.c b/arch/powerpc/kernel/sysfs.c
index 4437c70..f8caee0 100644
--- a
Hi,
Kindly ignore this patch, I send a wrong version. Will send out the
right one.
Thanks,
Anju
On Thursday 09 November 2017 05:43 PM, Anju T Sudhakar wrote:
Add ldbar spr to sysfs. The spr holds thread level In-Memory Collection (IMC)
counter configuration data. Exposing this will help
or not.
And bit 1 indicates the mode (if 0-Accumulation Mode/if 1-Trace Mode).
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/kernel/sysfs.c | 8
1 file changed, 8 insertions(+)
diff --git a/arch/powerpc/kernel/sysfs.c b/arch/powerpc/kernel/sysfs.c
index 4437c70..caefb64 100644
--- a
root@:/sys/kernel/debug/imc# ls
imc_cmd_0 imc_cmd_8 imc_mode_0 imc_mode_8
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/
Hi,
Kindly ignore this version
Thanks,
Anju
On Monday 13 November 2017 11:06 AM, Anju T Sudhakar wrote:
In memory Collection (IMC) counter pmu driver controls the ucode's execution
state. At the system boot, IMC perf driver pause the ucode. Ucode state is
changed to "running"
root@:/sys/kernel/debug/imc# ls
imc_cmd_0 imc_cmd_8 imc_mode_0 imc_mode_8
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/
.
https://patchwork.ozlabs.org/patch/844047/ (v2)
Signed-off-by: Anju T Sudhakar
Reviewed-by: Madhavan Srinivasan
---
arch/powerpc/perf/imc-pmu.c | 14 ++
1 file changed, 14 insertions(+)
diff --git a
registered.
Fixes: 73ce9aec65b1 ("powerpc/perf: Fix IMC_MAX_PMU macro")
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c
index 0ead3cd..4eb9e2b 10
The first patch removes the unused variable in the code for
IMC(In-memory collection counters).
The second patch does some code refactoring.
The third patch in the series make struct imc_events as a parameter to the
function imc_parse_event().
Anju T Sudhakar (3):
powerpc/perf: Remove
Remove the global variable 'thread_imc_pmu', since it is not used in the code.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c
index 4eb9e2b..ef7f9dd 100644
less memory")
Suggested-by: Michael Ellerman
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/imc-pmu.h | 2 +-
arch/powerpc/perf/imc-pmu.c| 66 +++---
2 files changed, 41 insertions(+), 27 deletions(-)
diff --git a/arch/powerpc/include/asm/im
Factor out memory freeing part for attribute elements from
imc_common_cpuhp_mem_free().
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 31 ---
1 file changed, 20 insertions(+), 11 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc
ied in the
ima-catalog, that is used to export the imc mode/command, otherwise
IMC_CNTL_BLK_OFFSET is used.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/imc-pmu.h| 7 +++
arch/powerpc/platforms/powernv/opal-imc.c | 77 +
in V1 into a single patch.
- Comments by Masami are addressed.
- Some helper functions are implemented in separate patches.
- Optimization for kprobe placed on the kretprobe_trampoline during
boot time is implemented.
Kindly let me know your suggestions and comments.
Thanks,
-Anju
Anju T Su
buffer allocated and the instruction being probed
is within ?? 32MB.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Naveen N. Rao
---
.../features/debug/optprobes/arch-support.txt | 2 +-
arch/powerpc/Kconfig | 1 +
arch/powerpc/include/asm/kprobes.h
Kprobe placed on the kretprobe_trampoline during boot time can be
optimized, since the instruction at probe point is a 'nop'.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/kernel/kprobes.c | 8
arch/powerpc/kernel/optprobes.c | 7 +++
2 files changed, 11 insert
From: "Naveen N. Rao"
Introduce __PPC_SH64() as a 64-bit variant to encode shift field in some
of the shift and rotate instructions operating on double-words. Convert
some of the BPF instruction macros to use the same.
Signed-off-by: Naveen N. Rao
---
arch/powerpc/include/asm/ppc-opcode.h | 1
From: "Naveen N. Rao"
Signed-off-by: Naveen N. Rao
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/code-patching.h | 1 +
arch/powerpc/lib/code-patching.c | 24 +++-
2 files changed, 24 insertions(+), 1 deletion(-)
diff --git a/arch/power
Hi Masami,
Thank you for reviewing the patch set.
On Friday 16 December 2016 05:22 PM, Masami Hiramatsu wrote:
On Wed, 14 Dec 2016 21:48:30 +0530
Anju T Sudhakar wrote:
From: "Naveen N. Rao"
The coding is OK to me. Please add a description for this patch
here, e.g. what is do
Hi Masami,
On Friday 16 December 2016 07:32 PM, Masami Hiramatsu wrote:
On Wed, 14 Dec 2016 21:48:27 +0530
Anju T Sudhakar wrote:
Detour buffer contains instructions to create an in memory pt_regs.
After the execution of the pre-handler, a call is made for instruction
emulation.
The NIP
Hi Balbir,
On Friday 16 December 2016 08:16 PM, Balbir Singh wrote:
On 15/12/16 03:18, Anju T Sudhakar wrote:
This is the V2 patchset of the kprobes jump optimization
(a.k.a OPTPROBES)for powerpc. Kprobe being an inevitable tool
for kernel developers, enhancing the performance of kprobe has
ressed.
- Description in the cover letter is modified a bit.
Kindly let me know your suggestions and comments.
Thanks,
-Anju
Anju T Sudhakar (2):
arch/powerpc: Implement Optprobes
arch/powerpc: Optimize kprobe in kretprobe_trampoline
Naveen N. Rao (2):
powerpc: asm/ppc-opcode.h: introduce __PP
buffer allocated and the instruction being probed
is within ?? 32MB.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Naveen N. Rao
---
.../features/debug/optprobes/arch-support.txt | 2 +-
arch/powerpc/Kconfig | 1 +
arch/powerpc/include/asm/kprobes.h
Kprobe placed on the kretprobe_trampoline during boot time can be
optimized, since the instruction at probe point is a 'nop'.
Signed-off-by: Anju T Sudhakar
Acked-by: Masami Hiramatsu
---
arch/powerpc/kernel/kprobes.c | 8
arch/powerpc/kernel/optprobes.c | 7 +++---
From: "Naveen N. Rao"
Introduce __PPC_SH64() as a 64-bit variant to encode shift field in some
of the shift and rotate instructions operating on double-words. Convert
some of the BPF instruction macros to use the same.
Signed-off-by: Naveen N. Rao
---
arch/powerpc/include/asm/ppc-opcode.h | 1
he current instruction.
This patch verifies whether the target address is within +/- 32MB
range or not.
Signed-off-by: Naveen N. Rao
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/code-patching.h | 1 +
arch/powerpc/lib/code-patching.c | 24 +++-
2 files c
Hi Michael,
Thank you so much for the review.
On Wednesday 01 February 2017 04:23 PM, Michael Ellerman wrote:
Anju T Sudhakar writes:
Detour buffer contains instructions to create an in memory pt_regs.
After the execution of the pre-handler, a call is made for instruction
emulation.
The
verifies whether the target address is within +/- 32MB
range or not.
Signed-off-by: Naveen N. Rao
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/code-patching.h | 1 +
arch/powerpc/lib/code-patching.c | 24 +++-
2 files changed, 24 insertions(+), 1
From: "Naveen N. Rao"
Introduce __PPC_SH64() as a 64-bit variant to encode shift field in some
of the shift and rotate instructions operating on double-words. Convert
some of the BPF instruction macros to use the same.
Signed-off-by: Naveen N. Rao
---
arch/powerpc/include/asm/ppc-opcode.h | 1
From: "Naveen N. Rao"
Fix two issues with kprobes.h on BE which were exposed with the optprobes work:
- one, having to do with a missing include for linux/module.h for
MODULE_NAME_LEN -- this didn't show up previously since the only users of
kprobe_lookup_name were in kprobes.c, which included li
the address range
between the detour buffer allocated and the instruction being probed
is within +/- 32MB.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Naveen N. Rao
Acked-by: Masami Hiramatsu
---
arch/powerpc/Kconfig | 1 +
arch/powerpc/include/asm/code-patching.h | 1
suggestions and comments.
Thanks,
-Anju
Anju T Sudhakar (2):
arch/powerpc: Implement Optprobes
arch/powerpc: Optimize kprobe in kretprobe_trampoline
arch/powerpc/Kconfig | 1 +
arch/powerpc/include/asm/code-patching.h | 1 +
arch/powerpc/include/asm/kprobes.h
Kprobe placed on the kretprobe_trampoline during boot time can be
optimized, since the instruction at probe point is a 'nop'.
Signed-off-by: Anju T Sudhakar
Acked-by: Masami Hiramatsu
---
arch/powerpc/kernel/kprobes.c | 8
arch/powerpc/kernel/optprobes.c | 7 +++---
this purpose.
Instructions which can be emulated using analyse_instr() are the candidates
for optimization. Before optimization ensure that the address range
between the detour buffer allocated and the instruction being probed
is within +/- 32MB.
Signed-off-by: Anju T Sudhakar
Signed-off-by: Naveen
Hi Dan Carpenter,
On Wednesday 31 January 2018 08:55 PM, Dan Carpenter wrote:
Hello Anju T Sudhakar,
The patch 885dcd709ba9: "powerpc/perf: Add nest IMC PMU support" from
Jul 19, 2017, leads to the following static checker warning:
arch/powerpc/perf/imc-pmu.c:1393 in
Hi,
On Tuesday 06 March 2018 04:35 PM, Michael Ellerman wrote:
Anju T Sudhakar writes:
diff --git a/arch/powerpc/kernel/sysfs.c b/arch/powerpc/kernel/sysfs.c
index 4437c70..caefb64 100644
--- a/arch/powerpc/kernel/sysfs.c
+++ b/arch/powerpc/kernel/sysfs.c
@@ -757,6 +759,9 @@ static int
exec works
The first three patches in this series addresses the comments by Dan Carpenter.
Anju T Sudhakar (4):
powerpc/perf: Rearrange memory freeing in imc init
avoid such access.
Also free the memory which is dynamically allocated during imc initialization,
wherever required.
Signed-off-by: Anju T Sudhakar
---
test matrix and static checker run details are updated in the cover letter
patch is based on
https://git.kernel.org/pub/scm/linux/kernel/git
Replace the direct return statement in imc_mem_init() with goto,
to adhere to the kernel coding style.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 18 ++
1 file changed, 10 insertions(+), 8 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch
Enable thread-imc in the kernel, only if core-imc is registered.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/include/asm/imc-pmu.h| 1 +
arch/powerpc/perf/imc-pmu.c | 12
arch/powerpc/platforms/powernv/opal-imc.c | 9 +
3 files changed, 22
Return proper error code for unknown domain during IMC initialization.
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c
index 1b285cd..4b4ca83 100644
--- a
able, will fix this issue.
Reported-by: Pridhiviraj Paidipeddi
Signed-off-by: Anju T Sudhakar
---
arch/powerpc/perf/imc-pmu.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/powerpc/perf/imc-pmu.c b/arch/powerpc/perf/imc-pmu.c
index d7532e7..75fb23c 100644
--- a/arch/pow
Hi,
On Saturday 12 May 2018 06:05 AM, Balbir Singh wrote:
On Fri, May 11, 2018 at 11:43 PM, Anju T Sudhakar
wrote:
Currently memory is allocated for core-imc based on cpu_present_mask, which has
bit 'cpu' set iff cpu is populated. We use (cpu number / threads per core)
as as arra
On Friday 11 May 2018 07:13 PM, Anju T Sudhakar wrote:
Currently memory is allocated for core-imc based on cpu_present_mask, which has
bit 'cpu' set iff cpu is populated. We use (cpu number / threads per core)
as as array index to access the memory.
So in a system with guarded co
101 - 200 of 218 matches
Mail list logo