OpenOCD
rp2xxx.c File Reference
Include dependency graph for rp2xxx.c:

Go to the source code of this file.

Data Structures

struct  rp2xxx_flash_bank
 
struct  rp2xxx_rom_call_batch_record
 

Macros

#define ACCESSCTRL_CFGRESET_OFFSET   0x40060008u
 
#define ACCESSCTRL_LOCK_DEBUG_BITS   0x00000008u
 
#define ACCESSCTRL_LOCK_OFFSET   0x40060000u
 
#define ACCESSCTRL_WRITE_PASSWORD   0xacce0000u
 
#define BOOTROM_MAGIC_ADDR   0x00000010
 
#define BOOTROM_MAGIC_MASK   0xffffff
 
#define BOOTROM_RP2040_MAGIC   0x01754d
 
#define BOOTROM_RP2350_MAGIC   0x02754d
 
#define BOOTROM_STATE_RESET_CURRENT_CORE   0x01
 
#define BOOTROM_STATE_RESET_GLOBAL_STATE   0x04
 
#define BOOTROM_STATE_RESET_OTHER_CORE   0x02
 
#define FUNC_BOOTROM_SET_STACK   MAKE_TAG('S', 'S')
 
#define FUNC_BOOTROM_STATE_RESET   MAKE_TAG('S', 'R')
 
#define FUNC_CONNECT_INTERNAL_FLASH   MAKE_TAG('I', 'F')
 
#define FUNC_FLASH_ENTER_CMD_XIP   MAKE_TAG('C', 'X')
 
#define FUNC_FLASH_EXIT_XIP   MAKE_TAG('E', 'X')
 
#define FUNC_FLASH_FLUSH_CACHE   MAKE_TAG('F', 'C')
 
#define FUNC_FLASH_RANGE_ERASE   MAKE_TAG('R', 'E')
 
#define FUNC_FLASH_RANGE_PROGRAM   MAKE_TAG('R', 'P')
 
#define FUNC_FLASH_RESET_ADDRESS_TRANS   MAKE_TAG('R', 'A')
 
#define IS_RP2040(id)   (RP2XXX_CHIP_ID_PART_MANUFACTURER(id) == RP2XXX_MK_PART(RP2040_CHIP_ID_PART))
 
#define IS_RP2350(id)   (RP2XXX_CHIP_ID_PART_MANUFACTURER(id) == RP2XXX_MK_PART(RP2350_CHIP_ID_PART))
 
#define LOG_ROM_SYMBOL_DEBUG   LOG_DEBUG
 
#define MAKE_TAG(a, b)   (((b)<<8) | a)
 
#define ROM_CALL_BATCH_ALGO_SIZE_BYTES   32
 
#define RP2040_CHIP_ID_PART   0x0002
 
#define RP2040_QSPI_CTRL   0x4001800c
 
#define RP2040_QSPI_CTRL_OUTOVER_HIGH   (3ul << 8)
 
#define RP2040_QSPI_CTRL_OUTOVER_LOW   (2ul << 8)
 
#define RP2040_QSPI_CTRL_OUTOVER_MASK   (3ul << 8)
 
#define RP2040_SSI_DR0   0x18000060
 
#define RP2350_CHIP_ID_PART   0x0004
 
#define RP2350_QMI_DIRECT_CSR   0x400d0000
 
#define RP2350_QMI_DIRECT_CSR_ASSERT_CS0N   BIT(2)
 
#define RP2350_QMI_DIRECT_CSR_EN   BIT(0)
 
#define RP2350_QMI_DIRECT_RX   0x400d0008
 
#define RP2350_QMI_DIRECT_TX   0x400d0004
 
#define RP2350_QMI_DIRECT_TX_NOPUSH   BIT(20)
 
#define RP2350_QMI_DIRECT_TX_OE   BIT(19)
 
#define RP2XXX_CHIP_ID_MANUFACTURER   0x493
 
#define RP2XXX_CHIP_ID_PART_MANUFACTURER(id)   ((id) & 0x0fffffff)
 
