Re: [PATCH] objtool: Don't fail the kernel build on fatal errors

2021-01-20 Thread Kamalesh Babulal
le (and bots) looking for objtool warnings than > ever before, so such warnings not likely to be ignored for long. > > Suggested-by: Nick Desaulniers > Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH v4 23/52] docs: trace-uses.rst: remove bogus c-domain tags

2020-10-01 Thread Kamalesh Babulal
On 01/10/20 12:11 pm, Mauro Carvalho Chehab wrote: > Em Thu, 1 Oct 2020 11:36:53 +0530 > Kamalesh Babulal escreveu: > >> On 30/09/20 6:54 pm, Mauro Carvalho Chehab wrote: >>> There are some c-domain tags that are wrong. While this won't >>> cause problems

Re: [PATCH v4 23/52] docs: trace-uses.rst: remove bogus c-domain tags

2020-09-30 Thread Kamalesh Babulal
om the output. > > Let's just place them at literal blocks. > tired with Sphinx v3.2.1, invalid C declaration warnings are not seen with the patch. > Signed-off-by: Mauro Carvalho Chehab Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH] [v2] tools/objtool: Fix unnecessary jumps

2020-08-11 Thread Kamalesh Babulal
r the change. It can be written like: "Previously cleanup() function was called under the out label for both fatal errors (ret < 0) and warnings. Now that cleanup() function is removed, the out label is no longer required. Remove it and return immediately for the fatal errors with ret a

Re: [PATCH] tools/objtool: Fix unnecessary jumps

2020-08-10 Thread Kamalesh Babulal
On 10/08/20 9:36 am, Youling Tang wrote: > There is no need to jump to the "out" tag when "ret < 0", just return > directly to "ret". > > Signed-off-by: Youling Tang > --- > tools/objtool/check.c | 16 > 1 file changed, 8 insertions(+), 8 deletions(-) > > diff --git a/tools/obj

Re: [PATCH] Revert "kbuild: use -flive-patching when CONFIG_LIVEPATCH is enabled"

2020-07-20 Thread Kamalesh Babulal
On 20/07/20 9:05 am, Joe Lawrence wrote: > On 7/17/20 2:29 PM, Josh Poimboeuf wrote: >> Use of the new -flive-patching flag was introduced with the following >> commit: >> >>    43bd3a95c98e ("kbuild: use -flive-patching when CONFIG_LIVEPATCH is >> enabled") >> >> This flag has several drawbacks:

Re: [PATCH v2] selftests/livepatch: adopt to newer sysctl error format

2020-07-14 Thread Kamalesh Babulal
l versions using '-q' option. > > Explicitly print the final status on success so that it can be verified > in the log. The error message is enough on failure. > > Reported-by: Kamalesh Babulal > Signed-off-by: Petr Mladek Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH] selftests/livepatch: adopt to newer sysctl error format

2020-07-13 Thread Kamalesh Babulal
On 11/07/20 12:01 am, Joe Lawrence wrote: > On Fri, Jul 10, 2020 at 05:27:35PM +0200, Petr Mladek wrote: >> On Fri 2020-07-10 10:40:43, Kamalesh Babulal wrote: >>> With procfs v3.3.16, the sysctl command doesn't prints the set key and >>> value on error. This chang

[PATCH] selftests/livepatch: adopt to newer sysctl error format

2020-07-09 Thread Kamalesh Babulal
_result string in test-ftrace.sh to match the expected output. With the patch, the test-ftrace.sh passes on v3.3.15, v3.3.16 versions of sysctl: ... # selftests: livepatch: test-ftrace.sh # TEST: livepatch interaction with ftrace_enabled sysctl ... ok ok 5 selftests: livepatch: test-ftrace.sh Sig

Re: [RFC][PATCH v4 27/32] objtool: mcount: Generic location and relocation table types

2020-06-09 Thread Kamalesh Babulal
; suggested. I reviewed the process in submitting-patches.rst and propose > the commit message: > > objtool: mcount: Extend mcountsym size > > Before we can move this function out of the wrapper and into > wordsize-independent code we need to explicitly size the > type returned from get_mcountsym() to preserve the symbol info. > > Reported-by: Kamalesh Babulal > Signed-off-by: Kamalesh Babulal > Signed-off-by: Matt Helsley > > Is that OK with you or do you have another preference? Thanks, it works for me. -- Kamalesh

Re: [RFC][PATCH v4 27/32] objtool: mcount: Generic location and relocation table types

2020-06-08 Thread Kamalesh Babulal
On 6/3/20 1:20 AM, Matt Helsley wrote: > Rather than building the exact ELF section data we need and > avoiding libelf's conversion step, use more GElf types > and then libelf's elfxx_xlatetof() functions to convert > the mcount locations (GElf_Addr) and associated relocations. > > This converts s

Re: [PATCH 2/2] objtool: Add support for relocations without addends

2020-06-02 Thread Kamalesh Babulal
- LGTM, minor nit-pick, checkpatch reports of missing space before '(' in the switch cases. With space issues resolved: Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH 2/3] objtool: Move struct objtool_file into arch-independent header

2020-05-27 Thread Kamalesh Babulal
ill be useful in all subcommands besides check, > and some subcommands may not want to include check.h to get the > definition, split the structure out into a new header meant for use > by all objtool subcommands. > > Signed-off-by: Matt Helsley Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH 3/3] objtool: Enable compilation of objtool for all architectures

