genode/repos/ports-foc/run/l4linux_ahci_bench.run
Norman Feske 5a1cef6381 Make label prefixing more strict
This patch unconditionally applies the labeling of sessions and thereby
removes the most common use case of 'Child_policy::filter_session_args'.
Furthermore, the patch removes an ambiguity of the session labels of
sessions created by the parent of behalf of its child, e.g., the PD
session created as part of 'Child' now has the label "<child-name>"
whereas an unlabeled PD-session request originating from the child
has the label "<child-name> -> ". This way, the routing-policy of
'Child_policy::resolve_session_request' can differentiate both cases.

As a consequence, the stricter labeling must now be considered wherever
a precise label was specified as a key for a session route or a server-
side policy selection. The simplest way to adapt those cases is to use a
'label_prefix' instead of the 'label' attribute. Alternatively, the
'label' attribute may used by appending " -> " (note the whitespace).

Fixes #2171
2016-11-30 13:37:07 +01:00

139 lines
2.7 KiB
Plaintext

#
# settings
#
set interpose_part_blk 0
assert_spec foc
assert_spec arndale
#
# build
#
set build_components {
core
init
drivers/timer
drivers/uart
drivers/ahci
drivers/platform
l4linux
}
lappend_if $interpose_part_blk build_components server/part_blk
build $build_components
create_boot_directory
#
# genode config
#
set config {
<config prio_levels="2">
<parent-provides>
<service name="ROM"/>
<service name="RAM"/>
<service name="IRQ"/>
<service name="IO_MEM"/>
<service name="IO_PORT"/>
<service name="PD"/>
<service name="RM"/>
<service name="CPU"/>
<service name="LOG"/>
</parent-provides>
<default-route>
<any-service><parent/><any-child/></any-service>
</default-route>
<start name="timer">
<resource name="RAM" quantum="1M"/>
<provides><service name="Timer"/></provides>
</start>
<start name="kdb_uart_drv">
<resource name="RAM" quantum="1M"/>
<provides>
<service name="Terminal"/>
<service name="Uart"/>
</provides>
<config><policy label_prefix="l4linux" uart="0" detect_size="yes"/></config>
</start>
<start name="ahci_drv">
<resource name="RAM" quantum="1M"/>
<provides><service name="Block"/></provides>
</start>
<start name="platform_drv">
<resource name="RAM" quantum="1M"/>
<provides><service name="Regulator"/></provides>
</start> }
append_if $interpose_part_blk config {
<start name="part_blk">
<resource name="RAM" quantum="10M" />
<provides><service name="Block" /></provides>
<route>
<service name="Block"><child name="ahci" /></service>
<any-service><parent/><any-child/></any-service>
</route>
<config>
<policy label="l4linux -> sda" partition="0"/>
</config>
</start> }
append config {
<start name="l4linux">
<resource name="RAM" quantum="200M"/>
<config args="mem=100M console=ttyS0 l4x_rd=initrd.gz l4x_cpus=2 l4x_cpus_map=0,1">
<block label="sda" />
</config> }
append_if $interpose_part_blk config {
<route>
<service name="Block"><child name="part_blk" /></service>
<any-service><parent/><any-child/></any-service>
</route> }
append config {
</start>
</config> }
install_config $config
#
# boot modules
#
set boot_modules {
core
init
timer
kdb_uart_drv
l4linux
initrd.gz
ahci_drv
platform_drv }
lappend_if $interpose_part_blk boot_modules part_blk
set uri "http://genode.org/files/l4linux/initrd-ahci-bench.gz"
if {![file exists bin/initrd.gz]} {
puts "Download initramfs ..."
exec >& /dev/null wget -c -O bin/initrd.gz $uri
}
exec >& /dev/null wget -O bin/initrd.gz.md5 $uri.md5
cd bin
exec md5sum -c initrd.gz.md5
cd ..
set fiasco_serial_esc_arg ""
build_boot_image [join $boot_modules " "]
#
# qemu
#
append qemu_args " -m 512 -nographic "
#
# execute test
#
run_genode_until forever