Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Jia-Ju Bai
On 2018/1/27 1:08, Al Viro wrote: On Fri, Jan 26, 2018 at 11:07:39AM -0500, David Miller wrote: This is found by a static analysis tool named DCNS written by myself. The trouble is, places like net/atm/raw.c:65: vcc->send = atm_send_aal0; net/atm/raw.c:74: vcc->send = vcc->dev->op

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Al Viro
On Fri, Jan 26, 2018 at 11:07:39AM -0500, David Miller wrote: > >> This is found by a static analysis tool named DCNS written by myself. > > > > The trouble is, places like > > net/atm/raw.c:65: vcc->send = atm_send_aal0; > > net/atm/raw.c:74: vcc->send = vcc->dev->ops->send; > > net/a

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Jia-Ju Bai
On 2018/1/27 0:07, David Miller wrote: From: Al Viro Date: Fri, 26 Jan 2018 12:05:22 + On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: After checking all possible call chains to fs_send() here, my tool finds that fs_send() is never called in atomic context. And this function

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread David Miller
From: Jia-Ju Bai Date: Fri, 26 Jan 2018 22:17:08 +0800 > > > On 2018/1/26 21:56, Jia-Ju Bai wrote: >> >> >> On 2018/1/26 20:05, Al Viro wrote: >>> On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: After checking all possible call chains to fs_send() here, my tool finds that

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread David Miller
From: Jia-Ju Bai Date: Fri, 26 Jan 2018 21:56:32 +0800 > My tool did not handle this situation of passing function pointer, and > I will improve the tool... Never automate these kinds of changes. Actually audit the change fully _yourself_ as a human after the tool indicates a possibility to you

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread David Miller
From: Al Viro Date: Fri, 26 Jan 2018 12:05:22 + > On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: >> After checking all possible call chains to fs_send() here, >> my tool finds that fs_send() is never called in atomic context. >> And this function is assigned to a function pointer

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Jia-Ju Bai
On 2018/1/26 21:56, Jia-Ju Bai wrote: On 2018/1/26 20:05, Al Viro wrote: On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: After checking all possible call chains to fs_send() here, my tool finds that fs_send() is never called in atomic context. And this function is assigned to a

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Jia-Ju Bai
On 2018/1/26 20:05, Al Viro wrote: On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: After checking all possible call chains to fs_send() here, my tool finds that fs_send() is never called in atomic context. And this function is assigned to a function pointer "dev->ops->send", which

Re: [PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-26 Thread Al Viro
On Fri, Jan 26, 2018 at 04:00:27PM +0800, Jia-Ju Bai wrote: > After checking all possible call chains to fs_send() here, > my tool finds that fs_send() is never called in atomic context. > And this function is assigned to a function pointer "dev->ops->send", > which is only called by vcc_sendmsg()

[PATCH] atm: firestream: Replace GFP_ATOMIC with GFP_KERNEL in fs_send

2018-01-25 Thread Jia-Ju Bai
After checking all possible call chains to fs_send() here, my tool finds that fs_send() is never called in atomic context. And this function is assigned to a function pointer "dev->ops->send", which is only called by vcc_sendmsg() (net/atm/common.c) through vcc->dev->ops->send(), and vcc_sendmsg()