RE: [PATCH 2/2] arm64: print alloc free paths for address in registers

2021-03-24 Thread Maninder Singh
__die(const char *str, int err, struct >> pt_regs *regs) >> >> print_modules(); >> show_regs(regs); >> +__show_regs_alloc_free(regs); > >As above, I'm not sure this is the right place to put this. We can get >here for reasons other than UAF, and I'm sure we can trigger panics via >UAF without going via this. > Adding call here, because we though in case of use after free __die will be called. due to unhandled page fault of 0x6b6b6 MAGIC value. thats why picked this place. Thanks, Maninder Singh

[PATCH 2/2] arm64: print alloc free paths for address in registers

2021-03-24 Thread Maninder Singh
svc_compat+0x1c/0x40 [ 19.549782] el0_svc_compat+0x24/0x38 [ 19.549913] el0_sync_compat_handler+0x90/0x158 [ 19.550067] el0_sync_compat+0x174/0x180 .. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm64/include/asm/system_misc.h | 1 + arch/arm64/kernel/pro

[PATCH 1/2] arm64/process.c: fix Wmissing-prototypes build warnings

2021-03-24 Thread Maninder Singh
asmlinkage void __sched arm64_preempt_schedule_irq(void) | ^~ Reported-by: kernel test robot Signed-off-by: Maninder Singh --- arch/arm64/include/asm/processor.h | 2 ++ arch/arm64/include/asm/thread_info.h | 2 ++ arch/arm64/kernel

[PATCH 1/1] arm64: print alloc free paths for address in registers

2021-03-19 Thread Maninder Singh
svc_compat+0x1c/0x40 [ 19.549782] el0_svc_compat+0x24/0x38 [ 19.549913] el0_sync_compat_handler+0x90/0x158 [ 19.550067] el0_sync_compat+0x174/0x180 .. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm64/include/asm/system_misc.h | 1 + arch/arm64/kernel/pro

[PATCH 3/3] arm: print alloc free paths for address in registers

2021-03-16 Thread Maninder Singh
[ 20.195336] ret_fast_syscall+0x0/0x58 [ 20.195491] 0xbeeacde4 Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm/include/asm/bug.h | 1 + arch/arm/kernel/process.c | 11 +++ arch/arm/kernel/traps.c| 1 + 3 files

[PATCH 2/3] mm/slub: Add Support for free path information of an object.

2021-03-16 Thread Maninder Singh
-by: Vaneet Narang Signed-off-by: Maninder Singh --- mm/slab.h| 1 + mm/slab_common.c | 12 +++- mm/slub.c| 7 +++ mm/util.c| 2 +- 4 files changed, 20 insertions(+), 2 deletions(-) diff --git a/mm/slab.h b/mm/slab.h index c96bca9825d9..e360e3326232 100644 --- a/mm

[PATCH 1/3] mm/slub: fixing backtrace of objects because of redzone adjustment

2021-03-16 Thread Maninder Singh
l+0x0/0x58 [ 14.873372] 0xbe861de4 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- mm/slub.c | 1 + 1 file changed, 1 insertion(+) diff --git a/mm/slub.c b/mm/slub.c index 1912c4614248..9d13f0117ae6 100644 --- a/mm/slub.c +++ b/mm/slub.c @@ -4052,6 +4052,7 @@ void kmem_obj_i

RE: [PATCH v2] arm: print alloc free paths for address in registers

2021-03-09 Thread Maninder Singh
Hi, Any comments or updates? >Sender : Maninder Singh Engineer/Platform S/W Group >/SRI-Delhi/Samsung Electronics >Date : 2021-02-25 13:57 (GMT+5:30) >Title : [PATCH v2] arm: print alloc free paths for address in registers > >In case of "Use After Free" kern

[PATCH v2] arm: print alloc free paths for address in registers

2021-02-25 Thread Maninder Singh
ect+0xa4/0xdc [ 124.378633] do_sendfile+0x1c4/0x3ec [ 124.379220] sys_sendfile64+0x128/0x130 [ 124.379822] ret_fast_syscall+0x0/0x54 [ 124.380421] 0xbe9a2de4 Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: do address sanity with virt_addr_

[PATCH 1/1] arm: print alloc free paths for address in registers

2021-02-24 Thread Maninder Singh
[ 124.378633] do_sendfile+0x1c4/0x3ec [ 124.379220] sys_sendfile64+0x128/0x130 [ 124.379822] ret_fast_syscall+0x0/0x54 [ 124.380421] 0xbe9a2de4 Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm/include/asm/bug.h | 1 + arch/arm/ker

RE: [PATCH 1/1] arm64/entry.S: check for stack overflow in el1 case only

