Re: Re: [PATCH] [v2] usb: musb: Fix runtime PM imbalance on error

2020-05-21 Thread Greg Kroah-Hartman
On Fri, May 22, 2020 at 01:22:24PM +0800, dinghao@zju.edu.cn wrote: > Sorry, it's my carelessness. In v1 I added pm_runtime_put_autosuspend() > after copy_from_user() to fix this problem. Since copy_from_user() is > moved to the beginning now, we need not to add PM decrement. THat's fine,

Re: Re: [PATCH] [v2] usb: musb: Fix runtime PM imbalance on error

2020-05-21 Thread dinghao . liu
Sorry, it's my carelessness. In v1 I added pm_runtime_put_autosuspend() after copy_from_user() to fix this problem. Since copy_from_user() is moved to the beginning now, we need not to add PM decrement. Regards, Dinghao > On Fri, May 22, 2020 at 10:59:02AM +0800, Dinghao Liu wrote: > > When

Re: [PATCH] [v2] usb: musb: Fix runtime PM imbalance on error

2020-05-21 Thread Greg Kroah-Hartman
On Fri, May 22, 2020 at 10:59:02AM +0800, Dinghao Liu wrote: > When copy_from_user() returns an error code, there > is a runtime PM usage counter imbalance. > > Fix this by moving copy_from_user() to the beginning > of this function. > > Signed-off-by: Dinghao Liu > --- >

[PATCH] [v2] usb: musb: Fix runtime PM imbalance on error

2020-05-21 Thread Dinghao Liu
When copy_from_user() returns an error code, there is a runtime PM usage counter imbalance. Fix this by moving copy_from_user() to the beginning of this function. Signed-off-by: Dinghao Liu --- drivers/usb/musb/musb_debugfs.c | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-)