blob: 49a680e7f283ab1b2e1e7091ed1a70d77e3fff6f [file]
// Licensed under the Apache-2.0 license
// Virtual AST1060-EVB SPDM Requester-Responder Test Configuration (QEMU)
// ARM Cortex-M4 with semihosting console
// PMSAv7 power-of-2 alignment constraint.`
//
// Four-process system for testing SPDM requester/responder communication:
// 1. mctp_loopback_server - Routes MCTP messages between requester and responder
// 2. spdm_requester - SPDM requester using spdm-lib requester API
// 3. spdm_responder - SPDM responder using spdm-lib responder API
// 4. crypto_server - Crypto service (RustCrypto backend)
//
// Memory Layout (PMSAv7-friendly, power-of-2 aligned regions):
// 0x00000000 - 0x00000500: Vector table + kernel annotations (1280 bytes)
// 0x00000500 - 0x00010000: Kernel flash (~62KB)
// 0x00010000 - 0x00018000: mctp_loopback_server flash (32KB)
// 0x00018000 - 0x00020000: spdm_requester flash (32KB)
// 0x00020000 - 0x00028000: spdm_responder flash (32KB)
// 0x00028000 - 0x00038000: crypto_server flash (64KB)
// 0x00058000 - 0x00070000: Kernel RAM (96KB)
// 0x00070000 - 0x00078000: mctp_loopback_server RAM (32KB)
// 0x00078000 - 0x00080000: spdm_requester RAM (32KB)
// 0x00080000 - 0x00090000: spdm_responder RAM (64KB)
// 0x00090000 - 0x000A0000: crypto_server RAM (64KB)
//
// Total: 0xA0000 = 640KB (fits within the 640KB usable window of the AST1060's 640KB SRAM).
{
arch: {
type: "armv7m",
vector_table_start_address: 0x00000000,
vector_table_size_bytes: 1280,
},
kernel: {
flash_start_address: 0x00000500,
flash_size_bytes: 64256, // ~62KB, ends at 0x10000
ram_start_address: 0x00058000,
ram_size_bytes: 98304, // 96KB
},
apps: [
// ──── MCTP Loopback Server ────
{
name: "mctp_loopback_server",
flash_size_bytes: 32768,
ram_size_bytes: 32768,
processes: [
{
name: "mctp loopback server process",
objects: [
{
name: "MCTP_REQ",
type: "channel_handler",
},
{
name: "MCTP_RESP",
type: "channel_handler",
},
{
name: "WG",
type: "wait_group",
},
],
threads: [
{
name: "mctp loopback server thread",
stack_size_bytes: 4096,
},
],
},
],
},
// ──── SPDM Requester ────
{
name: "spdm_requester",
flash_size_bytes: 32768, // 32KB (actual ~16KB)
ram_size_bytes: 32768, // 32KB (stack 16KB + buffers)
processes: [
{
name: "spdm requester process",
objects: [
{
name: "MCTP",
type: "channel_initiator",
handler_process: "mctp loopback server process",
handler_object_name: "MCTP_REQ",
},
{
name: "CRYPTO",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_REQ",
},
{
name: "CRYPTO_M1",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_REQ_M1",
},
{
name: "CRYPTO_L1",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_REQ_L1",
},
],
threads: [
{
name: "spdm requester thread",
stack_size_bytes: 16384,
},
],
},
],
},
// ──── SPDM Responder ────
{
name: "spdm_responder",
flash_size_bytes: 32768, // 32KB (actual ~23KB)
ram_size_bytes: 65536,
processes: [
{
name: "spdm responder process",
objects: [
{
name: "MCTP",
type: "channel_initiator",
handler_process: "mctp loopback server process",
handler_object_name: "MCTP_RESP",
},
{
name: "CRYPTO",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_RESP",
},
{
name: "CRYPTO_M1",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_RESP_M1",
},
{
name: "CRYPTO_L1",
type: "channel_initiator",
handler_process: "crypto_server_process",
handler_object_name: "CRYPTO_RESP_L1",
},
],
threads: [
{
name: "spdm responder thread",
stack_size_bytes: 16384,
},
],
},
],
},
// ──── Crypto Server ────
{
name: "crypto_server",
flash_size_bytes: 65536, // 64KB (RustCrypto backend)
ram_size_bytes: 65536, // 64KB RAM for crypto contexts
processes: [
{
name: "crypto_server_process",
objects: [
{ name: "CRYPTO_REQ", type: "channel_handler" },
{ name: "CRYPTO_REQ_M1", type: "channel_handler" },
{ name: "CRYPTO_REQ_L1", type: "channel_handler" },
{ name: "CRYPTO_RESP", type: "channel_handler" },
{ name: "CRYPTO_RESP_M1", type: "channel_handler" },
{ name: "CRYPTO_RESP_L1", type: "channel_handler" },
{ name: "WG", type: "wait_group" },
],
threads: [
{
name: "crypto_server_thread",
stack_size_bytes: 8192,
},
],
},
],
},
],
}