2021-01-20 Thread Maninder Singh
Hi Mark, Will On Thu, Jan 07, 2021 at 11:29:03AM +, Mark Rutland wrote: >> On Fri, Dec 11, 2020 at 02:45:31PM +0530, Maninder Singh wrote: >> > current code checks for sp bit flip in all exceptions, >> > but only el1 exceptions requires this. el0 can not enter >&

[PATCH 1/1] arm64/entry.S: check for stack overflow in el1 case only

2020-12-11 Thread Maninder Singh
current code checks for sp bit flip in all exceptions, but only el1 exceptions requires this. el0 can not enter into stack overflow case directly. it will improve performance for el0 exceptions and interrupts. Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- arch/arm64/kernel

[PATCH 2/3] arm: introduce IRQ stacks

2020-10-08 Thread Maninder Singh
g Signed-off-by: Maninder Singh --- arch/arm/include/asm/assembler.h | 8 arch/arm/include/asm/irq.h | 6 ++ arch/arm/kernel/entry-armv.S | 41 +++- arch/arm/kernel/irq.c| 24 +++ 4 files changed, 78 i

[PATCH 1/3] arm: introduce self pointer in thread info

2020-10-08 Thread Maninder Singh
self pointer to thread info is added in thread info. It is base change required for IRQ stack on ARM. both stacks will have pointer to thread_info at bottom. Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm/Kconfig | 10

[PATCH 3/3] arm: Modify stack trace and dump for use with irq stack

2020-10-08 Thread Maninder Singh
on the old task stack. c_backtrace() is also modified on same logic, when traversing from last IRQ frame, update fp with SVC mode fp. Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/arm/include/asm/irq.h | 7 +++ arch/arm/kernel

[PATCH 0/3] IRQ stack support for ARM

2020-10-08 Thread Maninder Singh
will be at some performance cost, so code is under CONFIG_IRQ_STACK. and we don't have much knowledge and set up for CLANG and ARM_UNWIND, so dependency added for both cases. Tested patch set with QEMU for latest kernel and 4.1 kernel for ARM target with same patch set. Maninder Singh, Vaneet Narang (3): arm

RE: [PATCH 1/1] arm64: add support for PAGE_SIZE aligned kernel stack

2020-08-07 Thread Maninder Singh
Hi Mark, >>If you are seeing issues with the current stack size, can you please >>explain that in more detail? Where are you seeing problems? Which >>configuration options do you have selected? >> We checked on our system with netflix and youtube 4K videos running max stack consumption was 7

[PATCH 1/1] arm64: add support for PAGE_SIZE aligned kernel stack

2020-08-03 Thread Maninder Singh
faults as earlier. THREAD_SIZE masking in common files is changed to THREAD_SIZE_ALIGNED. Co-developed-by: Vaneet narang Signed-off-by: Vaneet narang Signed-off-by: Maninder Singh --- arch/arm64/Kconfig | 9 + arch/arm64/include/asm/memory.h | 29

[PATCH 1/1] arm64: use IRQ_STACK_SIZE instead of THREAD_SIZE for irq stack

2020-07-31 Thread Maninder Singh
IRQ_STACK_SIZE can be made different from THREAD_SIZE, and as IRQ_STACK_SIZE is used while irq stack allocation, same define should be used while printing information of irq stack. Signed-off-by: Maninder Singh --- arch/arm64/kernel/traps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion

[PATCH v2 4/4] scripts/checkstack.pl: fix arm sp regex

2020-05-08 Thread Maninder Singh
Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index bc07e19..d2c3858 100755 --- a/scripts/checkstack.pl +++ b/scripts/checkstack.pl @@ -60,7 +60,7

[PATCH v2 2/4] scripts/checkstack.pl: Add argument to print stacks greather than value.

2020-05-08 Thread Maninder Singh
Add arguments support to print stacks which are greater than argument value only. Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 11 --- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/scripts

[PATCH v2 3/4] scripts/checkstack.pl: add arm push handling for stack usage

2020-05-08 Thread Maninder Singh
[]: 492 Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 28 +++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/scripts/checkstack.pl b/scripts

[PATCH v2 1/4] scripts/checkstack.pl: don't display $dre as different entity

2020-05-08 Thread Maninder Singh
. 0xa00011f2720c0 sunxi_divs_clk_setup [vmlinux]: 464 ... 0xa00011f26f840 sunxi_mux_clk_setup.isra.0 [vmlinux]:320 Co-developed-by: Vaneet Narang Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1: https://lkml.org/lkml/2020/4/30/530 v2: review comments by Masahiro Yamada

RE:[PATCH 4/4] scripts/checkstack.pl: fix arm sp regex

