Module Name: src
Committed By: tsutsui
Date: Wed Jan 30 16:01:45 UTC 2013
Modified Files:
src/sys/dev/usb: uhci.c
Log Message:
Add missed byteswap ops for BE machines in block added in rev 1.223.
To generate a diff of this commit:
cvs rdiff -u -r1.254 -r1.255 src/sys/dev/usb/uhci.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/dev/usb/uhci.c
diff -u src/sys/dev/usb/uhci.c:1.254 src/sys/dev/usb/uhci.c:1.255
--- src/sys/dev/usb/uhci.c:1.254 Tue Jan 29 19:27:36 2013
+++ src/sys/dev/usb/uhci.c Wed Jan 30 16:01:45 2013
@@ -1,4 +1,4 @@
-/* $NetBSD: uhci.c,v 1.254 2013/01/29 19:27:36 christos Exp $ */
+/* $NetBSD: uhci.c,v 1.255 2013/01/30 16:01:45 tsutsui Exp $ */
/*
* Copyright (c) 1998, 2004, 2011, 2012 The NetBSD Foundation, Inc.
@@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uhci.c,v 1.254 2013/01/29 19:27:36 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uhci.c,v 1.255 2013/01/30 16:01:45 tsutsui Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -1865,8 +1865,8 @@ uhci_free_std_chain(uhci_softc_t *sc, uh
p->offs + offsetof(uhci_td_t, td_link),
sizeof(p->td.td_link),
BUS_DMASYNC_POSTWRITE | BUS_DMASYNC_POSTREAD);
- if ((p->td.td_link & UHCI_PTR_T) == 0) {
- p->td.td_link = UHCI_PTR_T;
+ if ((le32toh(p->td.td_link) & UHCI_PTR_T) == 0) {
+ p->td.td_link = htole32(UHCI_PTR_T);
usb_syncmem(&p->dma,
p->offs + offsetof(uhci_td_t, td_link),
sizeof(p->td.td_link),