blob: 6663fcaa55c081c9c1c0f82fe5b404b3db10704c [file] [log] [blame]
/*
* Copyright 2023 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef EXAMPLES_SOUNDSTREAM_MBOX_H_
#define EXAMPLES_SOUNDSTREAM_MBOX_H_
#include <compartment.h>
#include "sw/device/lib/dif/dif_tlul_mailbox.h"
typedef dif_tlul_mailbox_irq_t mailbox_irq_t;
const mailbox_irq_t kMboxIrqRtIrq = kDifTlulMailboxIrqRtirq;
void __cheri_compartment("mailbox") mailbox_init(void);
void __cheri_compartment("mailbox") mailbox_isr(void);
bool __cheri_compartment("mailbox") mailbox_button_pressed(void);
// XXX temp
void __cheri_compartment("mailbox") mailbox_set_button_pressed(bool);
void __cheri_compartment("mailbox") mailbox_set_led(bool enabled);
#endif // EXAMPLES_SOUNDSTREAM_MBOX_H_