#define RP2XXX_CHIP_ID_REVISION(id)   ((id) >> 28)
 
#define RP2XXX_MAX_ALGO_STACK_USAGE   1024
 
#define RP2XXX_MAX_RAM_ALGO_SIZE   1024
 
#define RP2XXX_MK_PART(part)   (((part) << 12) | (RP2XXX_CHIP_ID_MANUFACTURER << 1) | 1)
 
#define RP2XXX_ROM_API_FIXED_FLASH_PAGE   256
 
#define RP2XXX_ROM_API_FIXED_FLASH_SECTOR   4096
 
#define RP2XXX_SYSINFO_CHIP_ID   0x40000000
 
#define RT_FLAG_DATA   0x40
 
#define RT_FLAG_FUNC_ARM_NONSEC   0x10
 
#define RT_FLAG_FUNC_ARM_SEC   0x04
 
#define RT_FLAG_FUNC_RISCV   0x01
 

Functions

static void cleanup_after_raw_flash_cmd (struct target *target, struct rp2xxx_flash_bank *priv)
 
 COMMAND_HANDLER (rp2xxx_rom_api_call_handler)
 
 COMMAND_HANDLER (rp2xxx_switch_target_handler)
 
 FLASH_BANK_COMMAND_HANDLER (rp2xxx_flash_bank_command)
 
static int rp2040_lookup_rom_symbol (struct target *target, uint16_t tag, uint16_t flags, uint16_t *symbol_out)
 
static int rp2040_spi_tx_rx (struct target *target, const uint8_t *tx, unsigned int tx_len, unsigned int dummy_len, uint8_t *rx, unsigned int rx_len)
 
static int rp2040_ssel_active (struct target *target, bool active)
 
static int rp2350_a0_lookup_symbol (struct target *target, uint16_t tag, uint16_t flags, uint16_t *symbol_out)
 
static int rp2350_init_accessctrl (struct target *target)
 
static int rp2350_init_arm_core0 (struct target *target, struct rp2xxx_flash_bank *priv)
 
static int rp2350_lookup_rom_symbol (struct target *target, uint32_t ptr_to_entry, uint16_t tag, uint16_t flags, uint16_t *symbol_out)
 
static int rp2350_spi_tx_rx (struct target *target, const uint8_t *tx, unsigned int tx_len, unsigned int dummy_len, uint8_t *rx, unsigned int rx_len)
 
static int rp2xxx_call_rom_func (struct target *target, struct rp2xxx_flash_bank *priv, uint16_t func_offset, uint32_t argdata[], unsigned int n_args)
 
static int rp2xxx_call_rom_func_batch (struct target *target, struct rp2xxx_flash_bank *priv, struct rp2xxx_rom_call_batch_record *calls, unsigned int n_calls)
 
static int rp2xxx_flash_auto_probe (struct flash_bank *bank)
 
static int rp2xxx_flash_erase (struct flash_bank *bank, unsigned int first, unsigned int last)
 
static int rp2xxx_flash_probe (struct flash_bank *bank)
 
static int rp2xxx_flash_write (struct flash_bank *bank, const uint8_t *buffer, uint32_t offset, uint32_t count)
 
static int rp2xxx_invalidate_cache_restore_xip (struct target *target, struct rp2xxx_flash_bank *priv)
 
static int rp2xxx_lookup_rom_symbol (struct target *target, uint16_t tag, uint16_t flags, uint16_t *symbol_out)
 
static int rp2xxx_populate_rom_pointer_cache (struct target *target, struct rp2xxx_flash_bank *priv)
 
static int rp2xxx_read_sfdp_block (struct flash_bank *bank, uint32_t addr, unsigned int words, uint32_t *buffer)
 
static int rp2xxx_spi_tx_rx (struct flash_bank *bank, const uint8_t *tx, unsigned int tx_len, unsigned int dummy_len, uint8_t *rx, unsigned int rx_len)
 
static int setup_for_raw_flash_cmd (struct target *target, struct rp2xxx_flash_bank *priv)
 

Variables

static const uint8_t rcp_init_code []
 
static const int rcp_init_code_bkpt_offset = 24
 
