usb: gadget: remove build warnings
[profile/mobile/platform/kernel/u-boot-tm1.git] / drivers / usb / gadget / f_obex.c
index eed4a0d..e7214be 100644 (file)
@@ -263,9 +263,8 @@ static int obex_get_alt(struct usb_function *f, unsigned intf)
 static void obex_disable(struct usb_function *f)
 {
        struct f_obex   *obex = func_to_obex(f);
-       struct usb_composite_dev *cdev = f->config->cdev;
 
-       DBG(cdev, "obex ttyGS%d disable\n", obex->port_num);
+       DBG(f->config->cdev, "obex ttyGS%d disable\n", obex->port_num);
        gserial_disconnect(&obex->port);
 }
 
@@ -274,7 +273,6 @@ static void obex_disable(struct usb_function *f)
 static void obex_connect(struct gserial *g)
 {
        struct f_obex           *obex = port_to_obex(g);
-       struct usb_composite_dev *cdev = g->func.config->cdev;
        int                     status;
 
        if (!obex->can_activate)
@@ -282,14 +280,14 @@ static void obex_connect(struct gserial *g)
 
        status = usb_function_activate(&g->func);
        if (status)
-               DBG(cdev, "obex ttyGS%d function activate --> %d\n",
+               DBG(g->func.config->cdev,
+                       "obex ttyGS%d function activate --> %d\n",
                        obex->port_num, status);
 }
 
 static void obex_disconnect(struct gserial *g)
 {
        struct f_obex           *obex = port_to_obex(g);
-       struct usb_composite_dev *cdev = g->func.config->cdev;
        int                     status;
 
        if (!obex->can_activate)
@@ -297,7 +295,8 @@ static void obex_disconnect(struct gserial *g)
 
        status = usb_function_deactivate(&g->func);
        if (status)
-               DBG(cdev, "obex ttyGS%d function deactivate --> %d\n",
+               DBG(g->func.config->cdev,
+                       "obex ttyGS%d function deactivate --> %d\n",
                        obex->port_num, status);
 }