mbox series

[v3,0/6] USB: UDC: Fix memory leaks by expanding the API

Message ID 20200813031953.13676-1-peter.chen@nxp.com (mailing list archive)
Headers show
Series USB: UDC: Fix memory leaks by expanding the API | expand

Message

Peter Chen Aug. 13, 2020, 3:19 a.m. UTC
This series expands the UDC API to fix some long-standing memory leaks
in the net2280 and net2272 drivers. And with expanding APIs, it could
manage cdns3 and dwc3 gadget device memory better without the hacks
at UDC core.

Changes from v2:
- Rebase the latest usb/next, and fix one build error for dwc3 [Patch 5/6]

Alan Stern (3):
  USB: UDC: Expand device model API interface
  USB: UDC: net2280: Fix memory leaks
  USB: UDC: net2272: Fix memory leaks

Peter Chen (3):
  usb: cdns3: gadget: fix possible memory leak
  usb: dwc3: allocate gadget structure dynamically
  Revert "usb: udc: allow adding and removing the same gadget device"

 drivers/usb/cdns3/gadget.c       |  21 ++++--
 drivers/usb/dwc3/core.h          |   2 +-
 drivers/usb/dwc3/ep0.c           |  26 ++++----
 drivers/usb/dwc3/gadget.c        | 108 ++++++++++++++++++-------------
 drivers/usb/dwc3/gadget.h        |   2 +-
 drivers/usb/gadget/udc/core.c    |  79 +++++++++++++++++-----
 drivers/usb/gadget/udc/net2272.c |  25 ++++---
 drivers/usb/gadget/udc/net2272.h |   1 +
 drivers/usb/gadget/udc/net2280.c |  13 ++--
 drivers/usb/gadget/udc/net2280.h |   1 +
 include/linux/usb/gadget.h       |  27 ++++++--
 11 files changed, 204 insertions(+), 101 deletions(-)