The HcRhDescriptorA register is the first register of two describing the characteristics of the Root Hub. Reset values are implementation-specific. The descriptor length (11), descriptor type (TBD), and hub controller current (0) fields of the hub Class Descriptor are emulated by the HCD. All other fields are located in the HcRhDescriptorA and HcRhDescriptorB registers.

上文:
HcRhDescriptorA寄存器是两个描述根集线器特性寄存器中的第一个。复位值由具体实现决定。集线器类别描述符中的描述符长度(11)、描述符类型(待定)和集线器控制器电流(0)字段均由主机控制器驱动程序(HCD)模拟实现。所有其他字段位于HcRhDescriptorA和HcRhDescriptorB寄存器中。

图7-19:HcRhDescriptorA寄存器

寄存器位布局(31:0)

位域 31-24 23-13 12 11 10 9 8 7-0
字段 POTPGT Reserved NOCP OCPM DT NPS PSM NDP

字段功能说明

  • POTPGT bit[31,24]
    PowerOnToPowerGoodTime
    This byte specifies the duration HCD has to wait before accessing a powered-on port of the Root Hub. It is implementation-specific. The unit of time is 2 ms. The duration is calculated as POTPGT * 2 ms

    上文:
    电源开启至电源稳定时间(POTPGT)
    该字节指定主机控制器驱动程序(HCD)在访问根集线器已上电端口前必须等待的持续时间。该值为实现特定值。时间单位为2毫秒。持续时间计算公式为:POTPGT × 2毫秒

  • NOCP bit[12]
    NoOverCurrentProtection
    This bit describes how the overcurrent status for the Root Hub ports are reported. When this bit is cleared, the OverCurrentProtectionMode field specifies global or per-port reporting.
    0: Over-current status is reported collectively for all downstream ports
    1: No overcurrent protection supported

    上文:
    无过流保护(NoOverCurrentProtection)
    该位描述根集线器端口的过流状态报告方式。当该位清零时,过流保护模式字段(OverCurrentProtectionMode)将指定全局报告或每端口报告。
    0:所有下游端口的过流状态集中报告
    1:不支持过流保护功能

  • OCPM bit[11]
    OverCurrentProtectionMode
    This bit describes how the overcurrent status for the Root Hub ports are reported. At reset, this fields should reflect the same mode as PowerSwitchingMode. This field is valid only if the NoOverCurrentProtection field is cleared.
    0: over-current status is reported collectively for all downstream ports
    1: over-current status is reported on a per-port basis

    上文:
    过流保护模式(OverCurrentProtectionMode)
    该位描述根集线器端口的过流状态报告方式。复位时,此字段应反映与电源切换模式(PowerSwitchingMode)相同的模式。此字段仅在无过流保护字段(NoOverCurrentProtection)清零时有效。
    0:所有下游端口的过流状态集中报告
    1:过流状态按端口单独报告

  • DT bit[10]
    DeviceType
    This bit specifies that the Root Hub is not a compound device. The Root Hub is not permitted to be a compound device. This field should always read/write 0.

    上文:
    设备类型(DeviceType)
    该位指定根集线器不是复合设备。根集线器不允许作为复合设备使用。此字段应始终读写为0。

  • NPS bit[9]
    无电源切换(NoPowerSwitching)
    这些位用于指定是否支持电源切换,或端口始终供电。该值为实现特定值。当该位清零时,电源切换模式(PowerSwitchingMode)将指定全局切换或每端口切换。
    0:端口支持电源切换
    1:当主机控制器(HC)上电时,端口始终供电

  • PSM bit[8]
    PowerSwitchingMode
    This bit is used to specify how the power switching of the Root Hub ports is controlled. It is implementation-specific. This field is only valid if the NoPowerSwitching field is cleared.
    0: all ports are powered at the same time.
    1: each port is powered individually. This mode allows port
    power to be controlled by either the global switch or perport switching. If the PortPowerControlMask bit is set, the port responds only to port power commands
    (Set/ClearPortPower). If the port mask is cleared, then the port is controlled only by the global power switch (Set/ClearGlobalPower).

    上文:
    电源切换模式(PowerSwitchingMode)
    该位用于指定根集线器端口的电源切换控制方式。该值为实现特定值。此字段仅在NoPowerSwitching字段清零时有效。
    0:所有端口同时上电
    1:每个端口独立供电。此模式允许端口电源通过全局开关或每端口切换进行控制。若PortPowerControlMask位置位,端口仅响应端口电源命令(Set/ClearPortPower);若端口掩码清零,则端口仅由全局电源开关控制(Set/ClearGlobalPower)。

  • NDP bit[7,0]
    下游端口数量(NumberDownstreamPorts)
    这些位指定根集线器支持的下游端口数量。该值为实现特定值。最小端口数量为1。OpenHCI支持的最大端口数量为15。