2020-05-07 Thread Maninder Singh
Hi Masahiro, Thanks for review. We will integrate your review comements and send v2. >> >> so making regex $re for ARM similar to aarch64 >> >> Signed-off-by: Vaneet Narang >> Signed-off-by: Maninder Singh > > >This looks good to me, and it is a bug

[PATCH 4/4] scripts/checkstack.pl: fix arm sp regex

2020-04-30 Thread Maninder Singh
Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index b292ef4..e80de70 100755 --- a/scripts/checkstack.pl +++ b/scripts/checkstack.pl @@ -60,7 +60,7 @@ my (@stack, $re, $dre, $sub

[PATCH 2/4] scripts/checkstack.pl: Add argument to print stacks greather than value.

2020-04-30 Thread Maninder Singh
Add arguments support to print stacks which are greater than argument value only. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 12 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl

[PATCH 1/4] scripts/checkstack.pl: don't display $dre as different entity

2020-04-30 Thread Maninder Singh
. 0xa00011f2720c0 sunxi_divs_clk_setup [vmlinux]: 464 ... 0xa00011f26f840 sunxi_mux_clk_setup.isra.0 [vmlinux]:320 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 52 +-- 1 file changed, 25 insertions

[PATCH 3/4] scripts/checkstack.pl: add arm push handling for stack usage

2020-04-30 Thread Maninder Singh
Y []: 492 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- scripts/checkstack.pl | 27 ++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index 8e5ef98

[PATCH v3] mm/vmscan.c: change prototype for shrink_page_list

2020-04-29 Thread Maninder Singh
'commit 3c710c1ad11b ("mm, vmscan: extract shrink_page_list reclaim counters into a struct")' changed data type for the function, so changing return type for funciton and its caller. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: position of var

[PATCH v2] mm/vmscan.c: change prototype for shrink_page_list

2020-04-29 Thread Maninder Singh
'commit 3c710c1ad11b ("mm, vmscan: extract shrink_page_list reclaim counters into a struct")' changed data type for the function, so changing return type for funciton and its caller. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: position of var

RE:[PATCH 1/1] mm/vmscan.c: change prototype for shrink_page_list

2020-04-29 Thread Maninder Singh
t;> enum vm_event_item item; >> struct pglist_data *pgdat = lruvec_pgdat(lruvec); >> struct zone_reclaim_stat *reclaim_stat = >reclaim_stat; >> +unsigned int nr_reclaimed = 0; >> bool stalled = false; >> >> while (unlikely(too_many_isolated(pgdat, file, sc))) { Thanks, Maninder Singh

[PATCH 1/1] mm/vmscan.c: change prototype for shrink_page_list

2020-04-29 Thread Maninder Singh
'commit 3c710c1ad11b ("mm, vmscan: extract shrink_page_list reclaim counters into a struct")' changed data type for the function, so changing return type for funciton and its caller. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- mm/internal.h | 2 +- mm/page_al

[PATCH 2/4] zstd: use U16 data type for rankPos

2019-06-03 Thread Maninder Singh
e24ddc01sub sp, sp, #256; 0x100 changed: e92ddbf0push{r4, r5, r6, r7, r8, r9, fp, ip, lr, pc} e24cb004sub fp, ip, #4 e24dd080sub sp, sp, #128; 0x80 Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- lib/zstd/huf_compress.c | 4

[PATCH 0/4] zstd: reduce stack usage

2019-06-03 Thread Maninder Singh
[] (shrink_zone+0x53c/0x7c0) (shrink_zone) from [] (try_to_free_pages+0x2fc/0x7cc) (try_to_free_pages) from [] (__alloc_pages_nodemask+0x534/0x91c) (__alloc_pages_nodemask) from [] (pagecache_get_page+0xe0/0x1d8) Maninder Singh, Vaneet Narang (4): zstd: pass pointer rathen than structure

[PATCH 3/4] zstd: move params structure to global variable to reduce stack usage

2019-06-03 Thread Maninder Singh
As params structure remains same for lifetime, just initialise it at init time and make it global variable. Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- crypto/zstd.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/crypto/zstd.c b/crypto/zstd.c

[PATCH 1/1] splice: Reduce stack usage by reducing structure partial_page

2019-05-31 Thread Maninder Singh
]! ; 0xffdc ... e24dd0f4sub sp, sp, #244; 0xf4 : e16d42f4strdr4, [sp, #-36]! ; 0xffdc ... e24ddf45sub sp, sp, #276; 0x114 Tested on ARM. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- include

RE: race between flush_to_ldisc and pty_cleanup

2019-02-01 Thread Maninder Singh
Hi, >On Fri, Feb 01, 2019 at 07:03:26PM +0530, Maninder Singh wrote: >> Hi, >> >> >> There is some race condition between tty_port_put and flush_to_ldisc >> which lead to use after free case: >> (Kernel 4.1) >> >> [1403.5130] Unable

race between flush_to_ldisc and pty_cleanup

2019-02-01 Thread Maninder Singh
_dev ptmx_open chrdev_open do_dentry_open vfs_open do_last.isra.10 we already applied below patches: https://lore.kernel.org/patchwork/patch/862594/ But seems it is different case. Can you suggest any possible fix for this? Thanks, Maninder Singh

[PATCH 1/1] task_stack: make code generic for getting end of stack.

2018-12-19 Thread Maninder Singh
currently code provides end of stack by considering stack grows downwards. Make it useful for architectures where stack grows upward. Although CONFIG_THREAD_INFO_IN_TASK is selected only for architectures where stack grows downward. Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang

RE: linux-next: build warning after merge of the printk tree

2018-07-10 Thread Maninder Singh
Hi Petr, > Hi all, > After merging the printk tree, today's linux-next build (x86_64 > allnoconfig) produced this warning: > kernel/printk/printk.c:2033:13: warning: 'suppress_message_printing' defined > but not used [-Wunused-function] > static bool suppress_message_printing(int level) {

RE: linux-next: build warning after merge of the printk tree

2018-07-10 Thread Maninder Singh
Hi Petr, > Hi all, > After merging the printk tree, today's linux-next build (x86_64 > allnoconfig) produced this warning: > kernel/printk/printk.c:2033:13: warning: 'suppress_message_printing' defined > but not used [-Wunused-function] > static bool suppress_message_printing(int level) {

[PATCH v2] printk: make sure to print log on console.

2018-06-01 Thread Maninder Singh
, the messages might be handled after the consoles were silenced. reused flag LOG_NOCONS as its usage is gone long back. (5c2992ee7fd8a29d04125dc0aa3522784c5fa5eb) Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: make changes simpler as suggested by Petr Mladek.

[PATCH v2] printk: make sure to print log on console.

2018-06-01 Thread Maninder Singh
, the messages might be handled after the consoles were silenced. reused flag LOG_NOCONS as its usage is gone long back. (5c2992ee7fd8a29d04125dc0aa3522784c5fa5eb) Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: make changes simpler as suggested by Petr Mladek.

[PATCH 2/2] printk: make sure to print log on console.

2018-05-31 Thread Maninder Singh
or not(console_print) by checking current console loglevel with message's level at time of log. At time of print check this flag for printing message on console. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- kernel/printk/printk.c | 33 +++-- 1 file changed, 23

[PATCH 2/2] printk: make sure to print log on console.

2018-05-31 Thread Maninder Singh
or not(console_print) by checking current console loglevel with message's level at time of log. At time of print check this flag for printing message on console. Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- kernel/printk/printk.c | 33 +++-- 1 file changed, 23

[PATCH 1/2] printk: remove unused flag LOG_NOCONS

2018-05-31 Thread Maninder Singh
This patch removes unused flag LOG_NOCONS for printk. usage of this flag is removed long back with below commit. "5c2992ee7fd8a29d04125dc0aa3522784c5fa5eb" printk: remove console flushing special cases for partial buffered lines Signed-off-by: Maninder Singh Signed-off-by: Van

[PATCH 1/2] printk: remove unused flag LOG_NOCONS

2018-05-31 Thread Maninder Singh
This patch removes unused flag LOG_NOCONS for printk. usage of this flag is removed long back with below commit. "5c2992ee7fd8a29d04125dc0aa3522784c5fa5eb" printk: remove console flushing special cases for partial buffered lines Signed-off-by: Maninder Singh Signed-off-by: Van

[PATCH 1/1] um: add IRQENTRY and SOFTIRQENTRY points.

2018-04-20 Thread Maninder Singh
/27/357 Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- arch/um/kernel/dyn.lds.S | 2 ++ arch/um/kernel/uml.lds.S | 2 ++ 2 files changed, 4 insertions(+) diff --git a/arch/um/kernel/dyn.lds.S b/arch/um/kernel/dyn.lds.S i

[PATCH 1/1] um: add IRQENTRY and SOFTIRQENTRY points.

2018-04-20 Thread Maninder Singh
/27/357 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- arch/um/kernel/dyn.lds.S | 2 ++ arch/um/kernel/uml.lds.S | 2 ++ 2 files changed, 4 insertions(+) diff --git a/arch/um/kernel/dyn.lds.S b/arch/um/kernel/dyn.lds.S index d417e38..0fb2d3a 100644 --- a/arch/um/kernel/dyn.lds.S

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-04-16 Thread Maninder Singh
me >> memcpy 4918 MB/s 5108 MB/s 32768 100.00 data/data32k >> lz4 1.8.0 276 MB/s 1045 MB/s 14492 44.23 data/data32k >> >> LZO1x with 32K data (Default Compressor for ZRAM): >> sh-3.2# ./lzbench -elzo1x,1 data/data32k >> lzbench 1.7.3 (32-bit Linux) Assembled by P.Skibinski >> Compressor name Compress. Decompress. Compr. size Ratio Filename >> memcpy 5273 MB/s 5320 MB/s 32768 100.00 data/data32k >> lzo1x 2.09 -1 283 MB/s 465 MB/s 14292 43.62 data/data32k Thanks, Maninder Singh  

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-04-16 Thread Maninder Singh
me >> memcpy 4918 MB/s 5108 MB/s 32768 100.00 data/data32k >> lz4 1.8.0 276 MB/s 1045 MB/s 14492 44.23 data/data32k >> >> LZO1x with 32K data (Default Compressor for ZRAM): >> sh-3.2# ./lzbench -elzo1x,1 data/data32k >> lzbench 1.7.3 (32-bit Linux) Assembled by P.Skibinski >> Compressor name Compress. Decompress. Compr. size Ratio Filename >> memcpy 5273 MB/s 5320 MB/s 32768 100.00 data/data32k >> lzo1x 2.09 -1 283 MB/s 465 MB/s 14292 43.62 data/data32k Thanks, Maninder Singh  

Re: [PATCH v3] mm/page_owner: ignore everything below the IRQ entry point

2018-04-16 Thread Maninder Singh
es which we used in our patch. Thanks , Maninder Singh

Re: [PATCH v3] mm/page_owner: ignore everything below the IRQ entry point

2018-04-16 Thread Maninder Singh
es which we used in our patch. Thanks , Maninder Singh

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-04-02 Thread Maninder Singh
not an extension of LZ4 so there is no backward compatibility. Consider this as a different algorithm adapted from LZ4 for better compression ratio. Thanks Maninder Singh

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-04-02 Thread Maninder Singh
not an extension of LZ4 so there is no backward compatibility. Consider this as a different algorithm adapted from LZ4 for better compression ratio. Thanks Maninder Singh

Re: [PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-04-02 Thread Maninder Singh
Hi, >> diff --git a/drivers/block/zram/zcomp.c b/drivers/block/zram/zcomp.c >> index 4ed0a78..5bc5aab 100644 >> --- a/drivers/block/zram/zcomp.c >> +++ b/drivers/block/zram/zcomp.c >> @@ -17,11 +17,15 @@ >> #include >> >> #include "zcomp.h" >> +#define KB(1 << 10) >> >> static

Re: [PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-04-02 Thread Maninder Singh
Hi, >> diff --git a/drivers/block/zram/zcomp.c b/drivers/block/zram/zcomp.c >> index 4ed0a78..5bc5aab 100644 >> --- a/drivers/block/zram/zcomp.c >> +++ b/drivers/block/zram/zcomp.c >> @@ -17,11 +17,15 @@ >> #include >> >> #include "zcomp.h" >> +#define KB(1 << 10) >> >> static

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-03-29 Thread Maninder Singh
Hello Nick/Sergey,   Any suggestion or comments, so that we can change code and resend the patch?   > Hi Nick / Sergey, >  >  > We have compared LZ4 Dyn with Original LZ4 using some samples of realtime  >application data(4Kb) > compressed/decompressed by ZRAM. For comparison we have used lzbench 

Re: [PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-03-29 Thread Maninder Singh
Hello Nick/Sergey,   Any suggestion or comments, so that we can change code and resend the patch?   > Hi Nick / Sergey, >  >  > We have compared LZ4 Dyn with Original LZ4 using some samples of realtime  >application data(4Kb) > compressed/decompressed by ZRAM. For comparison we have used lzbench 

Re: [PATCH v2] mm/page_owner: ignore everything below the IRQ entry point

2018-03-27 Thread Maninder Singh
k, done. Sending new patch with fixes. Thanks. Maninder Singh    

Re: [PATCH v2] mm/page_owner: ignore everything below the IRQ entry point

2018-03-27 Thread Maninder Singh
k, done. Sending new patch with fixes. Thanks. Maninder Singh    

[PATCH v3] mm/page_owner: ignore everything below the IRQ entry point

2018-03-27 Thread Maninder Singh
ed-off-by: Maninder Singh <maninder...@samsung.com> --- v1->v2: fix build break for tile and blackfin (https://lkml.org/lkml/2017/12/3/287, verified for blackfin) v2->v3: remove inline as functions are larger, Declarations for __irqentry_text_start and friends are redundant. include/

[PATCH v3] mm/page_owner: ignore everything below the IRQ entry point

2018-03-27 Thread Maninder Singh
cpuidle_enter_state+0x96/0x290 do_idle+0x163/0x1a0 After patch:- __alloc_pages_nodemask+0xfc/0x220 page_frag_alloc+0x84/0x140 __napi_alloc_skb+0x83/0xe0 rtl8169_poll+0x1e5/0x670 net_rx_action+0x132/0x3a0 __do_softirq+0xce/0x298 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1

[PATCH v2] mm/page_owner: ignore everything below the IRQ entry point

2018-03-26 Thread Maninder Singh
+0x96/0x290 do_idle+0x163/0x1a0 After patch:- __alloc_pages_nodemask+0xfc/0x220 page_frag_alloc+0x84/0x140 __napi_alloc_skb+0x83/0xe0 rtl8169_poll+0x1e5/0x670 net_rx_action+0x132/0x3a0 __do_softirq+0xce/0x298 Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder

[PATCH v2] mm/page_owner: ignore everything below the IRQ entry point

2018-03-26 Thread Maninder Singh
+0x96/0x290 do_idle+0x163/0x1a0 After patch:- __alloc_pages_nodemask+0xfc/0x220 page_frag_alloc+0x84/0x140 __napi_alloc_skb+0x83/0xe0 rtl8169_poll+0x1e5/0x670 net_rx_action+0x132/0x3a0 __do_softirq+0xce/0x298 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1->v2: fix bu

Re: [PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-03-21 Thread Maninder Singh
CC: Vaneet Narang.   On (03/21/18 10:10), Maninder Singh wrote: > diff --git a/lib/lz4/lz4_compress.c b/lib/lz4/lz4_compress.c > index cc7b6d4..185c358 100644 > --- a/lib/lz4/lz4_compress.c > +++ b/lib/lz4/lz4_compress.c > @@ -183,7 +183,8 @@ static FORCE_INLINE int LZ4_c

Re: [PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-03-21 Thread Maninder Singh
CC: Vaneet Narang.   On (03/21/18 10:10), Maninder Singh wrote: > diff --git a/lib/lz4/lz4_compress.c b/lib/lz4/lz4_compress.c > index cc7b6d4..185c358 100644 > --- a/lib/lz4/lz4_compress.c > +++ b/lib/lz4/lz4_compress.c > @@ -183,7 +183,8 @@ static FORCE_INLINE int LZ4_c

[PATCH v2] arm/stacktrace: stop unwinding after an invalid address.

2018-03-21 Thread Maninder Singh
-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- v1->v2: https://lkml.org/lkml/2017/10/24/378 (take care of IRQ taken in SVC mode) arch/arm/kernel/stacktrace.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/kernel

[PATCH v2] arm/stacktrace: stop unwinding after an invalid address.

2018-03-21 Thread Maninder Singh
-by: Maninder Singh Signed-off-by: Vaneet Narang --- v1->v2: https://lkml.org/lkml/2017/10/24/378 (take care of IRQ taken in SVC mode) arch/arm/kernel/stacktrace.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/kernel/stacktrace.c b/arch/arm/kernel/stacktrace.c index a56e

[PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-03-20 Thread Maninder Singh
347866 seconds elapsed18.621296174 18.354183020 seconds elapsed22.366502860 22.357632546 seconds elapsed24.362417439 24.363003009 Maninder Singh, Vaneet Narang (1): lz4: Implement lz4 with dynamic offset (lz4_dyn). crypto/lz4.c

[PATCH 0/1] cover-letter/lz4: Implement lz4 with dynamic offset length.

2018-03-20 Thread Maninder Singh
347866 seconds elapsed18.621296174 18.354183020 seconds elapsed22.366502860 22.357632546 seconds elapsed24.362417439 24.363003009 Maninder Singh, Vaneet Narang (1): lz4: Implement lz4 with dynamic offset (lz4_dyn). crypto/lz4.c

[PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-03-20 Thread Maninder Singh
mem_used_total: 17117184 LZ4 orig_data_size: 78917632 compr_data_size: 16310717 mem_used_total: 17592320 LZ4_DYN === orig_data_size: 78917632 compr_data_size: 15520506 mem_used_total: 16748544 Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang

[PATCH 1/1] lz4: Implement lz4 with dynamic offset length.

2018-03-20 Thread Maninder Singh
mem_used_total: 17117184 LZ4 orig_data_size: 78917632 compr_data_size: 16310717 mem_used_total: 17592320 LZ4_DYN === orig_data_size: 78917632 compr_data_size: 15520506 mem_used_total: 16748544 Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- crypto/lz4.c | 64

[PATCH 1/1] mm/page_owner: fix recursion bug after changing skip entries

2018-03-20 Thread Maninder Singh
from (get_page_from_freelist) Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- mm/page_owner.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/page_owner.c b/mm/page_owner.c index 8592543..4

[PATCH 1/1] mm/page_owner: fix recursion bug after changing skip entries

2018-03-20 Thread Maninder Singh
from (get_page_from_freelist) Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- mm/page_owner.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/page_owner.c b/mm/page_owner.c index 8592543..46ab1c4 100644 --- a/mm/page_owner.c +++ b/mm/page_owner.c

[PATCH 1/1] mm/page_owner: ignore everything below the IRQ entry point

2017-12-03 Thread Maninder Singh
=be7635e7287e0e8013af3c89a6354a9e0182594c Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- include/linux/stacktrace.h | 25 + mm/kasan/kasan.c | 22 -- mm/page_owner.c

[PATCH 1/1] mm/page_owner: ignore everything below the IRQ entry point

2017-12-03 Thread Maninder Singh
=be7635e7287e0e8013af3c89a6354a9e0182594c Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- include/linux/stacktrace.h | 25 + mm/kasan/kasan.c | 22 -- mm/page_owner.c| 1 + 3 files changed, 26 insertions(+), 22 deletions

Re: [PATCH 1/1] stackdepot: interface to check entries and size of stackdepot.

2017-11-24 Thread Maninder Singh
Hi Michal, > On Wed 22-11-17 16:17:41, Maninder Singh wrote: > > This patch provides interface to check all the stack enteries > > saved in stackdepot so far as well as memory consumed by stackdepot. > > > > 1) Take current depot_index and offset to ca

Re: [PATCH 1/1] stackdepot: interface to check entries and size of stackdepot.

2017-11-24 Thread Maninder Singh
Hi Michal, > On Wed 22-11-17 16:17:41, Maninder Singh wrote: > > This patch provides interface to check all the stack enteries > > saved in stackdepot so far as well as memory consumed by stackdepot. > > > > 1) Take current depot_index and offset to ca

[PATCH 1/1] stackdepot: interface to check entries and size of stackdepot.

2017-11-22 Thread Maninder Singh
rnel/debug/depot_stack/depot_entries stack count 1 backtrace init_page_owner+0x1e/0x210 start_kernel+0x310/0x3cd secondary_startup_64+0xa5/0xb0 0x Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- include/lin

[PATCH 1/1] stackdepot: interface to check entries and size of stackdepot.

2017-11-22 Thread Maninder Singh
rnel/debug/depot_stack/depot_entries stack count 1 backtrace init_page_owner+0x1e/0x210 start_kernel+0x310/0x3cd secondary_startup_64+0xa5/0xb0 0x Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- include/linux/stackdepot.h | 13 +++ include/linux/stacktrace.h |

Re: [PATCH 1/1] arm/stacktrace: stop unwinding after an invalid address.

2017-11-15 Thread Maninder Singh
Hi Russell, >On Tue, Oct 24, 2017 at 05:16:42PM +0530, Maninder Singh wrote: >> This patch stops unwinding backtrace in case of below 2 cases. >> >> (Issue observed while porting stackdepot on ARM, duplicate >> entries created in stackdepot >> reference p

Re: [PATCH 1/1] arm/stacktrace: stop unwinding after an invalid address.

2017-11-15 Thread Maninder Singh
Hi Russell, >On Tue, Oct 24, 2017 at 05:16:42PM +0530, Maninder Singh wrote: >> This patch stops unwinding backtrace in case of below 2 cases. >> >> (Issue observed while porting stackdepot on ARM, duplicate >> entries created in stackdepot >> reference p

[PATCH 1/1] arm/stacktrace: stop unwinding after an invalid address.

2017-10-24 Thread Maninder Singh
+0xf8/0x1e0 trace_init+0xe0/0x2cc start_kernel+0x30c/0x448 0x400080a0 ^^^ Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- arch/arm/kernel/stacktrace.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-)

[PATCH 1/1] arm/stacktrace: stop unwinding after an invalid address.

2017-10-24 Thread Maninder Singh
+0xf8/0x1e0 trace_init+0xe0/0x2cc start_kernel+0x30c/0x448 0x400080a0 ^^^ Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- arch/arm/kernel/stacktrace.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/arch/arm/kernel/stacktrace.c b/arch/arm/kernel

[PATCH v2] stackdepot: ignore junk last entry in case of switch from user mode.

2017-10-11 Thread Maninder Singh
__handle_domain_irq+0x9c/0x130 gic_handle_irq+0x40/0x80 __irq_usr+0x4c/0x60 Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- v1 -> v2: use generic API to check whether address belongs to user space or not. lib/s

[PATCH v2] stackdepot: ignore junk last entry in case of switch from user mode.

2017-10-11 Thread Maninder Singh
__handle_domain_irq+0x9c/0x130 gic_handle_irq+0x40/0x80 __irq_usr+0x4c/0x60 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2: use generic API to check whether address belongs to user space or not. lib/stackdepot.c | 7 +++ 1 file changed, 7 insertions(+) d

[PATCH 1/1] stackdepot: ignore junk last entry in case of switch from user mode.

2017-10-11 Thread Maninder Singh
__handle_domain_irq+0x9c/0x130 gic_handle_irq+0x40/0x80 __irq_usr+0x4c/0x60 Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- lib/stackdepot.c | 5 + 1 file changed, 5 insertions(+) diff --git a/lib/stackd

[PATCH 1/1] stackdepot: ignore junk last entry in case of switch from user mode.

2017-10-11 Thread Maninder Singh
__handle_domain_irq+0x9c/0x130 gic_handle_irq+0x40/0x80 __irq_usr+0x4c/0x60 Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- lib/stackdepot.c | 5 + 1 file changed, 5 insertions(+) diff --git a/lib/stackdepot.c b/lib/stackdepot.c index f87d138..bb35b2c 100644 --- a/lib

[PATCH v2] bloat-o-meter: provide 3 different arguments for data, function and all

2017-09-27 Thread Maninder Singh
64 - -64 Total: Before=68, After=4, chg -94.12% Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- v1 -> v2 1) Incorporated missed changes between 4.1 and latest version. 2) Removed extra noise of

[PATCH v2] bloat-o-meter: provide 3 different arguments for data, function and all

2017-09-27 Thread Maninder Singh
64 - -64 Total: Before=68, After=4, chg -94.12% Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1 -> v2 1) Incorporated missed changes between 4.1 and latest version. 2) Removed extra noise of "#" after each section print. 3) Removed

[PATCH 1/1] bloat-o-meter: provide 3 different arguments for data, function and All

2017-09-25 Thread Maninder Singh
up/down: 0/-64 (-64) RO Data old new delta arr 64 - -64 Total: Before=68, After=4, chg -94.12% Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung

[PATCH 1/1] bloat-o-meter: provide 3 different arguments for data, function and All

2017-09-25 Thread Maninder Singh
up/down: 0/-64 (-64) RO Data old new delta arr 64 - -64 Total: Before=68, After=4, chg -94.12% Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh ---

[PATCH 1/1] pid: making some changes as per kernel coding guidlines

2017-07-25 Thread Maninder Singh
This patch do some minor changes to make code align to kernel coding guidlines, and make it little easy to find definations of these structs. Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- include/linux/pid.h | 9 +++--

[PATCH 1/1] pid: making some changes as per kernel coding guidlines

2017-07-25 Thread Maninder Singh
This patch do some minor changes to make code align to kernel coding guidlines, and make it little easy to find definations of these structs. Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- include/linux/pid.h | 9 +++-- 1 file changed, 3 insertions(+), 6 deletions(-) diff

[PATCH 1/1] ext4: correcting copy paste error.

2017-07-17 Thread Maninder Singh
Error reported by static tool for copy paste issue, fixing the same. Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- fs/ext4/extents.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/extents

[PATCH 1/1] ext4: correcting copy paste error.

2017-07-17 Thread Maninder Singh
Error reported by static tool for copy paste issue, fixing the same. Signed-off-by: Maninder Singh Signed-off-by: Vaneet Narang --- fs/ext4/extents.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/extents.c b/fs/ext4/extents.c index 2a97dff..5d337ca 100644 --- a/fs

[PATCH v2] module: check if memory leak by module.

2017-03-29 Thread Maninder Singh
] Allocating function kernel_init+0x1c/0x20 [test_module] Signed-off-by: Vaneet Narang <v.nar...@samsung.com> Signed-off-by: Maninder Singh <maninder...@samsung.com> --- v1->v2: made code generic rather than dependent on config. changed pr_alert to pr_err. include/linux/vmalloc.h

[PATCH v2] module: check if memory leak by module.

2017-03-29 Thread Maninder Singh
] Allocating function kernel_init+0x1c/0x20 [test_module] Signed-off-by: Vaneet Narang Signed-off-by: Maninder Singh --- v1->v2: made code generic rather than dependent on config. changed pr_alert to pr_err. include/linux/vmalloc.h | 2 ++ kernel/module.c |

[PATCH 1/1] module: check if memory leak by module.

2017-03-24 Thread Maninder Singh
101 [ 129.336376] Allocating function kernel_init+0x1c/0x20 [vmalloc] Signed-off-by: Maninder Singh <maninder...@samsung.com> Signed-off-by: Vaneet Narang <v.nar...@samsung.com> --- include/linux/vmalloc.h | 2 ++ kernel/module.c | 28 mm/K

  1   2   3   4   >