diff options
author | Sarah Sharp <sarah.a.sharp@linux.intel.com> | 2009-11-09 16:35:23 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-12-11 14:55:22 -0500 |
commit | 6648f29d3be2972a74ef8e29aa5d425ab4f1fc48 (patch) | |
tree | 019ca7fd4b73772952f570ef2a5dec67c5eabeaa /drivers/usb/host/xhci.h | |
parent | 7f4e985448e82fe4a1cc0ae4fcecaf7e0301c07b (diff) |
USB: xhci: Add tests for TRB address translation.
It's not surprising that the transfer request buffer (TRB) physical to
virtual address translation function has bugs in it, since I wrote most of
it at 4am last October. Add a test suite to check the TRB math. This
runs at memory initialization time, and causes the driver to fail to load
if the TRB math fails.
Please excuse the excessively long lines in the test vectors; they can't
really be made shorter and still be readable.
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/xhci.h')
-rw-r--r-- | drivers/usb/host/xhci.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/host/xhci.h b/drivers/usb/host/xhci.h index c92f84154fb5..3989aadcf670 100644 --- a/drivers/usb/host/xhci.h +++ b/drivers/usb/host/xhci.h | |||
@@ -1268,6 +1268,9 @@ void xhci_reset_bandwidth(struct usb_hcd *hcd, struct usb_device *udev); | |||
1268 | 1268 | ||
1269 | /* xHCI ring, segment, TRB, and TD functions */ | 1269 | /* xHCI ring, segment, TRB, and TD functions */ |
1270 | dma_addr_t xhci_trb_virt_to_dma(struct xhci_segment *seg, union xhci_trb *trb); | 1270 | dma_addr_t xhci_trb_virt_to_dma(struct xhci_segment *seg, union xhci_trb *trb); |
1271 | struct xhci_segment *trb_in_td(struct xhci_segment *start_seg, | ||
1272 | union xhci_trb *start_trb, union xhci_trb *end_trb, | ||
1273 | dma_addr_t suspect_dma); | ||
1271 | void xhci_ring_cmd_db(struct xhci_hcd *xhci); | 1274 | void xhci_ring_cmd_db(struct xhci_hcd *xhci); |
1272 | void *xhci_setup_one_noop(struct xhci_hcd *xhci); | 1275 | void *xhci_setup_one_noop(struct xhci_hcd *xhci); |
1273 | void xhci_handle_event(struct xhci_hcd *xhci); | 1276 | void xhci_handle_event(struct xhci_hcd *xhci); |