2020-05-27 Thread Kamalesh Babulal
er than those for x86. As more > command support is enabled on various architectures the necessary > KConfig changes can be made (e.g. adding "STACK_VALIDATION") to > trigger building objtool. > > [ jpoimboe: remove aliases, add __weak macro, add error messages ] >

Re: [PATCH 1/3] objtool: Exit successfully when requesting help

2020-05-27 Thread Kamalesh Babulal
e exit code to crudely check that, for > example, building an objtool executable succeeds. > > Signed-off-by: Matt Helsley Reviewed-by: Kamalesh Babulal -- Kamalesh

[PATCH] MAINTAINERS: add lib/livepatch to LIVE PATCHING

2020-05-15 Thread Kamalesh Babulal
Add lib/livepatch to list of livepatching F: patterns in MAINTAINERS. Suggested-by: Jiri Kosina Signed-off-by: Kamalesh Babulal --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index 8e1eb98d..de4f6af03198 100644 --- a/MAINTAINERS +++ b

Re: [PATCH] MAINTAINERS: adjust to livepatch .klp.arch removal

2020-05-15 Thread Kamalesh Babulal
On 5/15/20 3:15 AM, Jiri Kosina wrote: > On Sat, 9 May 2020, Kamalesh Babulal wrote: > >>> Commit 1d05334d2899 ("livepatch: Remove .klp.arch") removed >>> arch/x86/kernel/livepatch.c, but missed to adjust the LIVE PATCHING entry >>> in MAINTAINERS. >

[PATCH] MAINTAINERS: Update LIVE PATCHING file list

2020-05-10 Thread Kamalesh Babulal
The current list of livepatching files is incomplete, update the list with the missing files. Included files are ordered by the command: ./scripts/parse-maintainers.pl --input=MAINTAINERS --output=MAINTAINERS --order Signed-off-by: Kamalesh Babulal --- The patch applies on top of livepatching

Re: [PATCH] MAINTAINERS: adjust to livepatch .klp.arch removal

2020-05-09 Thread Kamalesh Babulal
On 5/9/20 1:02 PM, Lukas Bulwahn wrote: > Commit 1d05334d2899 ("livepatch: Remove .klp.arch") removed > arch/x86/kernel/livepatch.c, but missed to adjust the LIVE PATCHING entry > in MAINTAINERS. > > Since then, ./scripts/get_maintainer.pl --self-test=patterns complains: > > warning: no file ma

Re: [PATCH -next] livepatch: Make klp_apply_object_relocs static

2020-05-08 Thread Kamalesh Babulal
ly_object_relocs() has only one call site within core.c Reviewed-by: Kamalesh Babulal > --- > kernel/livepatch/core.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/kernel/livepatch/core.c b/kernel/livepatch/core.c > index 96d2da1..f76fdb9 1006

Re: [PATCH v3 3/3] selftests/livepatch: Test interaction with ftrace_enabled

2019-10-17 Thread Kamalesh Babulal
On 10/17/19 3:17 AM, Joe Lawrence wrote: > On 10/16/19 1:06 PM, Kamalesh Babulal wrote: >> On 10/16/19 5:03 PM, Miroslav Benes wrote: >>> From: Joe Lawrence >>> >>> Since livepatching depends upon ftrace handlers to implement "patched" >>> co

Re: [PATCH v3 2/3] selftests/livepatch: Make dynamic debug setup and restore generic

2019-10-16 Thread Kamalesh Babulal
On 10/16/19 5:03 PM, Miroslav Benes wrote: > From: Joe Lawrence > > Livepatch selftests currently save the current dynamic debug config and > tweak it for the selftests. The config is restored at the end. Make the > infrastructure generic, so that more variables can be saved and > restored. > >

Re: [PATCH v3 3/3] selftests/livepatch: Test interaction with ftrace_enabled

2019-10-16 Thread Kamalesh Babulal
On 10/16/19 5:03 PM, Miroslav Benes wrote: > From: Joe Lawrence > > Since livepatching depends upon ftrace handlers to implement "patched" > code functionality, verify that the ftrace_enabled sysctl value > interacts with livepatch registration as expected. At the same time, > ensure that ftrace

Re: [PATCH v2] ftrace: Introduce PERMANENT ftrace_ops flag

2019-10-15 Thread Kamalesh Babulal
ually, a callback with the flag > set cannot be registered if ftrace_enabled is disabled. > > Signed-off-by: Miroslav Benes The patch looks good to me. A minor typo in flag description below. Reviewed-by: Kamalesh Babulal [...] > diff --git a/include/linux/ftrace.h b/include/linux/f

Re: [PATCH v4 3/3] livepatch: Remove duplicate warning about missing reliable stacktrace support

2019-06-12 Thread Kamalesh Babulal
liable() cannot return > -ENOSYS thanks to klp_have_reliable_stack() check in > klp_try_switch_task(). > > Signed-off-by: Petr Mladek > [ mbenes: changelog edited ] > Signed-off-by: Miroslav Benes Reviewed-by: Kamalesh Babulal

Re: [PATCH v4 2/3] Revert "livepatch: Remove reliable stacktrace check in klp_try_switch_task()"

