From 2ed14320f3fed9e5b774ef68bdf73a4f3e28844e Mon Sep 17 00:00:00 2001 From: Felipe Balbi Date: Tue, 26 Feb 2013 10:59:41 +0200 Subject: [PATCH] usb: gadget: udc-core: initialize parent if udc-core always does it, we can delete some extra lines from all UDC drivers. Besides, it avoids mistakes from happening and propagating. Signed-off-by: Felipe Balbi --- drivers/usb/gadget/udc-core.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/usb/gadget/udc-core.c b/drivers/usb/gadget/udc-core.c index 3e19a016c197..447a1614736e 100644 --- a/drivers/usb/gadget/udc-core.c +++ b/drivers/usb/gadget/udc-core.c @@ -184,6 +184,7 @@ int usb_add_gadget_udc(struct device *parent, struct usb_gadget *gadget) goto err1; dev_set_name(&gadget->dev, "gadget"); + gadget->dev.parent = parent; dma_set_coherent_mask(&gadget->dev, parent->coherent_dma_mask); gadget->dev.dma_parms = parent->dma_parms; -- GitLab