From 2b0fda8a11ab3d861d6ad19e3f95015fb193e68b Mon Sep 17 00:00:00 2001 From: PaulStoffregen Date: Sun, 8 Oct 2017 03:35:20 -0700 Subject: [PATCH] Fix device list of drivers in use --- enumeration.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/enumeration.cpp b/enumeration.cpp index f75f538..268bf39 100644 --- a/enumeration.cpp +++ b/enumeration.cpp @@ -344,11 +344,8 @@ void USBHost::claim_drivers(Device_t *dev) available_drivers = driver->next; } // add to list of drivers using this device - if (dev->drivers) { - dev->drivers->next = driver; - } + driver->next = dev->drivers; dev->drivers = driver; - driver->next = NULL; driver->device = dev; // not done, may be more interface for more drivers }