2
0
Forkuj 0
genodepkgs/nixos-modules/dhall/graphical-log.dhall

107 wiersze
3.2 KiB
Plaintext

let Genode = env:DHALL_GENODE
let Prelude = Genode.Prelude
let XML = Prelude.XML
let Init = Genode.Init
let Child = Init.Child
let Resources = Init.Resources
let ServiceRoute = Init.ServiceRoute
let routeLogRom =
λ(label : Text) → ServiceRoute.parentLabel "ROM" (Some "log") (Some label)
in Init::{
, verbose = True
, routes =
Prelude.List.map
Text
Init.ServiceRoute.Type
Init.ServiceRoute.parent
[ "Nitpicker", "Rtc", "Timer" ]
, children = toMap
{ nit_fb =
Child.flat
Child.Attributes::{
, binary = "nit_fb"
, config = Init.Config::{
, attributes = toMap
{ initial_width = "600", initial_height = "600" }
}
, exitPropagate = True
, provides = [ "Framebuffer", "Input" ]
, resources = Resources::{ ram = Genode.units.MiB 8 }
}
, terminal =
Child.flat
Child.Attributes::{
, binary = "terminal"
, config = Init.Config::{
, content =
[ XML.element
{ name = "vfs"
, attributes = XML.emptyAttributes
, content =
[ XML.element
{ name = "dir"
, attributes = toMap { name = "fonts" }
, content =
[ XML.leaf
{ name = "fs"
, attributes = toMap { label = "fonts" }
}
]
}
]
}
]
}
, provides = [ "Terminal" ]
, resources = Resources::{ caps = 256, ram = Genode.units.MiB 4 }
, routes =
[ ServiceRoute.child "Framebuffer" "nit_fb"
, ServiceRoute.child "Input" "nit_fb"
, ServiceRoute.parent "File_system"
]
}
, terminal_log =
Child.flat
Child.Attributes::{
, binary = "terminal_log"
, provides = [ "LOG" ]
, routes = [ ServiceRoute.child "Terminal" "terminal" ]
}
, log_core =
Child.flat
Child.Attributes::{
, binary = "log_core"
, routes =
[ routeLogRom "core_log"
, ServiceRoute.childLabel
"LOG"
"terminal_log"
(Some "log")
(Some "core")
]
}
, log_kernel =
Child.flat
Child.Attributes::{
, binary = "log_core"
, routes =
[ routeLogRom "kernel_log"
, ServiceRoute.childLabel
"LOG"
"terminal_log"
(Some "log")
(Some "kernel")
]
}
}
}