static const struct command_registration rp2xxx_command_handler []
 
static const struct command_registration rp2xxx_exec_command_handlers []
 
const struct flash_driver rp2xxx_flash
 
static const uint8_t rp2xxx_rom_call_batch_algo_armv6m [ROM_CALL_BATCH_ALGO_SIZE_BYTES]
 
static const uint8_t rp2xxx_rom_call_batch_algo_armv8m [ROM_CALL_BATCH_ALGO_SIZE_BYTES]
 
static const int rp2xxx_rom_call_batch_algo_bkpt_offset = ROM_CALL_BATCH_ALGO_SIZE_BYTES - 2
 
static const uint8_t rp2xxx_rom_call_batch_algo_riscv [ROM_CALL_BATCH_ALGO_SIZE_BYTES]
 

Macro Definition Documentation

◆ ACCESSCTRL_CFGRESET_OFFSET

#define ACCESSCTRL_CFGRESET_OFFSET   0x40060008u

Definition at line 46 of file rp2xxx.c.

◆ ACCESSCTRL_LOCK_DEBUG_BITS

#define ACCESSCTRL_LOCK_DEBUG_BITS   0x00000008u

Definition at line 45 of file rp2xxx.c.

◆ ACCESSCTRL_LOCK_OFFSET

#define ACCESSCTRL_LOCK_OFFSET   0x40060000u

Definition at line 44 of file rp2xxx.c.

◆ ACCESSCTRL_WRITE_PASSWORD

#define ACCESSCTRL_WRITE_PASSWORD   0xacce0000u

Definition at line 47 of file rp2xxx.c.

◆ BOOTROM_MAGIC_ADDR

#define BOOTROM_MAGIC_ADDR   0x00000010

Definition at line 20 of file rp2xxx.c.

◆ BOOTROM_MAGIC_MASK

#define BOOTROM_MAGIC_MASK   0xffffff

Definition at line 19 of file rp2xxx.c.

◆ BOOTROM_RP2040_MAGIC

#define BOOTROM_RP2040_MAGIC   0x01754d

Definition at line 16 of file rp2xxx.c.

◆ BOOTROM_RP2350_MAGIC

#define BOOTROM_RP2350_MAGIC   0x02754d

Definition at line 18 of file rp2xxx.c.

◆ BOOTROM_STATE_RESET_CURRENT_CORE

#define BOOTROM_STATE_RESET_CURRENT_CORE   0x01

Definition at line 40 of file rp2xxx.c.

◆ BOOTROM_STATE_RESET_GLOBAL_STATE

#define BOOTROM_STATE_RESET_GLOBAL_STATE   0x04

Definition at line 42 of file rp2xxx.c.

◆ BOOTROM_STATE_RESET_OTHER_CORE

#define BOOTROM_STATE_RESET_OTHER_CORE   0x02

Definition at line 41 of file rp2xxx.c.

◆ FUNC_BOOTROM_SET_STACK

#define FUNC_BOOTROM_SET_STACK   MAKE_TAG('S', 'S')

Definition at line 30 of file rp2xxx.c.

◆ FUNC_BOOTROM_STATE_RESET

#define FUNC_BOOTROM_STATE_RESET   MAKE_TAG('S', 'R')

Definition at line 29 of file rp2xxx.c.

◆ FUNC_CONNECT_INTERNAL_FLASH

#define FUNC_CONNECT_INTERNAL_FLASH   MAKE_TAG('I', 'F')

Definition at line 24 of file rp2xxx.c.

◆ FUNC_FLASH_ENTER_CMD_XIP

#define FUNC_FLASH_ENTER_CMD_XIP   MAKE_TAG('C', 'X')

Definition at line 28 of file rp2xxx.c.

◆ FUNC_FLASH_EXIT_XIP

#define FUNC_FLASH_EXIT_XIP   MAKE_TAG('E', 'X')

Definition at line 23 of file rp2xxx.c.

◆ FUNC_FLASH_FLUSH_CACHE

#define FUNC_FLASH_FLUSH_CACHE   MAKE_TAG('F', 'C')

