Linux IO_MEM session

Christian Helmuth christian.helmuth at ...1...
Thu Jan 25 13:01:36 CET 2018


Hello Johannes,

On Thu, Jan 25, 2018 at 11:25:20AM +0100, Johannes Kliemann wrote:
> > _ds_cap = _ds_ep->manage(&_ds);

Looking at the generic implementation we learn that it also needs a
cast after the manage


  base/src/core/io_mem_session_component.cc:87:
  _ds_cap = static_cap_cast<Io_mem_dataspace>(_ds_ep->manage(&_ds));

For testing I adapted this to the current inheritance state in
base-linux, which then compiles

  base-linux/src/core/io_mem_session_component.cc:72:
  _ds_cap = static_cap_cast<Io_mem_dataspace>(static_cap_cast<Dataspace>(_ds_ep->manage(&_ds)));

So, the implementation currently prevents to provide Io_mem_dataspace
as easy as Dataspace because there's no hook to tell the generic parts
that a Dataspace is in fact a Linux_dataspace because Io_mem_dataspace
directly inherits Dataspace. Sounds twisted, but that's the reason in
my opinion and we need to do some refactoring to make the
Io_mem-related modules tweakable in this regard.

Regards
-- 
Christian Helmuth
Genode Labs

https://www.genode-labs.com/ · https://genode.org/
https://twitter.com/GenodeLabs · /ˈdʒiː.nəʊd/

Genode Labs GmbH · Amtsgericht Dresden · HRB 28424 · Sitz Dresden
Geschäftsführer: Dr.-Ing. Norman Feske, Christian Helmuth




More information about the users mailing list