blob: 5f6ed9ba7db23577becb6590cb84d913ed9c9b10 [file] [log] [blame]
// Copyright 2018 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
library fuchsia.hardware.mailbox;
using zx;
// Mailboxes
enum MailboxType : uint8 {
SCP_SECURE_MAILBOX = 0x0;
SCP_NS_LOW_PRIORITY_MAILBOX = 0x1;
SCP_NS_HIGH_PRIORITY_MAILBOX = 0x2;
AP_SECURE_MAILBOX = 0x3;
AP_NS_LOW_PRIORITY_MAILBOX = 0x4;
AP_NS_HIGH_PRIORITY_MAILBOX = 0x5;
INVALID_MAILBOX = 0x6;
};
struct MailboxDataBuf {
uint32 cmd;
[Buffer] vector<uint8> tx;
};
struct MailboxChannel {
MailboxType mailbox;
[Buffer] vector<uint8> rx;
};
[Transport = "Banjo", BanjoLayout = "ddk-protocol"]
protocol Mailbox {
SendCommand(MailboxChannel channel, MailboxDataBuf mdata) -> (zx.status s);
};