PERFORCE change 140367 for review

Hans Petter Selasky hselasky at FreeBSD.org
Mon Apr 21 18:24:05 UTC 2008


http://perforce.freebsd.org/chv.cgi?CH=140367

Change 140367 by hselasky at hselasky_laptop001 on 2008/04/21 18:23:48

	
	Need to flush after last write to structure and not before.

Affected files ...

.. //depot/projects/usb/src/sys/dev/usb/ehci.c#76 edit
.. //depot/projects/usb/src/sys/dev/usb/ohci.c#63 edit
.. //depot/projects/usb/src/sys/dev/usb/uhci.c#62 edit

Differences ...

==== //depot/projects/usb/src/sys/dev/usb/ehci.c#76 (text+ko) ====

@@ -1113,11 +1113,11 @@
 
 		sqh->qh_qtd.qtd_next = htole32(EHCI_LINK_TERMINATE);
 
-		usbd_pc_cpu_flush(sqh->page_cache);
-
 		last = ((last == sqh) ? sqh->prev : last);
 
 		sqh->prev = 0;
+
+		usbd_pc_cpu_flush(sqh->page_cache);
 	}
 	return (last);
 }

==== //depot/projects/usb/src/sys/dev/usb/ohci.c#63 (text+ko) ====

@@ -755,11 +755,11 @@
 		sed->ed_flags |= htole32(OHCI_ED_SKIP);
 		sed->ed_headp = sed->ed_tailp;
 
-		usbd_pc_cpu_flush(sed->page_cache);
-
 		last = ((last == sed) ? sed->prev : last);
 
 		sed->prev = 0;
+
+		usbd_pc_cpu_flush(sed->page_cache);
 	}
 	return (last);
 }

==== //depot/projects/usb/src/sys/dev/usb/uhci.c#62 (text+ko) ====

@@ -1011,11 +1011,11 @@
 		 */
 		sqh->qh_e_next = htole32(UHCI_PTR_T);
 
-		usbd_pc_cpu_flush(sqh->page_cache);
-
 		last = ((last == sqh) ? sqh->h_prev : last);
 
 		sqh->h_prev = 0;
+
+		usbd_pc_cpu_flush(sqh->page_cache);
 	}
 	return (last);
 }


More information about the p4-projects mailing list