summaryrefslogtreecommitdiff
path: root/usrp/host/lib/legacy
diff options
context:
space:
mode:
authoreb2008-04-30 03:52:31 +0000
committereb2008-04-30 03:52:31 +0000
commit9d1423b9506c89a51a10b6119d01ce9a82a13b0c (patch)
tree186e1b20618bf805dd262572bd3b2778b767d201 /usrp/host/lib/legacy
parent7f202514385708941073930bc6d9a5237bb89826 (diff)
downloadgnuradio-9d1423b9506c89a51a10b6119d01ce9a82a13b0c.tar.gz
gnuradio-9d1423b9506c89a51a10b6119d01ce9a82a13b0c.tar.bz2
gnuradio-9d1423b9506c89a51a10b6119d01ce9a82a13b0c.zip
Merged features/inband-usb -r6431:8293 into trunk.
git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@8295 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'usrp/host/lib/legacy')
-rw-r--r--usrp/host/lib/legacy/fusb_linux.cc26
1 files changed, 13 insertions, 13 deletions
diff --git a/usrp/host/lib/legacy/fusb_linux.cc b/usrp/host/lib/legacy/fusb_linux.cc
index 60687a149..6dce8d9e0 100644
--- a/usrp/host/lib/legacy/fusb_linux.cc
+++ b/usrp/host/lib/legacy/fusb_linux.cc
@@ -386,14 +386,6 @@ fusb_ephandle_linux::stop ()
{
if (!d_started)
return true;
-
- d_devhandle->_cancel_pending_rqsts (this);
- d_devhandle->_reap (false);
-
-
- usbdevfs_urb *urb;
- while ((urb = completed_list_get ()) != 0)
- free_list_add (urb);
if (d_write_work_in_progress){
free_list_add (d_write_work_in_progress);
@@ -407,11 +399,19 @@ fusb_ephandle_linux::stop ()
d_read_buffer_end = 0;
}
- if (d_free_list.size () != (unsigned) d_nblocks)
- fprintf (stderr, "d_free_list.size () = %d, d_nblocks = %d\n",
- d_free_list.size (), d_nblocks);
-
- assert (d_free_list.size () == (unsigned) d_nblocks);
+ d_devhandle->_cancel_pending_rqsts (this);
+ d_devhandle->_reap (false);
+
+ while (1){
+ usbdevfs_urb *urb;
+ while ((urb = completed_list_get ()) != 0)
+ free_list_add (urb);
+
+ if (d_free_list.size () == (unsigned) d_nblocks)
+ break;
+
+ d_devhandle->_reap(true);
+ }
d_started = false;
return true;