Skip to contentSkip to conversation

pvusb: mark request as consumed after finished using it

PATCH New Juergen Gross 1 participant 1 message Sep 26, 2014 Xen hypervisor interface

lore
Share & tools
lore

Juergen Gross

author maintainer
#0 lore raw

PATCH 1/1 pvusb: mark request as consumed after finished using it

A request from the pvusb frontend should be marked as consumed by the backend only after the backend isn't accessing the request data in the communication ring any more.

drivers/xen/usbback/usbback.c +1 -1
diff -r 2b001f768b76 drivers/xen/usbback/usbback.c
@@ -1003,10 +1003,10 @@ static int usbbk_start_submit_urb(usbif_
 		}
 
 		req = RING_GET_REQUEST(urb_ring, rc);
-		urb_ring->req_cons = ++rc;
 
 		dispatch_request_to_pending_reqs(usbif, req,
 							pending_req);
+		urb_ring->req_cons = ++rc;
 
 		cond_resched();
 	}