[0/3] usb: gadget: f_hid: fix f_hidg lifetime vs cdev

Message ID 20221122123523.3068034-1-john@metanate.com
Headers
Series usb: gadget: f_hid: fix f_hidg lifetime vs cdev |

Message

John Keeping Nov. 22, 2022, 12:35 p.m. UTC
  This series arises from the recent thread [1] on lifetime issues.

The main point is the first patch, with the second being an unrelated
fix for an issue spotted while working on this.  Both of these have
Fixes: tags for backporting to stable.

The final patch tidies up some error handling to hopefully avoid patch 2
issues in the future.

[1] https://lore.kernel.org/r/20221117120813.1257583-1-lee@kernel.org

John Keeping (3):
  usb: gadget: f_hid: fix f_hidg lifetime vs cdev
  usb: gadget: f_hid: fix refcount leak on error path
  usb: gadget: f_hid: tidy error handling in hidg_alloc

 drivers/usb/gadget/function/f_hid.c | 60 ++++++++++++++++-------------
 1 file changed, 33 insertions(+), 27 deletions(-)
  

Comments

Lee Jones Nov. 22, 2022, 6:18 p.m. UTC | #1
On Tue, 22 Nov 2022, John Keeping wrote:

> This series arises from the recent thread [1] on lifetime issues.
> 
> The main point is the first patch, with the second being an unrelated
> fix for an issue spotted while working on this.  Both of these have
> Fixes: tags for backporting to stable.
> 
> The final patch tidies up some error handling to hopefully avoid patch 2
> issues in the future.
> 
> [1] https://lore.kernel.org/r/20221117120813.1257583-1-lee@kernel.org
> 
> John Keeping (3):
>   usb: gadget: f_hid: fix f_hidg lifetime vs cdev
>   usb: gadget: f_hid: fix refcount leak on error path
>   usb: gadget: f_hid: tidy error handling in hidg_alloc
> 
>  drivers/usb/gadget/function/f_hid.c | 60 ++++++++++++++++-------------
>  1 file changed, 33 insertions(+), 27 deletions(-)

For the set:

Reviewed-by: Lee Jones <lee@kernel.org>
Tested-by: Lee Jones <lee@kernel.org>
  
Lee Jones Nov. 28, 2022, 2:04 p.m. UTC | #2
On Tue, 22 Nov 2022, Lee Jones wrote:

> On Tue, 22 Nov 2022, John Keeping wrote:
> 
> > This series arises from the recent thread [1] on lifetime issues.
> > 
> > The main point is the first patch, with the second being an unrelated
> > fix for an issue spotted while working on this.  Both of these have
> > Fixes: tags for backporting to stable.
> > 
> > The final patch tidies up some error handling to hopefully avoid patch 2
> > issues in the future.
> > 
> > [1] https://lore.kernel.org/r/20221117120813.1257583-1-lee@kernel.org
> > 
> > John Keeping (3):
> >   usb: gadget: f_hid: fix f_hidg lifetime vs cdev
> >   usb: gadget: f_hid: fix refcount leak on error path
> >   usb: gadget: f_hid: tidy error handling in hidg_alloc
> > 
> >  drivers/usb/gadget/function/f_hid.c | 60 ++++++++++++++++-------------
> >  1 file changed, 33 insertions(+), 27 deletions(-)
> 
> For the set:
> 
> Reviewed-by: Lee Jones <lee@kernel.org>
> Tested-by: Lee Jones <lee@kernel.org>

Greg, is this still on your radar?
  
Greg KH Nov. 28, 2022, 5:47 p.m. UTC | #3
On Mon, Nov 28, 2022 at 02:04:13PM +0000, Lee Jones wrote:
> On Tue, 22 Nov 2022, Lee Jones wrote:
> 
> > On Tue, 22 Nov 2022, John Keeping wrote:
> > 
> > > This series arises from the recent thread [1] on lifetime issues.
> > > 
> > > The main point is the first patch, with the second being an unrelated
> > > fix for an issue spotted while working on this.  Both of these have
> > > Fixes: tags for backporting to stable.
> > > 
> > > The final patch tidies up some error handling to hopefully avoid patch 2
> > > issues in the future.
> > > 
> > > [1] https://lore.kernel.org/r/20221117120813.1257583-1-lee@kernel.org
> > > 
> > > John Keeping (3):
> > >   usb: gadget: f_hid: fix f_hidg lifetime vs cdev
> > >   usb: gadget: f_hid: fix refcount leak on error path
> > >   usb: gadget: f_hid: tidy error handling in hidg_alloc
> > > 
> > >  drivers/usb/gadget/function/f_hid.c | 60 ++++++++++++++++-------------
> > >  1 file changed, 33 insertions(+), 27 deletions(-)
> > 
> > For the set:
> > 
> > Reviewed-by: Lee Jones <lee@kernel.org>
> > Tested-by: Lee Jones <lee@kernel.org>
> 
> Greg, is this still on your radar?

Yes, let me catch up on pending patches...
  
Lee Jones Nov. 29, 2022, 8:59 a.m. UTC | #4
On Mon, 28 Nov 2022, Greg Kroah-Hartman wrote:

> On Mon, Nov 28, 2022 at 02:04:13PM +0000, Lee Jones wrote:
> > On Tue, 22 Nov 2022, Lee Jones wrote:
> > 
> > > On Tue, 22 Nov 2022, John Keeping wrote:
> > > 
> > > > This series arises from the recent thread [1] on lifetime issues.
> > > > 
> > > > The main point is the first patch, with the second being an unrelated
> > > > fix for an issue spotted while working on this.  Both of these have
> > > > Fixes: tags for backporting to stable.
> > > > 
> > > > The final patch tidies up some error handling to hopefully avoid patch 2
> > > > issues in the future.
> > > > 
> > > > [1] https://lore.kernel.org/r/20221117120813.1257583-1-lee@kernel.org
> > > > 
> > > > John Keeping (3):
> > > >   usb: gadget: f_hid: fix f_hidg lifetime vs cdev
> > > >   usb: gadget: f_hid: fix refcount leak on error path
> > > >   usb: gadget: f_hid: tidy error handling in hidg_alloc
> > > > 
> > > >  drivers/usb/gadget/function/f_hid.c | 60 ++++++++++++++++-------------
> > > >  1 file changed, 33 insertions(+), 27 deletions(-)
> > > 
> > > For the set:
> > > 
> > > Reviewed-by: Lee Jones <lee@kernel.org>
> > > Tested-by: Lee Jones <lee@kernel.org>
> > 
> > Greg, is this still on your radar?
> 
> Yes, let me catch up on pending patches...

Perfect, thank you.