Browse Source

cached_fs_rom: session diagnostics

ncurses
Emery Hemingway 2 years ago
parent
commit
c1457bf140
  1. 31
      packages/genodelabs/cached_fs_rom.patch
  2. 2
      packages/genodelabs/targets.nix

31
packages/genodelabs/cached_fs_rom.patch

@ -0,0 +1,31 @@
commit 72032b25e153fe736b07670d4cf5d49a77e606db
Author: Emery Hemingway <ehmry@posteo.net>
Date: Fri May 29 17:39:05 2020 +0530
cached_fs_rom: diagnosis of delivered ROM sessions
To enable logging of ROM session deliveries, set the "diag" on
session routes:
<route>
<service name="ROM" label_prefix="/bin/">
<child name="cached_fs_rom" diag="yes"/>
</service>
<route>
Fix #3772
diff --git a/repos/os/src/server/cached_fs_rom/main.cc b/repos/os/src/server/cached_fs_rom/main.cc
index 392ff8aecb..9e4e4d0eee 100755
--- a/repos/os/src/server/cached_fs_rom/main.cc
+++ b/repos/os/src/server/cached_fs_rom/main.cc
@@ -394,6 +394,8 @@ struct Cached_fs_rom::Main final : Genode::Session_request_handler
/* Create new RPC object */
Session_component *session = new (heap)
Session_component(*rom, sessions, id, label);
+ if (session_diag_from_args(args.string()).enabled)
+ log("deliver ROM \"", label, "\"");
env.parent().deliver_session_cap(pid, env.ep().manage(*session));
} else if (!rom->transfer) {

2
packages/genodelabs/targets.nix

@ -1,6 +1,8 @@
{ buildPackages, ports }:
with ports; {
cached_fs_rom.patches = [ ./cached_fs_rom.patch ];
gpt_write.portInputs = [ jitterentropy ];
init.patches = [ ./sandbox.patch ];

Loading…
Cancel
Save