2019-06-12 Thread Kamalesh Babulal
> to have reliable stack traces support. The system only warns now about > it. > > It only makes sense to reintroduce the compile time checking in > klp_try_switch_task() again and bail out early. > > Signed-off-by: Miroslav Benes Reviewed-by: Kamalesh Babulal

Re: [PATCH v4 1/3] stacktrace: Remove weak version of save_stack_trace_tsk_reliable()

2019-06-12 Thread Kamalesh Babulal
-ENOSYS returning version for them. > > In short, stack_trace_save_tsk_reliable() returning -ENOSYS defined in > include/linux/stacktrace.h serves the same purpose as the old weak > version of save_stack_trace_tsk_reliable() which is therefore no longer > needed. > > Cc: Thomas Gleixner > Signed-off-by: Miroslav Benes Reviewed-by: Kamalesh Babulal

Re: [PATCH] stacktrace: fix CONFIG_ARCH_STACKWALK stack_trace_save_tsk_reliable return

2019-05-18 Thread Kamalesh Babulal
e > array. > > In the case of the above config and trace, be sure to return the > stacktrace_cookie.len on stack_trace_save_tsk_reliable() success. > > Fixes: 25e39e32b0a3f ("livepatch: Simplify stack trace retrieval") > Reported-by: Miroslav Benes > Signed-off-by: Joe Lawrence Reviewed-by: Kamalesh Babulal

Re: [PATCH] livepatch: Remove stale kobj_added entries from kernel-doc descriptions

2019-05-07 Thread Kamalesh Babulal
t; them. > > Reported-by: Kamalesh Babulal > Signed-off-by: Miroslav Benes Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH 2/2] livepatch: Remove duplicated code for early initialization

2019-05-03 Thread Kamalesh Babulal
code > was not duplicated. Let's deduplicate it for future generations > of livepatching hackers. > > The patch does not change the existing behavior. > > Signed-off-by: Petr Mladek Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH 1/2] livepatch: Remove custom kobject state handling

2019-05-03 Thread Kamalesh Babulal
bool patched; > bool transition; Minor nitpick, the description of kobj_added needs to be removed from structure descriptions. Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH v2 2/2] livepatch: Use static buffer for debugging messages under rq lock

2019-04-30 Thread Kamalesh Babulal
On Tue, Apr 30, 2019 at 11:10:49AM +0200, Petr Mladek wrote: > klp_try_switch_task() is called under klp_mutex. The buffer for > debugging messages might be static. > > Signed-off-by: Petr Mladek Reviewed-by: Kamalesh Babulal

Re: [PATCH v2 1/2] livepatch: Remove duplicate warning about missing reliable stacktrace support

2019-04-30 Thread Kamalesh Babulal
adek Reviewed-by: Kamalesh Babulal

Re: [PATCH 3/3] livepatch: Cleanup message handling in klp_try_switch_task()

