/* Store the receive time-stamp for event PTP frame in the time-stamp buffer ring.  */
static void ENET_QOS_StoreRxFrameTime(ENET_QOS_Type *base, enet_qos_handle_t *handle, enet_qos_rx_bd_struct_t *rxDesc, enet_qos_ptp_time_t *ts)
/* Store the receive time-stamp for event PTP frame in the time-stamp buffer ring.  */
static void ENET_QOS_StoreRxFrameTime(ENET_QOS_Type *base, enet_qos_handle_t *handle, enet_qos_rx_bd_struct_t *rxDesc, enet_qos_ptp_time_t *ts)
{
    assert(ts != NULL);
    uint32_t nanosecond;
    nanosecond = rxDesc->buff1Addr;
    if ((base->MAC_TIMESTAMP_CONTROL & ENET_QOS_MAC_TIMESTAMP_CONTROL_TSCTRLSSR_MASK) == 0U)
    {
        nanosecond = (uint32_t)(((uint64_t)nanosecond * 465U) / 1000U);
    }
    ts->second     = rxDesc->reserved;
    ts->nanosecond = nanosecond;
}