Lines Matching refs:dfu_state
455 dev->dfu_state = new_state;
461 return dev->dfu_state;
475 dev->dfu_state = USB_DFU_ERROR;
483 if (dev->dfu_state == USB_DFU_APP_DETACH)
485 dev->dfu_state = USB_DFU_IDLE;
527 dev->dfu_state = USB_DFU_APP_IDLE;
539 int dfu_state = dev->dfu_state;
541 if (dfu_state == USB_DFU_DNLOAD_SYNC)
543 dev->dfu_state = USB_DFU_DNLOAD_IDLE;
545 else if (dfu_state == USB_DFU_DNBUSY)
547 dev->dfu_state = USB_DFU_DNLOAD_SYNC;
549 else if (dfu_state == USB_DFU_MANIFEST_SYNC)
551 dev->dfu_state = USB_DFU_MANIFEST;
553 else if (dfu_state == USB_DFU_MANIFEST)
555 dev->dfu_state = USB_DFU_IDLE;
559 status->state = (uint8_t)dev->dfu_state;
579 dev->dfu_state = USB_DFU_DNLOAD_SYNC;
584 if (dev->dfu_state == USB_DFU_IDLE)
586 dev->dfu_state = USB_DFU_ERROR;
591 dev->dfu_state = USB_DFU_MANIFEST_SYNC;
605 if (dev->dfu_state == USB_DFU_IDLE)
607 dev->dfu_state = USB_DFU_UPLOAD_IDLE;
611 else if (dev->dfu_state == USB_DFU_UPLOAD_IDLE)