2019-04-24 Thread Kamalesh Babulal
On Wed, Apr 24, 2019 at 08:48:58PM +0200, Miroslav Benes wrote: > On Wed, 24 Apr 2019, Josh Poimboeuf wrote: > [...] > > > ret = save_stack_trace_tsk_reliable(task, &trace); > > > - WARN_ON_ONCE(ret == -ENOSYS); > > > + if (ret == -ENOSYS) { > > > + if (!enosys_warned) { > > > +

Re: [PATCH 2/3] stacktrace: Remove superfluous WARN_ONCE() from save_stack_trace_tsk_reliable()

2019-04-24 Thread Kamalesh Babulal
On Wed, Apr 24, 2019 at 10:55:49AM +0200, Petr Mladek wrote: > WARN_ONCE() in the generic save_stack_trace_tsk_reliable() is superfluous. > The only current user klp_check_stack() writes its own warning when > -ENOSYS is returned. > > Signed-off-by: Petr Mladek Reviewed-by: K

Re: [PATCH 1/3] livepatch: Convert error about unsupported reliable stacktrace into a warning

2019-04-24 Thread Kamalesh Babulal
ition. > > Suggested-by: Josh Poimboeuf > Signed-off-by: Petr Mladek Reviewed-by: Kamalesh Babulal -- Kamalesh

Re: [PATCH] livepatch: Enforce reliable stack trace as config dependency

2019-02-11 Thread Kamalesh Babulal
On Mon, Feb 11, 2019 at 08:08:13AM -0600, Josh Poimboeuf wrote: > On Sat, Feb 09, 2019 at 02:47:28PM +0530, Kamalesh Babulal wrote: > > After removal of the immediate flag by commit d0807da78e11 > > ("livepatch: Remove immediate feature"), reliable stack trace became >

[PATCH] livepatch: Enforce reliable stack trace as config dependency

2019-02-09 Thread Kamalesh Babulal
ned-off-by: Kamalesh Babulal Cc: Miroslav Benes Cc: Petr Mladek Cc: Josh Poimboeuf Cc: Jiri Kosina --- Patch is based on a087cdd4073b (origin/for-5.1/atomic-replace) branch include/linux/livepatch.h | 6 -- kernel/livepatch/Kconfig | 2 ++ kernel/livepatch/core.c | 6 -- 3 files

Re: [PATCH v2] livepatch: core: Return EOPNOTSUPP instead of ENOSYS

2019-02-08 Thread Kamalesh Babulal
On Fri, Feb 08, 2019 at 10:34:45AM +0100, Petr Mladek wrote: > On Fri 2019-02-08 11:50:05, Kamalesh Babulal wrote: > > On Wed, Feb 06, 2019 at 11:28:32AM +0100, Petr Mladek wrote: > > > On Tue 2019-02-05 09:59:33, Josh Poimboeuf wrote: > > > > On Tue, Feb 05, 2

Re: [PATCH v2] livepatch: core: Return EOPNOTSUPP instead of ENOSYS

2019-02-08 Thread Kamalesh Babulal
Hi Miroslav, On Fri, Feb 08, 2019 at 10:24:21AM +0100, Miroslav Benes wrote: > Hi Kamalesh, > > On Fri, 8 Feb 2019, Kamalesh Babulal wrote: > > > On Wed, Feb 06, 2019 at 11:28:32AM +0100, Petr Mladek wrote: > > > On Tue 2019-02-05 09:59:33, Josh Poimboeuf wrote: >

Re: [PATCH v2] livepatch: core: Return EOPNOTSUPP instead of ENOSYS

2019-02-07 Thread Kamalesh Babulal
On Wed, Feb 06, 2019 at 11:28:32AM +0100, Petr Mladek wrote: > On Tue 2019-02-05 09:59:33, Josh Poimboeuf wrote: > > On Tue, Feb 05, 2019 at 03:33:28AM +0900, Alice Ferrazzi wrote: > > > From: Alice Ferrazzi > > > > > > As a result of an unsupported operation is better to use EOPNOTSUPP > > > as

[PATCH] static_keys.txt: Fix trivial spelling mistake

2019-02-04 Thread Kamalesh Babulal
Fix the spelling of 'functionnality' -> 'functionality'. Signed-off-by: Kamalesh Babulal --- Documentation/static-keys.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/static-keys.txt b/Documentation/static-keys.txt index d681355608

[PATCH] livepatch: Validate module/old func name length

2018-07-20 Thread Kamalesh Babulal
apply, to misspelled/incorrect names. At least gatekeep the modules with over the limit string length, by checking for their length during livepatch module registration. Signed-off-by: Kamalesh Babulal --- kernel/livepatch/core.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/kernel/livepatch

[PATCH v2] doc: livepatch: fix minor typo/grammar in shadow-vars.txt

2018-07-16 Thread Kamalesh Babulal
Fix the spelling of 'varibles' -> 'variables' and grammar in shadows->vars.txt file. Signed-off-by: Kamalesh Babulal Cc: Josh Poimboeuf --- v2 changes: - Fixed the grammar of the sentence as suggested by Josh Documentation/livepatch/shadow-vars.txt | 2 +- 1 file

[PATCH] doc: livepatch: fix minor typo in shadow-vars.txt

2018-07-15 Thread Kamalesh Babulal
Fix the spelling of 'varibles' -> 'variables' in shadows->vars.txt file. Signed-off-by: Kamalesh Babulal --- Documentation/livepatch/shadow-vars.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/livepatch/shadow-vars.txt b/Docu

Re: [PATCH] livepatch: Remove reliable stacktrace check in klp_try_switch_task()

2018-07-15 Thread Kamalesh Babulal
On Saturday 14 July 2018 12:07 AM, Josh Poimboeuf wrote: We bail out during patch registration for architectures, those don't support reliable stack trace. Does anybody know if that change was intentional? I thought the plan was to allow non-consistency-model arches to still use livepatch, and

[PATCH] livepatch: Remove reliable stacktrace check in klp_try_switch_task()

2018-07-12 Thread Kamalesh Babulal
Support for immediate flag was removed by commit d0807da78e11 ("livepatch: Remove immediate feature"). We bail out during patch registration for architectures, those don't support reliable stack trace. Remove the check in klp_try_switch_task(), as its not required. Signed-o

Re: [PATCH] powerpc/modules: remove unused mod_arch_specific.toc field

2018-05-24 Thread Kamalesh Babulal
f the __powerpc64__ #ifdef. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal

Re: [PATCH v4.2] powerpc/modules: Don't try to restore r2 after a sibling call

2017-11-17 Thread Kamalesh Babulal
eue(): 14c: 00 00 00 48 b 14c 14c: R_PPC64_REL24 net_set_todo 150: 00 00 82 3c addis r4,r2,0 GCC didn't insert a nop after the branch to net_set_todo() because it's a sibling call, so it never returns. The nop isn't needed a

Re: [PATCH v4 2/3] powerpc/modules: Don't try to restore r2 after a sibling call

2017-11-14 Thread Kamalesh Babulal
On Tuesday 14 November 2017 09:23 PM, Josh Poimboeuf wrote: On Tue, Nov 14, 2017 at 03:59:21PM +0530, Naveen N. Rao wrote: Kamalesh Babulal wrote: From: Josh Poimboeuf When attempting to load a livepatch module, I got the following error: module_64: patch_module: Expect noop after

[PATCH v4 0/3] ppc64le: Add REL24 relocation support of livepatch symbols

2017-11-14 Thread Kamalesh Babulal
. Josh Poimboeuf (2): powerpc/modules: Don't try to restore r2 after a sibling call powerpc/modules: Improve restore_r2() error message Kamalesh Babulal (1): kernel/modules: Add REL24 relocation support of livepatch symbols arch/powerpc/kernel/module_64.c | 11 --- 1 file chang

[PATCH v4 3/3] powerpc/modules: Improve restore_r2() error message

2017-11-14 Thread Kamalesh Babulal
, got 7c630034 at netdev_has_upper_dev+0x54/0xb0 [patch_foo] Signed-off-by: Josh Poimboeuf Signed-off-by: Kamalesh Babulal --- arch/powerpc/kernel/module_64.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/powerpc/kernel/module_64.c b/arch/powerpc/kernel/module_64.c

[PATCH v4 2/3] powerpc/modules: Don't try to restore r2 after a sibling call

2017-11-14 Thread Kamalesh Babulal
Signed-off-by: Kamalesh Babulal --- arch/powerpc/kernel/module_64.c | 4 1 file changed, 4 insertions(+) diff --git a/arch/powerpc/kernel/module_64.c b/arch/powerpc/kernel/module_64.c index 39b01fd..9e5391f 100644 --- a/arch/powerpc/kernel/module_64.c +++ b/arch/powerpc/kernel/module_64.c @@

[PATCH v4 1/3] kernel/modules: Add REL24 relocation support of livepatch symbols

2017-11-14 Thread Kamalesh Babulal
d for global calls. This issue can be fixed by teaching apply_relocate_add() to handle both SHN_UNDEF/SHN_LIVEPATCH symbols via the same stub. This patch extends SHN_UNDEF code to handle livepatch symbols too. Signed-off-by: Kamalesh Babulal CC: Balbir Singh Cc: Naveen N. Rao Cc: Josh Poimboeu

[PATCH] objtool: Fix ignore_func() description

2017-10-23 Thread Kamalesh Babulal
ignore_func() is limited to check if a symbol has been manually whitelisted using STACK_FRAME_NON_STANDARD macro. Change the function description accordingly. Cc: Ingo Molnar Signed-off-by: Kamalesh Babulal --- tools/objtool/check.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff

[PATCH] objtool: Refactor insn search in add_dead_ends()

2017-10-22 Thread Kamalesh Babulal
Move the search for instruction dead_end into helper function __add_dead_ends(), instead of duplicating the search for unreachable and reachable sections in add_dead_ends(). Cc: Ingo Molnar Signed-off-by: Kamalesh Babulal --- tools/objtool/check.c | 108

Re: [PATCH] objtool: Fix memory leak in decode_instructions()

2017-10-22 Thread Kamalesh Babulal
On Thursday 19 October 2017 08:02 PM, Josh Poimboeuf wrote: On Thu, Oct 19, 2017 at 09:31:37AM -0500, Josh Poimboeuf wrote: On Fri, Oct 13, 2017 at 11:20:58AM +0530, Kamalesh Babulal wrote: On Friday 13 October 2017 10:36 AM, Josh Poimboeuf wrote: On Fri, Oct 13, 2017 at 10:14:36AM +0530

[tip:core/urgent] objtool: Fix memory leak in decode_instructions()

2017-10-20 Thread tip-bot for Kamalesh Babulal
Commit-ID: b703798386fb7288d5a995bd2284a984a5e24f3c Gitweb: https://git.kernel.org/tip/b703798386fb7288d5a995bd2284a984a5e24f3c Author: Kamalesh Babulal AuthorDate: Thu, 19 Oct 2017 11:27:24 -0500 Committer: Ingo Molnar CommitDate: Fri, 20 Oct 2017 09:43:21 +0200 objtool: Fix memory

[tip:core/objtool] objtool: Print top level commands on incorrect usage

2017-10-18 Thread tip-bot for Kamalesh Babulal
Commit-ID: 6a93bb7e4a7d6670677d5b0eb980936eb9cc5d2e Gitweb: https://git.kernel.org/tip/6a93bb7e4a7d6670677d5b0eb980936eb9cc5d2e Author: Kamalesh Babulal AuthorDate: Sat, 14 Oct 2017 20:17:54 +0530 Committer: Ingo Molnar CommitDate: Wed, 18 Oct 2017 15:22:26 +0200 objtool: Print top

[PATCH v2] objtool: Print top level commands on incorrect usage

2017-10-14 Thread Kamalesh Babulal
usage: objtool COMMAND [ARGS] Commands: check Perform stack metadata validation on an object file orc Generate in-place ORC unwind tables for an object file $ echo $? 129 Cc: Ingo Molnar Signed-off-by: Kamalesh Babulal --- v2: - Changes to commit message only. tools/ob

Re: [PATCH] objtool: Print top level commands on incorrect usage

2017-10-14 Thread Kamalesh Babulal
On Friday 13 October 2017 10:08 PM, Josh Poimboeuf wrote: [...] Signed-off-by: Kamalesh Babulal --- tools/objtool/objtool.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tools/objtool/objtool.c b/tools/objtool/objtool.c index 31e0f91..07f3299 100644 --- a/tools

[PATCH] objtool: Print top level commands on incorrect usage

2017-10-13 Thread Kamalesh Babulal
: objtool COMMAND [ARGS] Commands: check Perform stack metadata validation on an object file orc Generate in-place ORC unwind tables for an object file $ echo $? 129 Cc: Ingo Molnar Signed-off-by: Kamalesh Babulal --- tools/objtool/objtool.c | 6 ++ 1 file changed, 2 insertions

Re: [PATCH] objtool: Fix memory leak in decode_instructions()

2017-10-12 Thread Kamalesh Babulal
On Friday 13 October 2017 10:36 AM, Josh Poimboeuf wrote: On Fri, Oct 13, 2017 at 10:14:36AM +0530, Kamalesh Babulal wrote: On Thursday 12 October 2017 09:40 PM, Josh Poimboeuf wrote: On Thu, Oct 12, 2017 at 02:32:14PM +0530, Kamalesh Babulal wrote: free the allocated insn before returning

Re: [PATCH] objtool: Fix memory leak in decode_instructions()

2017-10-12 Thread Kamalesh Babulal
On Thursday 12 October 2017 09:40 PM, Josh Poimboeuf wrote: On Thu, Oct 12, 2017 at 02:32:14PM +0530, Kamalesh Babulal wrote: free the allocated insn before returning, when an error occurs before adding insn to file->insn_list. Signed-off-by: Kamalesh Babulal Any chance you're wo

[PATCH] objtool: Fix memory leak in decode_instructions()

2017-10-12 Thread Kamalesh Babulal
free the allocated insn before returning, when an error occurs before adding insn to file->insn_list. Signed-off-by: Kamalesh Babulal --- tools/objtool/check.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tools/objtool/check.c b/tools/objtool/check.c in

Re: [PATCH v3 12/15] livepatch: store function sizes

2017-01-11 Thread Kamalesh Babulal
On Thursday 08 December 2016 11:38 PM, Josh Poimboeuf wrote: For the consistency model we'll need to know the sizes of the old and new functions to determine if they're on the stacks of any tasks. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 04/15] livepatch/x86: add TIF_PATCH_PENDING thread flag

2017-01-10 Thread Kamalesh Babulal
is placed in the _TIF_ALLWORK_MASK macro, which results in exit_to_usermode_loop() calling klp_update_patch_state() when it's set. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 10/15] livepatch: move patching functions into patch.c

2017-01-10 Thread Kamalesh Babulal
On Thursday 08 December 2016 11:38 PM, Josh Poimboeuf wrote: Move functions related to the actual patching of functions and objects into a new patch.c file. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 09/15] livepatch: remove unnecessary object loaded check

