Re: [Qestion] Hit a WARN_ON_ONCE in try_to_unmap_one when runing syzkaller

2019-03-14 Thread zhong jiang
On 2019/3/14 14:27, Naoya Horiguchi wrote: > Hi, > > On Wed, Mar 13, 2019 at 12:03:20AM +0800, zhong jiang wrote: > ... >> Minchan has changed the conditon check from BUG_ON to WARN_ON_ONCE in >> try_to_unmap_one. >> However, It is still an abnormal condition wh

[Qestion] Hit a WARN_ON_ONCE in try_to_unmap_one when runing syzkaller

2019-03-12 Thread zhong jiang
. Because page is locked , Its page flags should not be changed except for PageSwapBacked. Thanks, zhong jiang [ 16.918386] random: sshd: uninitialized urandom read (32 bytes read) [ 17.159274] random: fast init done [ 18.025596] urandom_read: 1 callbacks suppressed [ 18.025610] random

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-07 Thread zhong jiang
On 2019/3/6 10:05, Andrea Arcangeli wrote: > Hello everyone, > > [ CC'ed Mike and Peter ] > > On Tue, Mar 05, 2019 at 02:42:00PM +0800, zhong jiang wrote: >> On 2019/3/5 14:26, Dmitry Vyukov wrote: >>> On Mon, Mar 4, 2019 at 4:32 PM zhong jiang wrote: >>>&

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-06 Thread zhong jiang
On 2019/3/7 2:29, Andrea Arcangeli wrote: > Hello Zhong, > > On Wed, Mar 06, 2019 at 09:07:00PM +0800, zhong jiang wrote: >> The patch use call_rcu to delay free the task_struct, but It is possible to >> free the task_struct >> ahead of get_mem_cgroup_from_mm. is it

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-06 Thread zhong jiang
On 2019/3/6 16:12, Peter Xu wrote: > On Wed, Mar 06, 2019 at 03:41:06PM +0800, zhong jiang wrote: >> On 2019/3/6 14:26, Mike Rapoport wrote: >>> Hi, >>> >>> On Wed, Mar 06, 2019 at 01:53:12PM +0800, zhong jiang wrote: >>>> On 2019/3/6 10:

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-05 Thread zhong jiang
On 2019/3/6 14:26, Mike Rapoport wrote: > Hi, > > On Wed, Mar 06, 2019 at 01:53:12PM +0800, zhong jiang wrote: >> On 2019/3/6 10:05, Andrea Arcangeli wrote: >>> Hello everyone, >>> >>> [ CC'ed Mike and Peter ] >>> >>> On Tue, Mar 05, 2019

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-05 Thread zhong jiang
On 2019/3/6 10:05, Andrea Arcangeli wrote: > Hello everyone, > > [ CC'ed Mike and Peter ] > > On Tue, Mar 05, 2019 at 02:42:00PM +0800, zhong jiang wrote: >> On 2019/3/5 14:26, Dmitry Vyukov wrote: >>> On Mon, Mar 4, 2019 at 4:32 PM zhong jiang wrote: >>>&

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-04 Thread zhong jiang
On 2019/3/5 14:26, Dmitry Vyukov wrote: > On Mon, Mar 4, 2019 at 4:32 PM zhong jiang wrote: >> On 2019/3/4 22:11, Dmitry Vyukov wrote: >>> On Mon, Mar 4, 2019 at 3:00 PM zhong jiang wrote: >>>> On 2019/3/4 15:40, Dmitry Vyukov wrote: >>>>> On S

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-04 Thread zhong jiang
On 2019/3/5 5:51, Matthew Wilcox wrote: > On Mon, Mar 04, 2019 at 12:19:32AM +0800, zhong jiang wrote: >> I also hit the following issue. but it fails to reproduce the issue by the >> log. >> >> it seems to the case that we access the mm->owner and deference

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-04 Thread zhong jiang
On 2019/3/4 22:11, Dmitry Vyukov wrote: > On Mon, Mar 4, 2019 at 3:00 PM zhong jiang wrote: >> On 2019/3/4 15:40, Dmitry Vyukov wrote: >>> On Sun, Mar 3, 2019 at 5:19 PM zhong jiang wrote: >>>> Hi, guys >>>> >>>> I also hit th

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-04 Thread zhong jiang
On 2019/3/4 15:40, Dmitry Vyukov wrote: > On Sun, Mar 3, 2019 at 5:19 PM zhong jiang wrote: >> Hi, guys >> >> I also hit the following issue. but it fails to reproduce the issue by the >> log. >> >> it seems to the case that we access the mm->owner a

Re: KASAN: use-after-free Read in get_mem_cgroup_from_mm

2019-03-03 Thread zhong jiang
Thanks, zhong jiang On 2018/12/4 23:43, syzbot wrote: > syzbot has found a reproducer for the following crash on: > > HEAD commit:0072a0c14d5b Merge tag 'media/v4.20-4' of git://git.kernel.. > git tree: upstream > console output: https://syzkaller.appspot.com/x/log.txt?x=11

Re: [PATCH] mm: hwpoison: fix thp split handing in soft_offline_in_use_page()

2019-02-28 Thread zhong jiang
On 2019/3/1 15:29, Naoya Horiguchi wrote: > On Tue, Feb 26, 2019 at 10:34:32PM +0800, zhong jiang wrote: >> On 2019/2/26 21:51, Kirill A. Shutemov wrote: >>> On Tue, Feb 26, 2019 at 07:18:00PM +0800, zhong jiang wrote: >>>> From: zhongjiang >>>> >>

Re: [PATCH] mm: hwpoison: fix thp split handing in soft_offline_in_use_page()

2019-02-26 Thread zhong jiang
On 2019/2/26 21:51, Kirill A. Shutemov wrote: > On Tue, Feb 26, 2019 at 07:18:00PM +0800, zhong jiang wrote: >> From: zhongjiang >> >> When soft_offline_in_use_page() runs on a thp tail page after pmd is plit, > s/plit/split/ > >> we trigger the following VM_BU

[PATCH] mm: hwpoison: fix thp split handing in soft_offline_in_use_page()

2019-02-26 Thread zhong jiang
From: zhongjiang When soft_offline_in_use_page() runs on a thp tail page after pmd is plit, we trigger the following VM_BUG_ON_PAGE(): Memory failure: 0x3755ff: non anonymous thp __get_any_page: 0x3755ff: unknown zero refcount page type 2f8000 Soft offlining pfn 0x34d805 at process

Re: [PATCH] mm: use this_cpu_cmpxchg_double in put_cpu_partial

2018-11-19 Thread zhong jiang
to call for ideas. Have you hit the really issue or just review the code ? I did hit the issue and fixed in the upstream patch unpredictably by the following patch. e5d9998f3e09 ("slub: make ->cpu_partial unsigned int") Thanks, zhong jiang > Signed-off-by: Wengang Wang > --- >

Re: [PATCH] mm: use this_cpu_cmpxchg_double in put_cpu_partial

2018-11-19 Thread zhong jiang
to call for ideas. Have you hit the really issue or just review the code ? I did hit the issue and fixed in the upstream patch unpredictably by the following patch. e5d9998f3e09 ("slub: make ->cpu_partial unsigned int") Thanks, zhong jiang > Signed-off-by: Wengang Wang > --- >

Re: [Question] There is a thp count left when the process exits

2018-11-08 Thread zhong jiang
+LKML I can not find the possibility when I check the code. because the mmap_sem and spin_lock will protect the concurrence. I will be appreciated if anyone has some clue. Thanks, zhong jiang On 2018/11/8 23:01, zhong jiang wrote: > Hi, > > Recently, I hit the following issue

Re: [Question] There is a thp count left when the process exits

2018-11-08 Thread zhong jiang
+LKML I can not find the possibility when I check the code. because the mmap_sem and spin_lock will protect the concurrence. I will be appreciated if anyone has some clue. Thanks, zhong jiang On 2018/11/8 23:01, zhong jiang wrote: > Hi, > > Recently, I hit the following issue

[PATCH] pch_uart: remove set but not used variable 'tx_empty'

2018-10-23 Thread zhong jiang
tx_empty is not used after setting its value. It is safe to remove the unused variable. Signed-off-by: zhong jiang --- drivers/tty/serial/pch_uart.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/tty/serial/pch_uart.c b/drivers/tty/serial/pch_uart.c index cb85002..9ed121f 100644

[PATCH] pch_uart: remove set but not used variable 'tx_empty'

2018-10-23 Thread zhong jiang
tx_empty is not used after setting its value. It is safe to remove the unused variable. Signed-off-by: zhong jiang --- drivers/tty/serial/pch_uart.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/tty/serial/pch_uart.c b/drivers/tty/serial/pch_uart.c index cb85002..9ed121f 100644

[PATCH] cdrom: remove set but not used variable 'tocuse'

2018-10-23 Thread zhong jiang
tocuse is not used after setting its value. It is safe to remove the unused variable. Signed-off-by: zhong jiang --- drivers/cdrom/gdrom.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/cdrom/gdrom.c b/drivers/cdrom/gdrom.c index 757e85b..b45c543 100644

[PATCH] cdrom: remove set but not used variable 'tocuse'

2018-10-23 Thread zhong jiang
tocuse is not used after setting its value. It is safe to remove the unused variable. Signed-off-by: zhong jiang --- drivers/cdrom/gdrom.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/cdrom/gdrom.c b/drivers/cdrom/gdrom.c index 757e85b..b45c543 100644

[RESEND PATCHv2] misc: cxl: Fix possible null pointer dereference

2018-10-03 Thread zhong jiang
It is not safe to dereference an object before a null test. It is not needed and just remove them. Ftrace can be used instead. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/cxl/guest.c b/drivers/misc/cxl/guest.c index

[RESEND PATCHv2] misc: cxl: Fix possible null pointer dereference

2018-10-03 Thread zhong jiang
It is not safe to dereference an object before a null test. It is not needed and just remove them. Ftrace can be used instead. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/cxl/guest.c b/drivers/misc/cxl/guest.c index

Re: [PATCHv2] misc: cxl: delete possible null pointer dereference

2018-10-03 Thread zhong jiang
On 2018/10/4 12:38, Greg KH wrote: > On Thu, Oct 04, 2018 at 10:56:48AM +0800, zhong jiang wrote: >> It is safe to dereference an object below a NULL test. For the sake >> of debugging. Just delete the call of possible null pointer dereference. >> >> Signed-off-by: zhon

Re: [PATCHv2] misc: cxl: delete possible null pointer dereference

2018-10-03 Thread zhong jiang
On 2018/10/4 12:38, Greg KH wrote: > On Thu, Oct 04, 2018 at 10:56:48AM +0800, zhong jiang wrote: >> It is safe to dereference an object below a NULL test. For the sake >> of debugging. Just delete the call of possible null pointer dereference. >> >> Signed-off-by: zhon

[PATCHv2] misc: cxl: delete possible null pointer dereference

2018-10-03 Thread zhong jiang
It is safe to dereference an object below a NULL test. For the sake of debugging. Just delete the call of possible null pointer dereference. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/misc/cxl/guest.c b

[PATCHv2] misc: cxl: delete possible null pointer dereference

2018-10-03 Thread zhong jiang
It is safe to dereference an object below a NULL test. For the sake of debugging. Just delete the call of possible null pointer dereference. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/misc/cxl/guest.c b

Re: [PATCH] misc: cxl: Move a deference below a NULL test

2018-10-03 Thread zhong jiang
On 2018/10/3 6:55, Greg KH wrote: > On Wed, Sep 26, 2018 at 07:41:12PM +0800, zhong jiang wrote: >> It is safe to move a deference below a NULL test. >> >> Signed-off-by: zhong jiang >> Acked-by: Andrew Donnellan >> --- >> drivers/misc/cxl/guest.c | 4 ++--

Re: [PATCH] misc: cxl: Move a deference below a NULL test

2018-10-03 Thread zhong jiang
On 2018/10/3 6:55, Greg KH wrote: > On Wed, Sep 26, 2018 at 07:41:12PM +0800, zhong jiang wrote: >> It is safe to move a deference below a NULL test. >> >> Signed-off-by: zhong jiang >> Acked-by: Andrew Donnellan >> --- >> drivers/misc/cxl/guest.c | 4 ++--

[STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-30 Thread zhong jiang
Cc: # 4.4.x Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: zhong jiang --- include/linux/slub_def.h | 3 ++- mm/slub.c| 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h in

[STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-30 Thread zhong jiang
Cc: # 4.4.x Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: zhong jiang --- include/linux/slub_def.h | 3 ++- mm/slub.c| 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h in

[PATCH v2] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
Fix the following compile warning: sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined but not used [-Wunused-function] sound/soc/codecs/wm8731.c:600:12: warning: 'wm8731_hw_init' defined but not used [-Wunused-function] Signed-off-by: zhong jiang --- v1->v2: - M

[PATCH v2] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
Fix the following compile warning: sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined but not used [-Wunused-function] sound/soc/codecs/wm8731.c:600:12: warning: 'wm8731_hw_init' defined but not used [-Wunused-function] Signed-off-by: zhong jiang --- v1->v2: - M

Re: [PATCH] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
On 2018/9/30 10:17, Joe Perches wrote: > On Sun, 2018-09-30 at 09:45 +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined >> but not used [-Wunused-function] >> sound/so

Re: [PATCH] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
On 2018/9/30 10:17, Joe Perches wrote: > On Sun, 2018-09-30 at 09:45 +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined >> but not used [-Wunused-function] >> sound/so

[PATCH] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
Fix the following compile warning: sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined but not used [-Wunused-function] sound/soc/codecs/wm8731.c:600:12: warning: 'wm8731_hw_init' defined but not used [-Wunused-function] Signed-off-by: zhong jiang --- sound/soc

[PATCH] ASoC: wm8731: Fix a unused function gcc warning

2018-09-29 Thread zhong jiang
Fix the following compile warning: sound/soc/codecs/wm8731.c:575:12: warning: 'wm8731_request_supplies' defined but not used [-Wunused-function] sound/soc/codecs/wm8731.c:600:12: warning: 'wm8731_hw_init' defined but not used [-Wunused-function] Signed-off-by: zhong jiang --- sound/soc

[PATCH] fs/dax.c: Use vmf_error() helper

2018-09-28 Thread zhong jiang
These codes can be replaced with new inline vmf_error(). Signed-off-by: zhong jiang --- fs/dax.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/fs/dax.c b/fs/dax.c index b68ce48..e732f70 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -1311,9 +1311,8 @@ static vm_fault_t

[PATCH] fs/dax.c: Use vmf_error() helper

2018-09-28 Thread zhong jiang
These codes can be replaced with new inline vmf_error(). Signed-off-by: zhong jiang --- fs/dax.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/fs/dax.c b/fs/dax.c index b68ce48..e732f70 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -1311,9 +1311,8 @@ static vm_fault_t

Re: [STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-28 Thread zhong jiang
On 2018/9/27 23:46, Greg KH wrote: > On Thu, Sep 27, 2018 at 10:43:40PM +0800, zhong jiang wrote: >> From: Alexey Dobriyan >> >> /* >> * cpu_partial determined the maximum number of objects >> * kept in the per cpu partial lists of a proc

Re: [STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-28 Thread zhong jiang
On 2018/9/27 23:46, Greg KH wrote: > On Thu, Sep 27, 2018 at 10:43:40PM +0800, zhong jiang wrote: >> From: Alexey Dobriyan >> >> /* >> * cpu_partial determined the maximum number of objects >> * kept in the per cpu partial lists of a proc

Re: [PATCH] ieee802154: remove a redundant local variable 'i'

2018-09-28 Thread zhong jiang
On 2018/9/27 22:47, Stefan Schmidt wrote: > Hello. > > On 19/09/2018 16:41, zhong jiang wrote: >> The local variable 'i' is never used after being assigned. >> hence it should be redundant adn can be removed. >> >> Signed-off-by: zhong jiang >> --- >>

Re: [PATCH] ieee802154: remove a redundant local variable 'i'

2018-09-28 Thread zhong jiang
On 2018/9/27 22:47, Stefan Schmidt wrote: > Hello. > > On 19/09/2018 16:41, zhong jiang wrote: >> The local variable 'i' is never used after being assigned. >> hence it should be redundant adn can be removed. >> >> Signed-off-by: zhong jiang >> --- >>

[STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-27 Thread zhong jiang
tch is a effective bugfix. It should go into stable. Signed-off-by: Alexey Dobriyan Acked-by: Christoph Lameter Cc: Pekka Enberg Cc: David Rientjes Cc: Joonsoo Kim Cc: sta...@vger.kernel.org Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: zhong jiang --- incl

[STABLE PATCH] slub: make ->cpu_partial unsigned int

2018-09-27 Thread zhong jiang
tch is a effective bugfix. It should go into stable. Signed-off-by: Alexey Dobriyan Acked-by: Christoph Lameter Cc: Pekka Enberg Cc: David Rientjes Cc: Joonsoo Kim Cc: sta...@vger.kernel.org Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds Signed-off-by: zhong jiang --- incl

[RESEND PATCH v2] misc: card_utils: remove duplicated include file

2018-09-27 Thread zhong jiang
delay.h and dma-mapping.h have duplicated include. hence just remove redundant file. Signed-off-by: zhong jiang --- v1->v2: - modify the subject drivers/misc/genwqe/card_utils.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_utils.c b/drivers/misc/gen

[RESEND PATCH v2] misc: card_utils: remove duplicated include file

2018-09-27 Thread zhong jiang
delay.h and dma-mapping.h have duplicated include. hence just remove redundant file. Signed-off-by: zhong jiang --- v1->v2: - modify the subject drivers/misc/genwqe/card_utils.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_utils.c b/drivers/misc/gen

Re: [PATCHv2] misc: genwqe: remove duplicated include and order header files alphabetically in card_utils.c

2018-09-26 Thread zhong jiang
On 2018/9/26 11:05, zhong jiang wrote: > dma-mapping.h and delay.h have included twice. It is unnecessary. Meanwhile, > Arrange header files in alphabetical sequence to improve readability. > > Signed-off-by: zhong jiang > --- > drivers/misc/genwqe/card_utils.c | 22 +

Re: [PATCHv2] misc: genwqe: remove duplicated include and order header files alphabetically in card_utils.c

2018-09-26 Thread zhong jiang
On 2018/9/26 11:05, zhong jiang wrote: > dma-mapping.h and delay.h have included twice. It is unnecessary. Meanwhile, > Arrange header files in alphabetical sequence to improve readability. > > Signed-off-by: zhong jiang > --- > drivers/misc/genwqe/card_utils.c | 22 +

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
On 2018/9/26 22:22, Michal Suchánek wrote: > On Wed, 26 Sep 2018 19:46:08 +0800 > zhong jiang wrote: > >> It is safe to move dereference below a NULL test. >> >> Signed-off-by: zhong jiang >> --- >> arch/powerpc/kernel/cacheinfo.c | 5 ++--- >>

Re: [PATCH] powerpc: Move a dereference below a NULL test

2018-09-26 Thread zhong jiang
On 2018/9/26 22:22, Michal Suchánek wrote: > On Wed, 26 Sep 2018 19:46:08 +0800 > zhong jiang wrote: > >> It is safe to move dereference below a NULL test. >> >> Signed-off-by: zhong jiang >> --- >> arch/powerpc/kernel/cacheinfo.c | 5 ++--- >>

Re: [PATCH v2] NFC: st-nci: remove a redundant null pointer check

2018-09-26 Thread zhong jiang
On 2018/9/26 22:03, Andy Shevchenko wrote: > On Wed, Sep 26, 2018 at 08:30:50PM +0800, zhong jiang wrote: >> The dev is impossible is NULL. hence the check is redundant. We >> never will hit it. >> > Reviewed-by: Andy Shevchenko Thanks. >> Signed-off-by:

Re: [PATCH v2] NFC: st-nci: remove a redundant null pointer check

2018-09-26 Thread zhong jiang
On 2018/9/26 22:03, Andy Shevchenko wrote: > On Wed, Sep 26, 2018 at 08:30:50PM +0800, zhong jiang wrote: >> The dev is impossible is NULL. hence the check is redundant. We >> never will hit it. >> > Reviewed-by: Andy Shevchenko Thanks. >> Signed-off-by:

[PATCH] misc: cxl: Move a deference below a NULL test

2018-09-26 Thread zhong jiang
It is safe to move a deference below a NULL test. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/misc/cxl/guest.c b/drivers/misc/cxl/guest.c index 3bc0c15..559e835 100644 --- a/drivers/misc/cxl/guest.c

[PATCH] misc: cxl: Move a deference below a NULL test

2018-09-26 Thread zhong jiang
It is safe to move a deference below a NULL test. Signed-off-by: zhong jiang --- drivers/misc/cxl/guest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/misc/cxl/guest.c b/drivers/misc/cxl/guest.c index 3bc0c15..559e835 100644 --- a/drivers/misc/cxl/guest.c

[PATCHv2] misc: genwqe: remove duplicated include and order header files alphabetically in card_utils.c

2018-09-25 Thread zhong jiang
dma-mapping.h and delay.h have included twice. It is unnecessary. Meanwhile, Arrange header files in alphabetical sequence to improve readability. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 22 ++ 1 file changed, 10 insertions(+), 12 deletions(-) diff

[PATCHv2] misc: genwqe: remove duplicated include and order header files alphabetically in card_utils.c

2018-09-25 Thread zhong jiang
dma-mapping.h and delay.h have included twice. It is unnecessary. Meanwhile, Arrange header files in alphabetical sequence to improve readability. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 22 ++ 1 file changed, 10 insertions(+), 12 deletions(-) diff

Re: [PATCH] media: card_utils: remove duplicated include file

2018-09-25 Thread zhong jiang
On 2018/9/26 2:20, Greg KH wrote: > On Thu, Sep 20, 2018 at 01:04:02PM +0800, zhong jiang wrote: >> delay.h and dma-mapping.h have duplicated include. hence just remove >> redundant file. >> >> Signed-off-by: zhong jiang >> --- >> drivers/misc/genwqe/ca

Re: [PATCH] media: card_utils: remove duplicated include file

2018-09-25 Thread zhong jiang
On 2018/9/26 2:20, Greg KH wrote: > On Thu, Sep 20, 2018 at 01:04:02PM +0800, zhong jiang wrote: >> delay.h and dma-mapping.h have duplicated include. hence just remove >> redundant file. >> >> Signed-off-by: zhong jiang >> --- >> drivers/misc/genwqe/ca

Re: [PATCH] soc: qcom: qdsp6: remove duplicated include from q6adm.c

2018-09-25 Thread zhong jiang
On 2018/9/22 0:22, Mark Brown wrote: > On Fri, Sep 21, 2018 at 06:24:58PM +0800, zhong jiang wrote: >> We include wait.h twice in q6adm.c. it is unnecessary. hence remove >> it. Further, order the include files as alphabet. > Please use subject lines matching the style

Re: [PATCH] soc: qcom: qdsp6: remove duplicated include from q6adm.c

2018-09-25 Thread zhong jiang
On 2018/9/22 0:22, Mark Brown wrote: > On Fri, Sep 21, 2018 at 06:24:58PM +0800, zhong jiang wrote: >> We include wait.h twice in q6adm.c. it is unnecessary. hence remove >> it. Further, order the include files as alphabet. > Please use subject lines matching the style

[tip:x86/pti] x86/CPU: Fix unused variable warning when !CONFIG_IA32_EMULATION

2018-09-22 Thread tip-bot for zhong jiang
Commit-ID: 8e6b65a1b6cd1711d3acd2aa5c60d38c3e15dabb Gitweb: https://git.kernel.org/tip/8e6b65a1b6cd1711d3acd2aa5c60d38c3e15dabb Author: zhong jiang AuthorDate: Thu, 13 Sep 2018 10:49:45 +0800 Committer: Borislav Petkov CommitDate: Sat, 15 Sep 2018 14:57:05 +0200 x86/CPU: Fix unused

[tip:x86/pti] x86/CPU: Fix unused variable warning when !CONFIG_IA32_EMULATION

2018-09-22 Thread tip-bot for zhong jiang
Commit-ID: 8e6b65a1b6cd1711d3acd2aa5c60d38c3e15dabb Gitweb: https://git.kernel.org/tip/8e6b65a1b6cd1711d3acd2aa5c60d38c3e15dabb Author: zhong jiang AuthorDate: Thu, 13 Sep 2018 10:49:45 +0800 Committer: Borislav Petkov CommitDate: Sat, 15 Sep 2018 14:57:05 +0200 x86/CPU: Fix unused

Re: [PATCH] drm: sun4i: Fix a uninitialized variable warning.

2018-09-21 Thread zhong jiang
On 2018/9/21 22:26, Maxime Ripard wrote: > On Wed, Sep 19, 2018 at 05:01:32PM +0800, zhong jiang wrote: >> On 2018/9/19 16:47, Maxime Ripard wrote: >>> On Tue, Sep 18, 2018 at 03:25:20PM +0800, zhong jiang wrote: >>>> Fix the following compile warning: >>>&g

Re: [PATCH] drm: sun4i: Fix a uninitialized variable warning.

2018-09-21 Thread zhong jiang
On 2018/9/21 22:26, Maxime Ripard wrote: > On Wed, Sep 19, 2018 at 05:01:32PM +0800, zhong jiang wrote: >> On 2018/9/19 16:47, Maxime Ripard wrote: >>> On Tue, Sep 18, 2018 at 03:25:20PM +0800, zhong jiang wrote: >>>> Fix the following compile warning: >>>&g

[PATCH] PM / devfreq: remove redundant null pointer check before kfree

2018-09-21 Thread zhong jiang
kfree has taken the null pointer into account. hence it is safe to remove the redundant null pointer check before kfree. Signed-off-by: zhong jiang --- drivers/devfreq/devfreq.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq

[PATCH] PM / devfreq: remove redundant null pointer check before kfree

2018-09-21 Thread zhong jiang
kfree has taken the null pointer into account. hence it is safe to remove the redundant null pointer check before kfree. Signed-off-by: zhong jiang --- drivers/devfreq/devfreq.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/devfreq/devfreq.c b/drivers/devfreq

[PATCH] drivers/firmware: Should be a struct size instead of a pointer.

2018-09-21 Thread zhong jiang
kcalloc should be sizeof(*cpu_groups) instead of sizeof(cpu_groups). Signed-off-by: zhong jiang --- drivers/firmware/psci_checker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/firmware/psci_checker.c b/drivers/firmware/psci_checker.c index 3469436..26afabc 100644

[PATCH] drivers/firmware: Should be a struct size instead of a pointer.

2018-09-21 Thread zhong jiang
kcalloc should be sizeof(*cpu_groups) instead of sizeof(cpu_groups). Signed-off-by: zhong jiang --- drivers/firmware/psci_checker.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/firmware/psci_checker.c b/drivers/firmware/psci_checker.c index 3469436..26afabc 100644

[PATCH] soc: qcom: qdsp6: remove duplicated include from q6adm.c

2018-09-21 Thread zhong jiang
We include wait.h twice in q6adm.c. it is unnecessary. hence remove it. Further, order the include files as alphabet. Signed-off-by: zhong jiang --- sound/soc/qcom/qdsp6/q6adm.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/sound/soc/qcom/qdsp6/q6adm.c b

[PATCH] soc: qcom: qdsp6: remove duplicated include from q6adm.c

2018-09-21 Thread zhong jiang
We include wait.h twice in q6adm.c. it is unnecessary. hence remove it. Further, order the include files as alphabet. Signed-off-by: zhong jiang --- sound/soc/qcom/qdsp6/q6adm.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/sound/soc/qcom/qdsp6/q6adm.c b

[RESEND PATCH] error-injection: remove meaningless null pointer check before debugfs_remove_recursive

2018-09-20 Thread zhong jiang
debugfs_remove_recursive has taken the null pointer into account. just remove the null check before debugfs_remove_recursive. Acked-by: Masami Hiramatsu Signed-off-by: zhong jiang --- kernel/fail_function.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel

[RESEND PATCH] error-injection: remove meaningless null pointer check before debugfs_remove_recursive

2018-09-20 Thread zhong jiang
debugfs_remove_recursive has taken the null pointer into account. just remove the null check before debugfs_remove_recursive. Acked-by: Masami Hiramatsu Signed-off-by: zhong jiang --- kernel/fail_function.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel

Re: [PATCH v2] HID: logitech: fix a used uninitialized GCC warning

2018-09-20 Thread zhong jiang
Hi Jiri Can you pick up the patch? Thanks zhong jiang On 2018/9/13 15:41, zhong jiang wrote: > Fix the following compile warning: > > drivers/hid/hid-logitech-hidpp.c: In function 'hi_res_scroll_enable': > drivers/hid/hid-logitech-hidpp.c:2714:54: warning: 'multiplier'

Re: [PATCH v2] HID: logitech: fix a used uninitialized GCC warning

2018-09-20 Thread zhong jiang
Hi Jiri Can you pick up the patch? Thanks zhong jiang On 2018/9/13 15:41, zhong jiang wrote: > Fix the following compile warning: > > drivers/hid/hid-logitech-hidpp.c: In function 'hi_res_scroll_enable': > drivers/hid/hid-logitech-hidpp.c:2714:54: warning: 'multiplier'

[PATCH] RDMA/cxgb4: remove redundant null pointer check before kfree_skb

2018-09-20 Thread zhong jiang
kfree_skb has taken the null pointer into account. hence it is safe to remove the redundant null pointer check before kfree_skb. Signed-off-by: zhong jiang --- drivers/infiniband/hw/cxgb4/cm.c | 3 +-- drivers/infiniband/hw/cxgb4/qp.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions

[PATCH] RDMA/cxgb4: remove redundant null pointer check before kfree_skb

2018-09-20 Thread zhong jiang
kfree_skb has taken the null pointer into account. hence it is safe to remove the redundant null pointer check before kfree_skb. Signed-off-by: zhong jiang --- drivers/infiniband/hw/cxgb4/cm.c | 3 +-- drivers/infiniband/hw/cxgb4/qp.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions

[PATCH] misc: genwqe: remove duplicated include file

2018-09-19 Thread zhong jiang
module.h has duplicated include. hence just remove redundant include file. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_base.c | 1 - drivers/misc/genwqe/card_ddcb.c | 1 - 2 files changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_base.c b/drivers/misc/genwqe/card_base.c

[PATCH] misc: genwqe: remove duplicated include file

2018-09-19 Thread zhong jiang
module.h has duplicated include. hence just remove redundant include file. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_base.c | 1 - drivers/misc/genwqe/card_ddcb.c | 1 - 2 files changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_base.c b/drivers/misc/genwqe/card_base.c

[PATCH] media: card_utils: remove duplicated include file

2018-09-19 Thread zhong jiang
delay.h and dma-mapping.h have duplicated include. hence just remove redundant file. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_utils.c b/drivers/misc/genwqe/card_utils.c index f0961ec..3fcb9a2

[PATCH] media: card_utils: remove duplicated include file

2018-09-19 Thread zhong jiang
delay.h and dma-mapping.h have duplicated include. hence just remove redundant file. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/misc/genwqe/card_utils.c b/drivers/misc/genwqe/card_utils.c index f0961ec..3fcb9a2

[PATCH] misc: genwqe: should return proper error value.

2018-09-19 Thread zhong jiang
The function should return -EFAULT when copy_from_user fails. Even though the caller does not distinguish them. but we should keep backward compatibility. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff

[PATCH] misc: genwqe: should return proper error value.

2018-09-19 Thread zhong jiang
The function should return -EFAULT when copy_from_user fails. Even though the caller does not distinguish them. but we should keep backward compatibility. Signed-off-by: zhong jiang --- drivers/misc/genwqe/card_utils.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff

Re: [PATCH] net: iucv: Use FIELD_SIZEOF directly instead of reimplementing its function

2018-09-19 Thread zhong jiang
On 2018/9/19 17:52, zhong jiang wrote: > FIELD_SIZEOF is defined as a macro to calculate the specified vaule. > Therefore, > We prefer to use the macro rather than calculating its vaule. s/vaule/value . will resend . Thanks, zhong jiang > Signed-off-by: zhong jiang >

Re: [PATCH] net: iucv: Use FIELD_SIZEOF directly instead of reimplementing its function

2018-09-19 Thread zhong jiang
On 2018/9/19 17:52, zhong jiang wrote: > FIELD_SIZEOF is defined as a macro to calculate the specified vaule. > Therefore, > We prefer to use the macro rather than calculating its vaule. s/vaule/value . will resend . Thanks, zhong jiang > Signed-off-by: zhong jiang >

Re: [PATCH] drm: sun4i: Fix a uninitialized variable warning.

2018-09-19 Thread zhong jiang
On 2018/9/19 16:47, Maxime Ripard wrote: > On Tue, Sep 18, 2018 at 03:25:20PM +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> drivers/gpu/drm/sun4i/sun4i_tcon.c:1088: warning: 'has_lvds_alt' may be used >> uninitialized in this function [-Wm

Re: [PATCH] drm: sun4i: Fix a uninitialized variable warning.

2018-09-19 Thread zhong jiang
On 2018/9/19 16:47, Maxime Ripard wrote: > On Tue, Sep 18, 2018 at 03:25:20PM +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> drivers/gpu/drm/sun4i/sun4i_tcon.c:1088: warning: 'has_lvds_alt' may be used >> uninitialized in this function [-Wm

[PATCH] soc: qcom: cmd-db: Fix some uninitialized warning.

2018-09-18 Thread zhong jiang
zed in this function [-Wmaybe-uninitialized] return ret < 0 ? 0 : le16_to_cpu(ent.len); drivers/soc/qcom/cmd-db.c:269:24: warning: ‘ent.addr’ may be used uninitialized in this function [-Wmaybe-uninitialized] addr = le32_to_cpu(ent.addr); Signed-off-by: zhong jiang --- drivers/soc/qcom/cmd-db

[PATCH] soc: qcom: cmd-db: Fix some uninitialized warning.

2018-09-18 Thread zhong jiang
zed in this function [-Wmaybe-uninitialized] return ret < 0 ? 0 : le16_to_cpu(ent.len); drivers/soc/qcom/cmd-db.c:269:24: warning: ‘ent.addr’ may be used uninitialized in this function [-Wmaybe-uninitialized] addr = le32_to_cpu(ent.addr); Signed-off-by: zhong jiang --- drivers/soc/qcom/cmd-db

[PATCH] sched: psi: Fix a GCC uninitialized warning

2018-09-18 Thread zhong jiang
I find the following warning when compiling the kernel. kernel/sched/psi.c:639:13: warning: 'rq' may be used uninitialized in this function [-Wmaybe-uninitialized] struct rq *rq; Signed-off-by: zhong jiang --- kernel/sched/psi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

[PATCH] sched: psi: Fix a GCC uninitialized warning

2018-09-18 Thread zhong jiang
I find the following warning when compiling the kernel. kernel/sched/psi.c:639:13: warning: 'rq' may be used uninitialized in this function [-Wmaybe-uninitialized] struct rq *rq; Signed-off-by: zhong jiang --- kernel/sched/psi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [PATCH] ASoC: qcom: Fix a uninitialized warning.

2018-09-18 Thread zhong jiang
On 2018/9/19 1:17, Andy Gross wrote: > On Tue, Sep 18, 2018 at 01:06:48PM +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> drivers/soc/qcom/cmd-db.c:194:38: warning: 'ent.addr' may be used >> uninitialized in this function [-Wmaybe-uninitializ

Re: [PATCH] ASoC: qcom: Fix a uninitialized warning.

2018-09-18 Thread zhong jiang
On 2018/9/19 1:17, Andy Gross wrote: > On Tue, Sep 18, 2018 at 01:06:48PM +0800, zhong jiang wrote: >> Fix the following compile warning: >> >> drivers/soc/qcom/cmd-db.c:194:38: warning: 'ent.addr' may be used >> uninitialized in this function [-Wmaybe-uninitializ

[PATCH] media: usb: Use kmemdup instead of duplicating its function.

2018-09-18 Thread zhong jiang
kmemdup has implemented the function that kmalloc() + memcpy(). We prefer to kmemdup rather than code opened implementation. Signed-off-by: zhong jiang --- drivers/media/usb/dvb-usb-v2/gl861.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/media/usb/dvb-usb-v2

[PATCH] media: usb: Use kmemdup instead of duplicating its function.

2018-09-18 Thread zhong jiang
kmemdup has implemented the function that kmalloc() + memcpy(). We prefer to kmemdup rather than code opened implementation. Signed-off-by: zhong jiang --- drivers/media/usb/dvb-usb-v2/gl861.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/media/usb/dvb-usb-v2

Re: [PATCH v2] scsi: Use vmemdup_user to replace the open code

2018-09-18 Thread zhong jiang
On 2018/9/18 23:10, Greg KH wrote: > On Tue, Sep 18, 2018 at 11:00:37PM +0800, zhong jiang wrote: >> Hi, Greg >> >> Can you pick up the patch? > Nope, sorry, as before, work with the maintainers please. Thank you for your reply timely .:-) Sincerely, zhong jiang > greg k-h > > . >

Re: [PATCH v2] scsi: Use vmemdup_user to replace the open code

2018-09-18 Thread zhong jiang
On 2018/9/18 23:10, Greg KH wrote: > On Tue, Sep 18, 2018 at 11:00:37PM +0800, zhong jiang wrote: >> Hi, Greg >> >> Can you pick up the patch? > Nope, sorry, as before, work with the maintainers please. Thank you for your reply timely .:-) Sincerely, zhong jiang > greg k-h > > . >

Re: [PATCH v2] scsi: Use vmemdup_user to replace the open code

2018-09-18 Thread zhong jiang
Hi, Greg Can you pick up the patch? Thanks, zhong jiang On 2018/8/23 19:38, zhong jiang wrote: > On 2018/8/13 22:20, don.br...@microchip.com wrote: >>> -Original Message- >>> From: zhong jiang [mailto:zhongji...@huawei.com] >>> Sent: Monday, August 1

<    1   2   3   4   5   6   7   8   >