Definition at line 27 of file rp2xxx.c.

◆ FUNC_FLASH_RANGE_ERASE

#define FUNC_FLASH_RANGE_ERASE   MAKE_TAG('R', 'E')

Definition at line 25 of file rp2xxx.c.

◆ FUNC_FLASH_RANGE_PROGRAM

#define FUNC_FLASH_RANGE_PROGRAM   MAKE_TAG('R', 'P')

Definition at line 26 of file rp2xxx.c.

◆ FUNC_FLASH_RESET_ADDRESS_TRANS

#define FUNC_FLASH_RESET_ADDRESS_TRANS   MAKE_TAG('R', 'A')

Definition at line 31 of file rp2xxx.c.

◆ IS_RP2040

Definition at line 70 of file rp2xxx.c.

◆ IS_RP2350

Definition at line 72 of file rp2xxx.c.

◆ LOG_ROM_SYMBOL_DEBUG

#define LOG_ROM_SYMBOL_DEBUG   LOG_DEBUG

Definition at line 215 of file rp2xxx.c.

◆ MAKE_TAG

#define MAKE_TAG (   a,
 
)    (((b)<<8) | a)

Definition at line 22 of file rp2xxx.c.

◆ ROM_CALL_BATCH_ALGO_SIZE_BYTES

#define ROM_CALL_BATCH_ALGO_SIZE_BYTES   32

Definition at line 116 of file rp2xxx.c.

◆ RP2040_CHIP_ID_PART

#define RP2040_CHIP_ID_PART   0x0002

Definition at line 69 of file rp2xxx.c.

◆ RP2040_QSPI_CTRL

#define RP2040_QSPI_CTRL   0x4001800c

Definition at line 50 of file rp2xxx.c.

◆ RP2040_QSPI_CTRL_OUTOVER_HIGH

#define RP2040_QSPI_CTRL_OUTOVER_HIGH   (3ul << 8)

Definition at line 54 of file rp2xxx.c.

◆ RP2040_QSPI_CTRL_OUTOVER_LOW

#define RP2040_QSPI_CTRL_OUTOVER_LOW   (2ul << 8)

Definition at line 53 of file rp2xxx.c.

◆ RP2040_QSPI_CTRL_OUTOVER_MASK

#define RP2040_QSPI_CTRL_OUTOVER_MASK   (3ul << 8)

Definition at line 52 of file rp2xxx.c.

◆ RP2040_SSI_DR0

#define RP2040_SSI_DR0   0x18000060

Definition at line 49 of file rp2xxx.c.

◆ RP2350_CHIP_ID_PART

#define RP2350_CHIP_ID_PART   0x0004

Definition at line 71 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_CSR

#define RP2350_QMI_DIRECT_CSR   0x400d0000

Definition at line 56 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_CSR_ASSERT_CS0N

#define RP2350_QMI_DIRECT_CSR_ASSERT_CS0N   BIT(2)

Definition at line 61 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_CSR_EN

#define RP2350_QMI_DIRECT_CSR_EN   BIT(0)

Definition at line 60 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_RX

#define RP2350_QMI_DIRECT_RX   0x400d0008

Definition at line 58 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_TX

#define RP2350_QMI_DIRECT_TX   0x400d0004

Definition at line 57 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_TX_NOPUSH

#define RP2350_QMI_DIRECT_TX_NOPUSH   BIT(20)

Definition at line 62 of file rp2xxx.c.

◆ RP2350_QMI_DIRECT_TX_OE

#define RP2350_QMI_DIRECT_TX_OE   BIT(19)

Definition at line 63 of file rp2xxx.c.

◆ RP2XXX_CHIP_ID_MANUFACTURER

#define RP2XXX_CHIP_ID_MANUFACTURER   0x493

Definition at line 67 of file rp2xxx.c.

◆ RP2XXX_CHIP_ID_PART_MANUFACTURER

#define RP2XXX_CHIP_ID_PART_MANUFACTURER (   id)    ((id) & 0x0fffffff)

Definition at line 66 of file rp2xxx.c.