2017-01-10 Thread Kamalesh Babulal
Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 08/15] livepatch: separate enabled and patched states

2017-01-10 Thread Kamalesh Babulal
fully applied). - Patched means that an object's funcs are registered with ftrace and added to the klp_ops func stack. Also, since these states are binary, represent them with booleans instead of ints. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 02/15] x86/entry: define _TIF_ALLWORK_MASK flags explicitly

2017-01-10 Thread Kamalesh Babulal
explicitly. Signed-off-by: Josh Poimboeuf For the version with swapped _TIF_SINGLESTEP and _TIF_NEED_RESCHED flags. Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

Re: [PATCH v3 05/15] livepatch/powerpc: add TIF_PATCH_PENDING thread flag

2017-01-10 Thread Kamalesh Babulal
bit is included in the _TIF_USER_WORK_MASK macro so that do_notify_resume() and klp_update_patch_state() get called when the bit is set. Signed-off-by: Josh Poimboeuf Reviewed-by: Kamalesh Babulal -- cheers, Kamalesh.

[PATCH] powerpc/livepatch: Remove klp_write_module_reloc() stub

2016-12-15 Thread Kamalesh Babulal
commit 425595a7fc20 ("livepatch: reuse module loader code to write relocations") offloads livepatch module relocation write to arch specific module loader code. Remove unused klp_write_module_reloc() function stub. Signed-off-by: Kamalesh Babulal --- arch/powerpc/include/asm/livep

