blob: 50987cd9e819fe1482295a9e7f7b951a3e68cf17 [file] [log] [blame]
{
children: [
{
name: "archivist",
url: "fuchsia-boot:///#meta/archivist.cm",
},
{
name: "device_name_provider",
url: "fuchsia-boot:///#meta/device-name-provider.cm",
},
{
name: "driver_manager",
url: "fuchsia-boot:///#meta/driver_manager.cm",
environment: "#driver_manager-env",
},
{
name: "fshost",
url: "fuchsia-boot:///#meta/fshost.cm",
environment: "#fshost-env",
},
{
name: "console",
url: "fuchsia-boot:///#meta/console.cm",
},
{
name: "console-launcher",
url: "fuchsia-boot:///#meta/console-launcher.cm",
startup: "eager",
},
{
name: "miscsvc",
url: "fuchsia-boot:///#meta/miscsvc.cm",
},
{
name: "netsvc",
url: "fuchsia-boot:///#meta/netsvc.cm",
startup: "eager",
},
{
name: "ptysvc",
url: "fuchsia-boot:///#meta/ptysvc.cm",
},
{
name: "pwrbtn-monitor",
url: "fuchsia-boot:///#meta/pwrbtn-monitor.cm",
// pwrbtn-monitor only consumes capabilities, it doesn't provide
// any, so there's no other way to start it.
startup: "eager",
},
{
name: "shutdown_shim",
url: "fuchsia-boot:///#meta/shutdown-shim.cm",
},
{
name: "sysinfo",
url: "fuchsia-boot:///#meta/sysinfo.cm",
},
{
name: "power_manager",
url: "fuchsia-pkg://fuchsia.com/power_manager#meta/power_manager.cm",
},
],
offer: [
{
protocol: [
"fuchsia.boot.Arguments",
"fuchsia.boot.FactoryItems",
"fuchsia.boot.Items",
"fuchsia.boot.ReadOnlyLog",
"fuchsia.boot.RootJob",
"fuchsia.boot.RootJobForInspect",
"fuchsia.boot.RootResource",
"fuchsia.boot.WriteOnlyLog",
"fuchsia.cobalt.LoggerFactory",
"fuchsia.exception.Handler",
"fuchsia.kernel.RootJob",
"fuchsia.kernel.RootJobForInspect",
"fuchsia.kernel.Stats",
"fuchsia.net.NameLookup",
"fuchsia.net.stack.Log",
"fuchsia.net.stack.Stack",
"fuchsia.netstack.Netstack",
"fuchsia.pkg.PackageResolver",
"fuchsia.pkg.RepositoryManager",
"fuchsia.pkg.rewrite.Engine",
"fuchsia.posix.socket.Provider",
"fuchsia.process.Launcher",
"fuchsia.process.Resolver",
"fuchsia.sys.Environment",
"fuchsia.sys.Launcher",
"fuchsia.sys.Loader",
"fuchsia.tracing.controller.Controller",
"fuchsia.tracing.provider.Registry",
"fuchsia.wlan.service.Wlan",
],
from: "parent",
to: [
"#console-launcher",
"#netsvc",
],
},
{
directory: "boot",
from: "parent",
to: [
"#console-launcher",
"#driver_manager",
"#fshost",
"#miscsvc",
"#netsvc",
],
rights: [ "rx*" ],
},
{
protocol: [
"fuchsia.boot.FactoryItems",
"fuchsia.boot.ReadOnlyLog",
"fuchsia.kernel.RootJob",
"fuchsia.kernel.RootJobForInspect",
],
from: "parent",
to: [ "#driver_manager" ],
},
{
protocol: [ "fuchsia.power.manager.DriverManagerRegistration" ],
from: "#power_manager",
to: [ "#driver_manager" ],
},
{
protocol: [ "fuchsia.kernel.Stats" ],
from: "parent",
to: [
"#driver_manager",
"#power_manager",
],
},
{
protocol: "fuchsia.boot.RootResource",
from: "parent",
to: [
"#console",
"#driver_manager",
"#sysinfo",
],
},
{
protocol: [
"fuchsia.boot.Arguments",
"fuchsia.boot.Items",
"fuchsia.process.Launcher",
],
from: "parent",
to: [
"#driver_manager",
"#fshost",
],
},
{
protocol: [
"fuchsia.boot.Arguments",
"fuchsia.boot.WriteOnlyLog",
"fuchsia.process.Launcher",
],
from: "parent",
to: [ "#miscsvc" ],
},
{
protocol: [
"fuchsia.boot.Arguments",
"fuchsia.boot.WriteOnlyLog",
],
from: "parent",
to: [ "#device_name_provider" ],
},
{
protocol: [ "fuchsia.boot.WriteOnlyLog" ],
from: "parent",
to: [
"#console",
"#driver_manager",
"#fshost",
"#power_manager",
"#ptysvc",
"#pwrbtn-monitor",
"#shutdown_shim",
"#sysinfo",
],
},
{
protocol: [
"fuchsia.cobalt.LoggerFactory",
"fuchsia.tracing.provider.Registry",
],
from: "parent",
to: [
"#driver_manager",
"#fshost",
"#power_manager",
],
},
{
protocol: [ "fuchsia.security.resource.Vmex" ],
from: "parent",
to: [ "#fshost" ],
},
{
protocol: [ "fuchsia.scheduler.ProfileProvider" ],
from: "#driver_manager",
to: [ "#fshost" ],
},
{
// TODO(fxbug.dev/34633): DEPRECATED. Do not add new dependencies on the fshost
// loader service!
protocol: "fuchsia.fshost.Loader",
from: "#fshost",
to: [ "#driver_manager" ],
dependency: "weak_for_migration",
},
{
protocol: [
"fuchsia.device.manager.Administrator",
"fuchsia.device.manager.BindDebugger",
"fuchsia.device.manager.DebugDumper",
"fuchsia.kernel.DebugBroker",
"fuchsia.kernel.MexecBroker",
"fuchsia.scheduler.ProfileProvider",
"fuchsia.sysmem.Allocator",
"fuchsia.tracing.kernel.Controller",
"fuchsia.virtualconsole.SessionManager",
],
from: "#driver_manager",
to: [
"#console-launcher",
"#netsvc",
],
},
{
directory: "dev",
from: "#driver_manager",
to: [
"#console-launcher",
"#device_name_provider",
"#fshost",
"#miscsvc",
"#netsvc",
"#sysinfo",
],
},
{
directory: "minfs",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "pkgfs",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "system-delayed",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "system",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "blob",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "install",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "durable",
from: "#fshost",
to: [ "#driver_manager" ],
dependency: "weak_for_migration",
},
{
directory: "factory",
from: "#fshost",
to: [ "#driver_manager" ],
dependency: "weak_for_migration",
},
{
directory: "tmp",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "bin",
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
directory: "volume",
from: "#fshost",
to: [ "#miscsvc" ],
},
// Offer the log services to the console
{
protocol: [ "fuchsia.logger.Log" ],
from: "#archivist",
to: [ "#console" ],
},
// Offer power_manager's config data to it, so it can read its config
{
directory: "config-data",
from: "#fshost",
to: [ "#power_manager" ],
subdir: "power_manager",
dependency: "weak_for_migration",
},
// Offer the kernel serial console to the driver_manager
{
protocol: "fuchsia.hardware.pty.Device",
from: "#console",
as: "console",
to: [
"#console-launcher",
"#driver_manager",
],
},
{
protocol: "fuchsia.device.NameProvider",
from: "#device_name_provider",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
// TODO: Once svchost is spawned by component manager, we can
// remove this.
dependency: "weak_for_migration",
},
// Offer the misc service to the driver_manager
{
protocol: [
"fuchsia.kernel.Counter",
"fuchsia.paver.Paver",
],
from: "#miscsvc",
to: [ "#driver_manager" ],
// TODO: Once netsvc is spawned by component manager, we can remove this.
dependency: "weak_for_migration",
},
// Offer the pty service to the driver_manager
{
protocol: "fuchsia.hardware.pty.Device",
from: "#ptysvc",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
},
// driver_manager needs the v1 hub for the serial console
{
directory: "hub",
from: "parent",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
},
{
protocol: "fuchsia.sysinfo.SysInfo",
from: "#sysinfo",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
protocol: "fuchsia.hardware.power.statecontrol.Admin",
from: "#shutdown_shim",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
"#pwrbtn-monitor",
],
},
// Things shutdown_shim and power_manager need
{
protocol: [ "fuchsia.sys2.SystemController" ],
from: "parent",
to: [
"#power_manager",
"#shutdown_shim",
],
},
{
protocol: [ "fuchsia.device.manager.SystemStateTransition" ],
from: "#driver_manager",
to: [ "#shutdown_shim" ],
dependency: "weak_for_migration",
},
{
protocol: [ "fuchsia.hardware.power.statecontrol.Admin" ],
from: "#power_manager",
to: [ "#shutdown_shim" ],
},
{
protocol: [ "fuchsia.device.manager.Administrator" ],
from: "#driver_manager",
to: [ "#power_manager" ],
dependency: "weak_for_migration",
},
{
protocol: [ "fuchsia.feedback.CrashReporter" ],
from: "parent",
to: [ "#power_manager" ],
},
{
protocol: [
"fuchsia.kernel.Counter",
"fuchsia.paver.Paver",
],
from: "#miscsvc",
to: [
"#console-launcher",
"#netsvc",
],
},
// Non-zircon services for svchost
{
protocol: [
"fuchsia.exception.Handler",
"fuchsia.net.NameLookup",
"fuchsia.net.stack.Log",
"fuchsia.net.stack.Stack",
"fuchsia.netstack.Netstack",
"fuchsia.pkg.PackageResolver",
"fuchsia.pkg.RepositoryManager",
"fuchsia.pkg.rewrite.Engine",
"fuchsia.posix.socket.Provider",
"fuchsia.process.Resolver",
"fuchsia.sys.Environment",
"fuchsia.sys.Launcher",
"fuchsia.tracing.controller.Controller",
"fuchsia.wlan.service.Wlan",
],
from: "parent",
to: [ "#driver_manager" ],
},
{
protocol: "fuchsia.logger.Log",
from: "#archivist",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
},
{
protocol: [ "fuchsia.logger.LogSink" ],
from: "#archivist",
to: [
"#console-launcher",
"#driver_manager",
"#fshost",
"#netsvc",
],
},
{
protocol: [
"fuchsia.fshost.BlockWatcher",
"fuchsia.fshost.Filesystems",
"fuchsia.fshost.Registry",
],
from: "#fshost",
to: [
"#console-launcher",
"#driver_manager",
"#netsvc",
],
dependency: "weak_for_migration",
},
{
protocol: [ "fuchsia.fshost.Admin" ],
from: "#fshost",
to: [ "#driver_manager" ],
dependency: "weak_for_migration",
},
{
directory: "dev",
from: "#driver_manager",
as: "input",
to: [ "#pwrbtn-monitor" ],
subdir: "class/input",
},
{
protocol: [
"fuchsia.fshost.BlockWatcher",
"fuchsia.fshost.Registry",
],
from: "#fshost",
to: [ "#miscsvc" ],
},
// -- Archivist offers below here --
// Required events
{
event: [
"running",
"started",
"stopped",
],
from: "parent",
to: [ "#archivist" ],
},
{
event: "capability_ready",
from: "parent",
to: [ "#archivist" ],
filter: { path: "diagnostics" },
},
// Required services
{
protocol: [
"fuchsia.boot.ReadOnlyLog",
"fuchsia.sys2.EventSource",
],
from: "parent",
to: [ "#archivist" ],
},
// Weak services from appmgr and log-stats
{
protocol: [
"fuchsia.diagnostics.internal.LogStatsController",
"fuchsia.sys.internal.ComponentEventProvider",
"fuchsia.sys.internal.LogConnector",
],
from: "parent",
to: [ "#archivist" ],
dependency: "weak_for_migration",
},
// Configuration
{
directory: "boot",
from: "parent",
as: "config-data",
to: [ "#archivist" ],
rights: [ "r*" ],
subdir: "config/archivist",
},
// -- End Archivist offers --
],
expose: [
// This handle is used by component manager to resolve packages from the
// base package set.
{
directory: "pkgfs-delayed",
from: "#fshost",
},
{
directory: "dev",
from: "#driver_manager",
},
{
directory: "config-data",
from: "#fshost",
},
{
directory: "factory",
from: "#fshost",
},
{
directory: "durable",
from: "#fshost",
},
{
directory: "minfs",
from: "#fshost",
},
{
directory: "pkgfs",
from: "#fshost",
},
{
directory: "system",
from: "#fshost",
},
{
directory: "blob",
from: "#fshost",
},
{
directory: "tmp",
from: "#fshost",
},
{
directory: "bin",
from: "#fshost",
},
{
protocol: "fuchsia.device.NameProvider",
from: "#device_name_provider",
},
{
protocol: [
"fuchsia.device.manager.Administrator",
"fuchsia.device.manager.BindDebugger",
"fuchsia.device.manager.DebugDumper",
"fuchsia.kernel.DebugBroker",
"fuchsia.scheduler.ProfileProvider",
"fuchsia.tracing.kernel.Controller",
"fuchsia.tracing.kernel.Reader",
"fuchsia.virtualconsole.SessionManager",
],
from: "#driver_manager",
},
{
protocol: "fuchsia.hardware.power.statecontrol.Admin",
from: "#shutdown_shim",
},
{
protocol: "fuchsia.hardware.pty.Device",
from: "#ptysvc",
},
{
protocol: [
"fuchsia.kernel.Counter",
"fuchsia.paver.Paver",
],
from: "#miscsvc",
},
{
protocol: "fuchsia.sysinfo.SysInfo",
from: "#sysinfo",
},
{
protocol: [
"fuchsia.hardware.power.statecontrol.RebootMethodsWatcherRegister",
"fuchsia.thermal.Controller",
],
from: "#power_manager",
},
{
protocol: [
"fuchsia.diagnostics.ArchiveAccessor",
"fuchsia.diagnostics.FeedbackArchiveAccessor",
"fuchsia.diagnostics.LegacyMetricsArchiveAccessor",
"fuchsia.logger.Log",
"fuchsia.logger.LogSink",
],
from: "#archivist",
},
],
environments: [
{
name: "fshost-env",
extends: "realm",
// 20 minutes
__stop_timeout_ms: 1200000,
},
{
name: "driver_manager-env",
extends: "realm",
// 1 minute
__stop_timeout_ms: 60000,
},
],
}