◆ RP2XXX_CHIP_ID_REVISION

#define RP2XXX_CHIP_ID_REVISION (   id)    ((id) >> 28)

Definition at line 73 of file rp2xxx.c.

◆ RP2XXX_MAX_ALGO_STACK_USAGE

#define RP2XXX_MAX_ALGO_STACK_USAGE   1024

Definition at line 75 of file rp2xxx.c.

◆ RP2XXX_MAX_RAM_ALGO_SIZE

#define RP2XXX_MAX_RAM_ALGO_SIZE   1024

Definition at line 76 of file rp2xxx.c.

◆ RP2XXX_MK_PART

#define RP2XXX_MK_PART (   part)    (((part) << 12) | (RP2XXX_CHIP_ID_MANUFACTURER << 1) | 1)

Definition at line 68 of file rp2xxx.c.

◆ RP2XXX_ROM_API_FIXED_FLASH_PAGE

#define RP2XXX_ROM_API_FIXED_FLASH_PAGE   256

Definition at line 78 of file rp2xxx.c.

◆ RP2XXX_ROM_API_FIXED_FLASH_SECTOR

#define RP2XXX_ROM_API_FIXED_FLASH_SECTOR   4096

Definition at line 79 of file rp2xxx.c.

◆ RP2XXX_SYSINFO_CHIP_ID

#define RP2XXX_SYSINFO_CHIP_ID   0x40000000

Definition at line 65 of file rp2xxx.c.

◆ RT_FLAG_DATA

#define RT_FLAG_DATA   0x40

Definition at line 37 of file rp2xxx.c.

◆ RT_FLAG_FUNC_ARM_NONSEC

#define RT_FLAG_FUNC_ARM_NONSEC   0x10

Definition at line 36 of file rp2xxx.c.

◆ RT_FLAG_FUNC_ARM_SEC

#define RT_FLAG_FUNC_ARM_SEC   0x04

Definition at line 35 of file rp2xxx.c.

◆ RT_FLAG_FUNC_RISCV

#define RT_FLAG_FUNC_RISCV   0x01

Definition at line 34 of file rp2xxx.c.

Function Documentation

◆ cleanup_after_raw_flash_cmd()

static void cleanup_after_raw_flash_cmd ( struct target target,
struct rp2xxx_flash_bank priv 
)
static

◆ COMMAND_HANDLER() [1/2]

◆ COMMAND_HANDLER() [2/2]

COMMAND_HANDLER ( rp2xxx_switch_target_handler  )

◆ FLASH_BANK_COMMAND_HANDLER()

FLASH_BANK_COMMAND_HANDLER ( rp2xxx_flash_bank_command  )

Definition at line 1285 of file rp2xxx.c.

References bank, ERROR_OK, and priv.

◆ rp2040_lookup_rom_symbol()

static int rp2040_lookup_rom_symbol ( struct target target,
uint16_t  tag,
uint16_t  flags,
uint16_t *  symbol_out 
)
static

◆ rp2040_spi_tx_rx()

static int rp2040_spi_tx_rx ( struct target target,
const uint8_t *  tx,
unsigned int  tx_len,
unsigned int  dummy_len,
uint8_t *  rx,
unsigned int  rx_len 
)
static

◆ rp2040_ssel_active()

static int rp2040_ssel_active ( struct target target,
bool  active 
)
static

◆ rp2350_a0_lookup_symbol()

static int rp2350_a0_lookup_symbol ( struct target target,
uint16_t  tag,
uint16_t  flags,
uint16_t *  symbol_out 
)
static

◆ rp2350_init_accessctrl()

static int rp2350_init_accessctrl ( struct target target)
static

◆ rp2350_init_arm_core0()

◆ rp2350_lookup_rom_symbol()

static int rp2350_lookup_rom_symbol ( struct target target,
uint32_t  ptr_to_entry,
uint16_t  tag,
uint16_t  flags,
uint16_t *  symbol_out 
)
static

◆ rp2350_spi_tx_rx()