Re: [PATCH HACK 1/6] livepatch-test: Add more cases

2016-03-27 Thread Kamalesh Babulal
* Balbir Singh [2016-03-26 18:11:22]: > On Fri, Mar 25, 2016 at 3:37 AM, Kamalesh Babulal > wrote: > > * Michael Ellerman [2016-03-24 22:04:00]: > > > >> Not for merging. > >> > > > > Hi Michael, > > > > Loading the livepatch sample

Re: [PATCH HACK 1/6] livepatch-test: Add more cases

2016-03-24 Thread Kamalesh Babulal
* Michael Ellerman [2016-03-24 22:04:00]: > Not for merging. > Hi Michael, Loading the livepatch sample module, trigger following warning Mar 24 21:44:59 ubuntu kernel: [ 40.467580] sysfs: cannot create duplicate filename '/kernel/livepatch/livepatch_sample/vmlinux' Mar 24 21:44:59 ubuntu

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Kamalesh Babulal
* Torsten Duwe [2016-03-24 11:27:57]: > On Thu, Mar 24, 2016 at 03:44:55PM +0530, Kamalesh Babulal wrote: > > * Torsten Duwe [2016-03-23 16:58:58]: > > > > > > > > Since nobody liked the extra stack frame nor its workarounds, here is > > > the

Re: [PATCH/RFC] ppc64 livepatch: frameless klp_return_helper using odd TOC

2016-03-24 Thread Kamalesh Babulal
* Torsten Duwe [2016-03-23 16:58:58]: > > Since nobody liked the extra stack frame nor its workarounds, here is > the next attempt. Assumptions: > > 1. Heuristics are bad. The better they are, the more subtly the >way they might fail. > > 2. The TOC pointer is usually dividable by 4, if no

