File tree Expand file tree Collapse file tree 3 files changed +3
-22
lines changed Expand file tree Collapse file tree 3 files changed +3
-22
lines changed Original file line number Diff line number Diff line change @@ -61,21 +61,7 @@ mbed::BlockDevice* dfu_secondary_bd = get_secondary_bd();
61
61
const uint32_t QSPIFLASH_BASE_ADDRESS = 0x90000000 ;
62
62
const uint32_t FILEBLOCK_BASE_ADDRESS = 0xA0000000 ;
63
63
64
- USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops_default = {
65
- {
66
- (uint8_t *) FLASH_DESC_STR,
67
- (uint8_t *) QSPI_FLASH_DESC_STR,
68
- (uint8_t *) BOOTLOADER_DESC_STR
69
- },
70
- Flash_If_Init,
71
- Flash_If_DeInit,
72
- Flash_If_Erase,
73
- Flash_If_Write,
74
- Flash_If_Read,
75
- Flash_If_GetStatus,
76
- };
77
-
78
- USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops_MCUboot = {
64
+ USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops = {
79
65
{
80
66
(uint8_t *) FLASH_DESC_STR,
81
67
(uint8_t *) QSPI_FLASH_DESC_STR,
Original file line number Diff line number Diff line change 48
48
#define ADDR_FLASH_SECTOR_7_BANK2 ((uint32_t)0x081E0000) /* Base @ of Sector 7, 128 Kbytes */
49
49
50
50
/* Exported macro ------------------------------------------------------------*/
51
- extern USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops_default ;
52
- extern USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops_MCUboot ;
51
+ extern USBD_DFU_MediaTypeDef USBD_DFU_Flash_fops ;
53
52
#define FLASH_BASE_ADDR (uint32_t)(FLASH_BASE)
54
53
#define FLASH_END_ADDR (uint32_t)(0x081FFFFF)
55
54
Original file line number Diff line number Diff line change @@ -151,11 +151,7 @@ static int start_dfu(void) {
151
151
USBD_RegisterClass (&USBD_Device, USBD_DFU_CLASS);
152
152
153
153
/* Add DFU Media interface */
154
- if (boot_empty_keys ()) {
155
- USBD_DFU_RegisterMedia (&USBD_Device, &USBD_DFU_Flash_fops_default);
156
- } else {
157
- USBD_DFU_RegisterMedia (&USBD_Device, &USBD_DFU_Flash_fops_MCUboot);
158
- }
154
+ USBD_DFU_RegisterMedia (&USBD_Device, &USBD_DFU_Flash_fops);
159
155
160
156
/* Start Device Process */
161
157
USBD_Start (&USBD_Device);
You can’t perform that action at this time.
0 commit comments