blob: a05c2250825e85e9df5253167ed675b1f5e8e08c [file] [log] [blame]
// Copyright 2019 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.sysmem;
using zx;
@transport("Banjo")
@banjo_layout("ddk-protocol")
protocol Sysmem {
/// Takes the server end of a FIDL connection that'll serve
/// fuchsia.sysmem.Allocator. If the connection fails, the channel will
/// close.
Connect(resource struct {
allocator_request zx.handle:CHANNEL;
}) -> (struct {
s zx.status;
});
/// Takes the client end of a FIDL connection that'll serve
/// fuchsia.sysmem.Heap.
RegisterHeap(resource struct {
heap uint64;
heap_connection zx.handle:CHANNEL;
}) -> (struct {
s zx.status;
});
/// Takes the client end of a FIDL connection that'll serve
/// fuchsia.sysmem.SecureMem, which is a protocol that's specific to
/// sysmem<->securemem concerns.
RegisterSecureMem(resource struct {
secure_mem_connection zx.handle:CHANNEL;
}) -> (struct {
s zx.status;
});
/// Informs sysmem that the channel previously passed to RegisterSecureMem()
/// will be closing soon, and that this channel closure should not be
/// considered an error.
UnregisterSecureMem() -> (struct {
s zx.status;
});
};