aboutsummaryrefslogtreecommitdiffstats
path: root/src/stm32/usbfs.c
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2019-09-18 10:45:39 -0400
committerKevin O'Connor <kevin@koconnor.net>2019-09-18 11:59:43 -0400
commit8cb3d09484e6b304abbd905ffa1073683ffc2fcf (patch)
treef62fd54fe761a3b8a3672ec18013f7a07bc6555e /src/stm32/usbfs.c
parentfce98c5519019f3ea23d06cad04b55f3a4971d2c (diff)
downloadkutter-8cb3d09484e6b304abbd905ffa1073683ffc2fcf.tar.gz
kutter-8cb3d09484e6b304abbd905ffa1073683ffc2fcf.tar.xz
kutter-8cb3d09484e6b304abbd905ffa1073683ffc2fcf.zip
stm32: Move usb_request_bootloader() to chip specific code
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src/stm32/usbfs.c')
-rw-r--r--src/stm32/usbfs.c15
1 files changed, 0 insertions, 15 deletions
diff --git a/src/stm32/usbfs.c b/src/stm32/usbfs.c
index de80b9ae..a7a20548 100644
--- a/src/stm32/usbfs.c
+++ b/src/stm32/usbfs.c
@@ -10,7 +10,6 @@
#include "board/armcm_timer.h" // udelay
#include "board/gpio.h" // gpio_out_setup
#include "board/io.h" // writeb
-#include "board/irq.h" // irq_disable
#include "board/usb_cdc.h" // usb_notify_ep0
#include "board/usb_cdc_ep.h" // USB_CDC_EP_BULK_IN
#include "command.h" // DECL_CONSTANT_STR
@@ -207,20 +206,6 @@ usb_set_configure(void)
{
}
-void
-usb_request_bootloader(void)
-{
- if (!CONFIG_STM32_FLASH_START_2000)
- return;
- // Enter "stm32duino" bootloader
- irq_disable();
- RCC->APB1ENR |= RCC_APB1ENR_PWREN | RCC_APB1ENR_BKPEN;
- PWR->CR |= PWR_CR_DBP;
- BKP->DR10 = 0x01;
- PWR->CR &=~ PWR_CR_DBP;
- NVIC_SystemReset();
-}
-
/****************************************************************
* Setup and interrupts