diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2018-04-28 08:19:36 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2018-04-28 08:19:36 +0000 |
commit | ac785c3feb3f9595d6f9768d5a10ed1739553d6f (patch) | |
tree | 4813b65055479800c8e3b46e15819cc7c93ffe14 | |
parent | e5f6ae651d7f62bfacd04003662d872834ff5f03 (diff) |
Correct IST macro and add a new macro for setting Frame IDs.
-rw-r--r-- | sys/dev/usb/xhcireg.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/usb/xhcireg.h b/sys/dev/usb/xhcireg.h index 5b60d02d5a9..b0aa87eb900 100644 --- a/sys/dev/usb/xhcireg.h +++ b/sys/dev/usb/xhcireg.h @@ -1,4 +1,4 @@ -/* $OpenBSD: xhcireg.h,v 1.13 2018/04/27 14:17:52 mpi Exp $ */ +/* $OpenBSD: xhcireg.h,v 1.14 2018/04/28 08:19:35 mpi Exp $ */ /*- * Copyright (c) 2014 Martin Pieuchot. All rights reserved. @@ -71,7 +71,8 @@ #define XHCI_HCS1_N_PORTS(x) (((x) >> 24) & 0xff) #define XHCI_HCSPARAMS2 0x08 /* RO structual parameters 2 */ -#define XHCI_HCS2_IST(x) ((x) & 0xf) +#define XHCI_HCS2_IST(x) ((x) & 0x7) +#define XHCI_HCS2_IST_MICRO(x) (!((x) & 0x8)) #define XHCI_HCS2_ERST_MAX(x) (((x) >> 4) & 0xf) #define XHCI_HCS2_ETE(x) (((x) >> 8) & 0x1) #define XHCI_HCS2_SPR(x) (((x) >> 26) & 0x1) @@ -362,6 +363,7 @@ struct xhci_trb { #define XHCI_TRB_GET_EP(x) (((x) >> 16) & 0x1f) #define XHCI_TRB_SET_EP(x) (((x) & 0x1f) << 16) #define XHCI_TRB_ISOC_TLBPC(x) (((x) & 0xf) << 16) +#define XHCI_TRB_ISOC_FRAME(x) (((x) & 0x7ff) << 20) #define XHCI_TRB_GET_SLOT(x) (((x) >> 24) & 0xff) #define XHCI_TRB_SET_SLOT(x) (((x) & 0xff) << 24) #define XHCI_TRB_SIA (1U << 31) |