[PATCH 6/7] usb: gadget: fastboot: simplify reboot

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Now that we end the fastboot session when shutting down barebox
we can call restart_machine() directly and not in the completion
callback of the answer request.

Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx>
---
 drivers/usb/gadget/f_fastboot.c | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/drivers/usb/gadget/f_fastboot.c b/drivers/usb/gadget/f_fastboot.c
index f6eb30dec4..067b43ebed 100644
--- a/drivers/usb/gadget/f_fastboot.c
+++ b/drivers/usb/gadget/f_fastboot.c
@@ -622,15 +622,9 @@ int fastboot_tx_print(struct f_fastboot *f_fb, enum fastboot_msg_type type,
 	return fastboot_tx_write(f_fb, buf, n);
 }
 
-static void compl_do_reset(struct usb_ep *ep, struct usb_request *req)
-{
-	restart_machine();
-}
-
 static void cb_reboot(struct f_fastboot *f_fb, const char *cmd)
 {
-	f_fb->in_req->complete = compl_do_reset;
-	fastboot_tx_print(f_fb, FASTBOOT_MSG_OKAY, "");
+	restart_machine();
 }
 
 static int strcmp_l1(const char *s1, const char *s2)
-- 
2.19.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux