-
Notifications
You must be signed in to change notification settings - Fork 17
Expand file tree
/
Copy pathrp-multicore.ads
More file actions
36 lines (30 loc) · 956 Bytes
/
Copy pathrp-multicore.ads
File metadata and controls
36 lines (30 loc) · 956 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
--
-- Copyright (C) 2022 Fabien Chouteau <fabien.chouteau@gmail.com>
--
-- SPDX-License-Identifier: BSD-3-Clause
--
with System;
with HAL; use HAL;
package RP.Multicore
with Preelaborate
is
procedure Reset_Core1;
-- hard reset core1
procedure Launch_Core1
(Trap_Vector : HAL.UInt32;
Stack_Pointer : HAL.UInt32;
Entry_Point : HAL.UInt32)
with Pre => Trap_Vector /= 0 and then
Stack_Pointer /= 0 and then
Entry_Point /= 0;
-- Start core 1 (the second CPU of the RP2040) to execute code at
-- Entry_Point with the stack pointer set to Stack_Pointer and trap vector
-- base set to Trap_Vector.
procedure Launch_Core1
(Trap_Vector : System.Address;
Stack_Pointer : System.Address;
Entry_Point : System.Address);
function CPU_Id
return Natural;
-- Returns the Id of the CPU we're currently executing on.
end RP.Multicore;