Re: [PATCH][v4] livepatch/ppc: Enable livepatching on powerpc

2016-03-03 Thread Kamalesh Babulal
> > I tested the sample in the livepatch > > Signed-off-by: Torsten Duwe > Signed-off-by: Balbir Singh > Signed-off-by: Petr Mladek Reviewed-by: Kamalesh Babulal I tried it, with the sample livepatch module. Tested-by: Kamalesh Babulal Thanks, Kamalesh.

Re: [RFC][PATCH][v2] Enable livepatching for powerpc

2016-03-03 Thread Kamalesh Babulal
tchwork.ozlabs.org/patch/587464/ > > Signed-off-by: Torsten Duwe > Signed-off-by: Balbir Singh Tested-by: Kamalesh Babulal

Re: [PATCH v3 1/8] powerpc: Create a helper for getting the kernel toc value

2016-03-02 Thread Kamalesh Babulal
* Michael Ellerman [2016-03-03 15:26:53]: > Move the logic to work out the kernel toc pointer into a header. This is > a good cleanup, and also means we can use it elsewhere in future. > > Reviewed-by: Kamalesh Babulal > Reviewed-by: Torsten Duwe > Signed-off-by: Michael

Re: [PATCH v2 5/8] powerpc/ftrace: Use generic ftrace_modify_all_code()

2016-03-01 Thread Kamalesh Babulal
t; > With this we gain error checking and the much-needed function_trace_op > handling. > > Reviewed-by: Balbir Singh > Signed-off-by: Torsten Duwe > Signed-off-by: Michael Ellerman Reviewed-by: Kamalesh Babulal

Re: [PATCH v2 2/8] powerpc/module: Only try to generate the ftrace_caller() stub once

2016-03-01 Thread Kamalesh Babulal
* Michael Ellerman [2016-02-29 20:26:23]: > Currently we generate the module stub for ftrace_caller() at the bottom > of apply_relocate_add(). However apply_relocate_add() is potentially > called more than once per module, which means we will try to generate > the ftrace_caller() stub multiple ti

Re: [PATCH v2 1/8] powerpc: Create a helper for getting the kernel toc value

2016-03-01 Thread Kamalesh Babulal
* Michael Ellerman [2016-02-29 20:26:22]: > Move the logic to work out the kernel toc pointer into a header. This is > a good cleanup, and also means we can use it elsewhere in future. > > Signed-off-by: Michael Ellerman Reviewed-by: Kamalesh Babulal

Re: [PATCH 01/12] powerpc/module: Only try to generate the ftrace_caller() stub once

2016-02-25 Thread Kamalesh Babulal
> from module_finalize(). An additional benefit is we can clean the ifdefs > up a little. > > Finally we must propagate the const'ness of some of the pointers passed > to module_finalize(), but that is also an improvement. > > Signed-off-by: Michael Ellerman For all of the patches in the series. Tested-by: Kamalesh Babulal Regards, Kamalesh.

Re: [PATCH v8 8/8] livepatch: Detect offset for the ftrace location during build

2016-02-23 Thread Kamalesh Babulal
* Torsten Duwe [2016-02-23 18:00:17]: > On Wed, Feb 17, 2016 at 02:08:41PM +1100, Michael Ellerman wrote: > > > > That stub uses r2 to find the location of itself, but it only works if r2 > > holds > > the TOC for scsi_mod.ko. In this case r2 still contains ibmvscsi.ko's TOC. > > Here's my sol

Re: [PATCH v8 8/8] livepatch: Detect offset for the ftrace location during build

