/* Indicates that SUSPEND state has been detected on the USB.  */
static void usb_susp_isr(usb_core_instance *pdev)
/* Indicates that SUSPEND state has been detected on the USB.  */
static void usb_susp_isr(usb_core_instance *pdev)
{
    uint32_t u32dsts;
    uint8_t u8PrevStatus;
    dev_int_cbkpr->Suspend(pdev);
    u32dsts = READ_REG32(pdev->regs.DREGS->DSTS);
    WRITE_REG32(pdev->regs.GREGS->GINTSTS, USBFS_GINTSTS_USBSUSP);
    u8PrevStatus = pdev->dev.device_old_status;
    if ((pdev->dev.connection_status == 1U) && (u8PrevStatus == USB_DEV_CONFIGURED) &&
        (0U != pdev->basic_cfgs.low_power) && ((u32dsts & 1UL) != 0UL)) {
        SET_REG32_BIT(*pdev->regs.GCCTL, USBFS_GCCTL_STPPCLK);
        SET_REG32_BIT(*pdev->regs.GCCTL, USBFS_GCCTL_GATEHCLK);
    }
}