RPC parameters
Norman Feske
norman.feske at ...1...
Thu Jan 14 11:26:56 CET 2016
Hello,
> Genode is new to me . I just start playing with it.
welcome to the list!
> I was looking at the Hello program and the RPC mechanism. as i
> understood RPC does not support passing pointer as parameter
> how i can pass a parameter by reference where i need to change its value
> in the server side.
you can find a detailed description of the RPC mechanism in Section
8.12. "Remote procedure calls" of the manual [1]. In short, you have two
options:
1. Define a POD struct used as return type of your RPC functiion.
For an example, take a look that the Framebuffer::Session::mode
RPC function [2].
2. You can pass a reference to a POD object as RPC argument.
This is rarely used but you can find find an example in the
Raspberry-Pi-specific platform-session interface, namely the
setup_framebuffer RPC function [3].
[1] http://genode.org/documentation/genode-foundations-15-05.pdf
[2]
https://github.com/genodelabs/genode/blob/master/repos/os/include/framebuffer_session/framebuffer_session.h#L91
[3]
https://github.com/genodelabs/genode/blob/master/repos/os/include/spec/rpi/platform_session/platform_session.h#L39
Cheers
Norman
--
Dr.-Ing. Norman Feske
Genode Labs
http://www.genode-labs.com · http://genode.org
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