2016-02-16 Thread Kamalesh Babulal
* Torsten Duwe [2016-02-16 09:23:02]: > On Tue, Feb 16, 2016 at 11:17:02AM +0530, Kamalesh Babulal wrote: > > * Petr Mladek [2016-02-12 17:45:17]: > > > int test(int a) > > > { > > > + printk("%d\n", a); > > > return ++a; > >

Re: [PATCH v8 8/8] livepatch: Detect offset for the ftrace location during build

2016-02-15 Thread Kamalesh Babulal
* Petr Mladek [2016-02-12 17:45:17]: [...] > I guess that you used a broken gcc and cheated the check > to pass the compilation. Did you, please? > > The test used to detect the offset is using a minimalistic > function is is afftected by the gcc bug. > > The patch below might be used to cheat

Re: [PATCH v8 4/8] ppc64 ftrace_with_regs configuration variables

2016-02-11 Thread Kamalesh Babulal
* Balbir Singh [2016-02-11 18:48:17]: > On Wed, 2016-02-10 at 17:25 +0100, Torsten Duwe wrote: > > snip > > > diff --git a/arch/powerpc/gcc-mprofile-kernel-notrace.sh > > b/arch/powerpc/gcc-mprofile-kernel-notrace.sh > > new file mode 100755 > > index 000..68d6482 > > --- /dev/null > > +++

Re: [RFC NEXT] mm: Fix suspicious RCU usage at kernel/sched/core.c:7318

2015-06-15 Thread Kamalesh Babulal
* Larry Finger [2015-06-15 16:25:18]: > Beginning at commit d52d399, the following INFO splat is logged: > [...] > --- > include/linux/kmemleak.h | 3 ++- > mm/kmemleak.c| 9 + > mm/kmemleak.c.rej| 19 +++ > mm/percpu.c | 2 +- > 4 f

Re: [RFC][PATCH 7/7] sched,dl: Convert switched_{from,to}_dl() / prio_changed_dl() to balance callbacks

2015-06-02 Thread Kamalesh Babulal
* Peter Zijlstra [2015-06-01 15:58:25]: [...] > > -static DEFINE_PER_CPU(struct callback_head, dl_balance_head); > +static DEFINE_PER_CPU(struct callback_head, dl_push_head); > +static DEFINE_PER_CPU(struct callback_head, dl_pull_head); > > static void push_dl_tasks(struct rq *); > +static

Re: [RFC][PATCH 1/7] sched: Replace post_schedule with a balance callback list

2015-06-02 Thread Kamalesh Babulal
* Peter Zijlstra [2015-06-01 15:58:19]: [...] > --- a/kernel/sched/deadline.c > +++ b/kernel/sched/deadline.c > @@ -213,9 +213,16 @@ static inline bool need_pull_dl_task(str > return dl_task(prev); > } > > -static inline void set_post_schedule(struct rq *rq) > +static DEFINE_PER_CPU(str

Re: [RFCv4 PATCH 22/34] sched: Calculate energy consumption of sched_group

2015-05-21 Thread Kamalesh Babulal
* Morten Rasmussen [2015-05-12 20:38:57]: [...] > +/* > + * cpu_norm_usage() returns the cpu usage relative to a specific capacity, > + * i.e. it's busy ratio, in the range [0..SCHED_LOAD_SCALE] which is useful > for > + * energy calculations. Using the scale-invariant usage returned by > + * ge

Re: [RFCv4 PATCH 13/34] sched: Documentation for scheduler energy cost model

2015-05-19 Thread Kamalesh Babulal
* Morten Rasmussen [2015-05-12 20:38:48]: [...] > +Energy consumed during transitions from an idle-state (C-state) to a busy > state > +(P-staet) or going the other way is ignored by the model to simplify the > energy Minor, nit pick. Spelling of "P-State". > +model calculations. Thanks, Kam

Re: [PATCH v5 06/12] sched: add per rq cpu_capacity_orig

2014-08-27 Thread Kamalesh Babulal
* Vincent Guittot [2014-08-26 13:06:49]: > This new field cpu_capacity_orig reflects the available capacity of a CPUs > unlike the cpu_capacity which reflects the current capacity that can be > altered > by frequency and rt tasks. > > Signed-off-by: Vincent Guittot Rev

Re: [PATCH v5 04/12] sched: Allow all archs to set the capacity_orig

2014-08-27 Thread Kamalesh Babulal
_orig. > > arch_scale_smt_capacity and default_scale_smt_capacity have been removed as > they were not use elsewhere than in arch_scale_cpu_capacity. > > Signed-off-by: Vincent Guittot Reviewed-by: Kamalesh Babulal -- To unsubscribe from this list: send the line "unsubscribe linux-ke

Re: [PATCH] powerpc/spufs: Remove MAX_USER_PRIO define

2014-02-11 Thread Kamalesh Babulal
* Jeremy Kerr [2014-02-11 14:05:17]: > Current ppc64_defconfig fails with: > > arch/powerpc/platforms/cell/spufs/sched.c:86:0: error: "MAX_USER_PRIO" > redefined [-Werror] > cc1: all warnings being treated as errors > > 6b6350f1 introduced a generic MAX_USER_PRIO macro to sched/prio.h, which

[PATCH TIRIVAL] sched/core: Use TASK_USER_PRIO macro in set_load_weight()

2014-02-10 Thread Kamalesh Babulal
Use TASK_USER_PRIO macro, instead of handcoding priority to set load weight. Signed-off-by: Kamalesh Babulal --- kernel/sched/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 104c8164e04f..5f1c24bc453a 100644 --- a/kernel

[PATCH] sched: use __weak for arch_update_cpu_topology/sched_clock

2013-12-02 Thread Kamalesh Babulal
Use __weak macro instead of __attribute__((weak)). Signed-off-by: Kamalesh Babulal --- kernel/sched/clock.c | 2 +- kernel/sched/core.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/kernel/sched/clock.c b/kernel/sched/clock.c index c3ae1446461c..08c4ea45fbfd 100644

[tip:sched/core] sched/fair: Clean up update_sg_lb_stats() a bit

2013-11-27 Thread tip-bot for Kamalesh Babulal
Commit-ID: 380c9077b38df2962a22f00f21f6cd0db62d3390 Gitweb: http://git.kernel.org/tip/380c9077b38df2962a22f00f21f6cd0db62d3390 Author: Kamalesh Babulal AuthorDate: Fri, 15 Nov 2013 15:06:52 +0530 Committer: Ingo Molnar CommitDate: Wed, 27 Nov 2013 13:50:57 +0100 sched/fair: Clean up

[PATCH RESEND] sched/fair: simple cleanup in update_sg_lb_stats()

2013-11-15 Thread Kamalesh Babulal
Add rq->nr_running to sgs->sum_nr_running directly instead of assigning it through an intermediate variable nr_running. Signed-off-by: Kamalesh Babulal --- kernel/sched/fair.c | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c

  1   2   3   4   >