blob: 1ded689ad663087a92ff4f301d56e080b524ecd8 [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.boot;
/// Protocol for retrieving factory boot item payloads.
[Discoverable, Layout = "Simple"]
protocol FactoryItems {
/// Gets a `payload` for a ZBI_TYPE_STORAGE_BOOTFS_FACTORY boot item with
/// extra field set to `extra`.
///
/// This method vends `payload` at most once for each `extra` for the
/// lifetime of the service that implements this protocol. On subsequent
/// calls, `payload` will be ZX_HANDLE_INVALID and `length` will be 0.
///
/// NOTE: We return the `length` of the item, as VMOs must be page-aligned.
Get(uint32 extra) -> (handle<vmo>? payload, uint32 length);
};