From 141a11409e125abeca98d069eec6fcfee480d5fd Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Sat, 7 Jan 2012 17:38:11 +0100 Subject: DFU: include more common infrastructure for download and upload handling --- usb/device/dfu/dfu.h | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'usb/device/dfu/dfu.h') diff --git a/usb/device/dfu/dfu.h b/usb/device/dfu/dfu.h index 34afa4a..bf07d43 100644 --- a/usb/device/dfu/dfu.h +++ b/usb/device/dfu/dfu.h @@ -116,13 +116,16 @@ struct dfu { uint8_t status; uint32_t state; int past_manifest; + unsigned int total_bytes; }; extern struct dfu dfu; /* call-backs by the board/SOC */ -extern int USBDFU_handle_dnload(uint16_t val, uint16_t len, int first); -extern int USBDFU_handle_upload(uint16_t val, uint16_t len, int first); +extern int USBDFU_handle_dnload(uint8_t altif, unsigned int offset, + uint8_t *data, unsigned int len); +extern int USBDFU_handle_upload(uint8_t altif, unsigned int offset, + uint8_t *data, unsigned int req_len); void USBDFU_Runtime_RequestHandler(const USBGenericRequest *request); void USBDFU_DFU_RequestHandler(const USBGenericRequest *request); -- cgit v1.2.3