From 40a87784913066f74c2f7a1e9f5f54aaf4692364 Mon Sep 17 00:00:00 2001 From: Jerry Zhang Date: Thu, 27 Apr 2017 15:00:13 -0700 Subject: [PATCH] Revert "adb: Lower EP_ALLOC retry count" This reverts commit 05fe272a87c6be24d3e2808ecceed2be063b9c1d. Commit "adb: Do not signal gaget stack unless descriptors are written" fixed the main issue for configfs devices where device wasn't enabled until after the ioctl was attempted. Thus it is safe to bring up the retry count so that the ioctl doesn't fail due to small delays in usb stack. Test: use adb, switch configs on configfs devices --- adb/daemon/usb.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adb/daemon/usb.cpp b/adb/daemon/usb.cpp index 7e46b0265..d3b2f3d7d 100644 --- a/adb/daemon/usb.cpp +++ b/adb/daemon/usb.cpp @@ -64,7 +64,7 @@ using namespace std::chrono_literals; #define FUNCTIONFS_ENDPOINT_ALLOC _IOR('g', 231, __u32) -static constexpr size_t ENDPOINT_ALLOC_RETRIES = 2; +static constexpr size_t ENDPOINT_ALLOC_RETRIES = 10; static int dummy_fd = -1;