more missing-prototypes fixes

This commit is contained in:
Jeff Epler 2021-11-10 12:47:55 -06:00
parent ebc8359c67
commit 340d6b9213
No known key found for this signature in database
GPG Key ID: D5BF15AB975AB4DE
7 changed files with 11 additions and 6 deletions

View File

@ -28,6 +28,7 @@
#include "py/runtime.h"
#include "common-hal/alarm/SleepMemory.h"
#include "shared-bindings/alarm/SleepMemory.h"
#include "shared-bindings/nvm/ByteArray.h"
void alarm_sleep_memory_reset(void) {

View File

@ -78,10 +78,6 @@ void port_internal_flash_flush(void) {
void supervisor_flash_release_cache(void) {
}
void flash_flush(void) {
supervisor_flash_flush();
}
static int32_t convert_block_to_flash_addr(uint32_t block) {
if (0 <= block && block < INTERNAL_FLASH_PART1_NUM_BLOCKS) {
// a block in partition 1
@ -91,7 +87,7 @@ static int32_t convert_block_to_flash_addr(uint32_t block) {
return -1;
}
bool supervisor_flash_read_block(uint8_t *dest, uint32_t block) {
STATIC bool supervisor_flash_read_block(uint8_t *dest, uint32_t block) {
// non-MBR block, get data from flash memory
int32_t src = convert_block_to_flash_addr(block);
if (src == -1) {
@ -102,7 +98,7 @@ bool supervisor_flash_read_block(uint8_t *dest, uint32_t block) {
return error_code == ERR_NONE;
}
bool supervisor_flash_write_block(const uint8_t *src, uint32_t block) {
STATIC bool supervisor_flash_write_block(const uint8_t *src, uint32_t block) {
// non-MBR block, copy to cache
int32_t dest = convert_block_to_flash_addr(block);
if (dest == -1) {

View File

@ -26,6 +26,7 @@
*/
#include "shared-bindings/microcontroller/Pin.h"
#include "supervisor/board.h"
void board_init(void) {

View File

@ -25,6 +25,7 @@
*/
#include "shared-bindings/microcontroller/Pin.h"
#include "supervisor/board.h"
void board_init(void) {
// USB
@ -54,5 +55,7 @@ bool board_requests_safe_mode(void) {
void reset_board(void) {
}
#if CIRCUITPY_ALARM
void board_deinit(void) {
}
#endif

View File

@ -39,6 +39,8 @@ typedef void (*func)(void);
extern void _start(void) __attribute__((noreturn));
extern void SystemInit(void);
extern void Default_Handler(void);
extern void Reset_Handler(void);
void Default_Handler(void) {
while (1) {

View File

@ -28,6 +28,7 @@
#include "shared-bindings/microcontroller/Pin.h"
#include "src/rp2_common/hardware_gpio/include/hardware/gpio.h"
#include "supervisor/shared/board.h"
#include "supervisor/board.h"
void board_init(void) {
}

View File

@ -26,6 +26,7 @@
#include "py/mpstate.h"
#include "shared-bindings/digitalio/DigitalInOut.h"
#include "shared-bindings/gamepadshift/GamePadShift.h"
#include "shared-module/gamepadshift/GamePadShift.h"
#include "supervisor/shared/tick.h"