static int rp2350_spi_tx_rx ( struct target target,
const uint8_t *  tx,
unsigned int  tx_len,
unsigned int  dummy_len,
uint8_t *  rx,
unsigned int  rx_len 
)
static

◆ rp2xxx_call_rom_func()

static int rp2xxx_call_rom_func ( struct target target,
struct rp2xxx_flash_bank priv,
uint16_t  func_offset,
uint32_t  argdata[],
unsigned int  n_args 
)
static

◆ rp2xxx_call_rom_func_batch()

◆ rp2xxx_flash_auto_probe()

static int rp2xxx_flash_auto_probe ( struct flash_bank bank)
static

Definition at line 1272 of file rp2xxx.c.

References bank, ERROR_OK, priv, and rp2xxx_flash_probe().

Referenced by COMMAND_HANDLER().

◆ rp2xxx_flash_erase()

◆ rp2xxx_flash_probe()

◆ rp2xxx_flash_write()

◆ rp2xxx_invalidate_cache_restore_xip()

static int rp2xxx_invalidate_cache_restore_xip ( struct target target,
struct rp2xxx_flash_bank priv 
)
static

◆ rp2xxx_lookup_rom_symbol()

static int rp2xxx_lookup_rom_symbol ( struct target target,
uint16_t  tag,
uint16_t  flags,
uint16_t *  symbol_out 
)
static

◆ rp2xxx_populate_rom_pointer_cache()

◆ rp2xxx_read_sfdp_block()

static int rp2xxx_read_sfdp_block ( struct flash_bank bank,
uint32_t  addr,
unsigned int  words,
uint32_t *  buffer 
)
static

◆ rp2xxx_spi_tx_rx()

static int rp2xxx_spi_tx_rx ( struct flash_bank bank,
const uint8_t *  tx,
unsigned int  tx_len,
unsigned int  dummy_len,
uint8_t *  rx,
unsigned int  rx_len 
)
static

◆ setup_for_raw_flash_cmd()

Variable Documentation

◆ rcp_init_code

const uint8_t rcp_init_code[]
static
Initial value:
= {
0x06, 0x48,
0x5f, 0xf4, 0x40, 0x41,
0x01, 0x60,
0x30, 0xee, 0x10, 0xf7,
0x04, 0xd4,
0x40, 0xec, 0x80, 0x07,
0x40, 0xec, 0x81, 0x07,
0x40, 0xbf,
0x00, 0xbe,
0x00, 0x00,
0x88, 0xed, 0x00, 0xe0
}

Definition at line 93 of file rp2xxx.c.

Referenced by rp2350_init_arm_core0().

◆ rcp_init_code_bkpt_offset

const int rcp_init_code_bkpt_offset = 24
static

Definition at line 92 of file rp2xxx.c.

Referenced by rp2350_init_arm_core0().

◆ rp2xxx_command_handler

const struct command_registration rp2xxx_command_handler[]
static
Initial value:
= {
{
.name = "rp2xxx",
.mode = COMMAND_ANY,
.help = "rp2xxx flash controller commands",
.usage = "",
},
}
#define COMMAND_REGISTRATION_DONE
Use this as the last entry in an array of command_registration records.
Definition: command.h:253
@ COMMAND_ANY
Definition: command.h:42
static const struct command_registration rp2xxx_exec_command_handlers[]
Definition: rp2xxx.c:1402

Definition at line 1366 of file rp2xxx.c.

◆ rp2xxx_exec_command_handlers

const struct command_registration rp2xxx_exec_command_handlers[]
static
Initial value:
= {
{
.name = "rom_api_call",
.mode = COMMAND_EXEC,
.help = "arbitrary ROM API call",
.usage = "fc [p0 [p1 [p2 [p3]]]]",
.handler = rp2xxx_rom_api_call_handler,
},
{
.name = "_switch_target",
.mode = COMMAND_EXEC,
.help = "internal use",
.usage = "old_target new_target",
.handler = rp2xxx_switch_target_handler,
},
}
@ COMMAND_EXEC
Definition: command.h:40

Definition at line 1366 of file rp2xxx.c.

◆ rp2xxx_flash

const struct flash_driver rp2xxx_flash
Initial value:
= {
.name = "rp2xxx",
.flash_bank_command = rp2xxx_flash_bank_command,
.auto_probe = rp2xxx_flash_auto_probe,
.erase_check = default_flash_blank_check,
.free_driver_priv = default_flash_free_driver_priv
}
int default_flash_blank_check(struct flash_bank *bank)
Provides default erased-bank check handling.
int default_flash_read(struct flash_bank *bank, uint8_t *buffer, uint32_t offset, uint32_t count)
Provides default read implementation for flash memory.
void default_flash_free_driver_priv(struct flash_bank *bank)
Deallocates bank->driver_priv.
static const struct command_registration rp2xxx_command_handler[]
Definition: rp2xxx.c:1420
static int rp2xxx_flash_probe(struct flash_bank *bank)
Definition: rp2xxx.c:1176
static int rp2xxx_flash_auto_probe(struct flash_bank *bank)
Definition: rp2xxx.c:1272
static int rp2xxx_flash_write(struct flash_bank *bank, const uint8_t *buffer, uint32_t offset, uint32_t count)
Definition: rp2xxx.c:853
static int rp2xxx_flash_erase(struct flash_bank *bank, unsigned int first, unsigned int last)
Definition: rp2xxx.c:920

Definition at line 1366 of file rp2xxx.c.

Referenced by COMMAND_HANDLER().

◆ rp2xxx_rom_call_batch_algo_armv6m

const uint8_t rp2xxx_rom_call_batch_algo_armv6m[ROM_CALL_BATCH_ALGO_SIZE_BYTES]
static
Initial value:
= {
0x07, 0xa7,
0x10, 0xcf,
0x00, 0x2c,
0x0a, 0xd0,
0x20, 0xcf,
0xad, 0x46,
0x0f, 0xcf,
0xa0, 0x47,
0xf7, 0xe7,
0xc0, 0x46,
0xc0, 0x46,
0xc0, 0x46,
0xc0, 0x46,
0xc0, 0x46,
0xc0, 0x46,
0x00, 0xbe,
}

Definition at line 118 of file rp2xxx.c.

Referenced by rp2xxx_call_rom_func_batch().

◆ rp2xxx_rom_call_batch_algo_armv8m

const uint8_t rp2xxx_rom_call_batch_algo_armv8m[ROM_CALL_BATCH_ALGO_SIZE_BYTES]
static
Initial value:
= {
0x07, 0xa7,
0x00, 0x20,
0x80, 0xf3, 0x0a, 0x88,
0x80, 0xf3, 0x0b, 0x88,
0x10, 0xcf,
0x00, 0x2c,
0x05, 0xd0,
0x20, 0xcf,
0xad, 0x46,
0x0f, 0xcf,
0xa0, 0x47,
0xf7, 0xe7,
0xc0, 0x46,
0x00, 0xbe,
}

Definition at line 142 of file rp2xxx.c.

Referenced by rp2xxx_call_rom_func_batch().

◆ rp2xxx_rom_call_batch_algo_bkpt_offset

const int rp2xxx_rom_call_batch_algo_bkpt_offset = ROM_CALL_BATCH_ALGO_SIZE_BYTES - 2
static

Definition at line 117 of file rp2xxx.c.

Referenced by rp2xxx_call_rom_func_batch().

◆ rp2xxx_rom_call_batch_algo_riscv

const uint8_t rp2xxx_rom_call_batch_algo_riscv[ROM_CALL_BATCH_ALGO_SIZE_BYTES]
static
Initial value:
= {
0x97, 0x04, 0x00, 0x00,
0x93, 0x84, 0x04, 0x02,
0x98, 0x40,
0x11, 0xcb,
0x03, 0xa1, 0x44, 0x00,
0x88, 0x44,
0xcc, 0x44,
0x90, 0x48,
0xd4, 0x48,
0xe1, 0x04,
0x02, 0x97,
0xf5, 0xb7,
0x02, 0x90,
}

Definition at line 164 of file rp2xxx.c.

Referenced by rp2xxx_call_rom_func_batch().