Release 17.05, base-hw, environment ROM session denied error

Bob Stewart robjsstewart at ...9...
Mon Jun 19 02:34:46 CEST 2017


Those two commits in "staging" have gotten rid of the emergency allocation warnings, Stefan. Thanks for the suggestion.

Bob

Get Outlook for Android<https://aka.ms/ghei36>

________________________________
From: Bob Stewart <robjsstewart at ...9...>
Sent: Wednesday, June 14, 2017 9:06:27 AM
To: genode-main at lists.sourceforge.net; Genode OS Framework Mailing List
Subject: Re: Release 17.05, base-hw, environment ROM session denied error

Hi Stefan, thanks for the reply.

I see those two commits and I'll checkout "staging" on the weekend once I figure out my issue with my core-only service access.

Bob

Get Outlook for Android<https://aka.ms/ghei36>

________________________________
From: Stefan Kalkowski <stefan.kalkowski at ...1...>
Sent: Wednesday, June 14, 2017 4:24:35 AM
To: genode-main at lists.sourceforge.net
Subject: Re: Release 17.05, base-hw, environment ROM session denied error

Hi Bob,

On 06/13/2017 04:32 PM, Bob Stewart wrote:
> Thanks for the reply, Norman.
>
> I doubt that it is related to explicit routing declarations as I have a
> default routing set to go through all parents, all children. Or, am I
> misunderstanding routing? This run script and component code work in
> 16.11 and 17.02. So the problem is being caused by a change in 17.05.
>
> I finally looked into child.h. The actual error is Service Denied. The
> ctrl_module component which is having this start up problem is trying to
> establish a session to a server which accesses a core-only service. I
> had to create this service because the SOC requires privileged access to
> enable hardware subsystems or to establish a specific gpio pin mux
> setting. The associated code has been working well since 2015. I'll
> trace the code back to the origin of the Service Denied state and find
> out what I have missed in the 17.05 changes.
>
> Regarding the two log lines:
>
>  [init -> gpio_drv] used before freeing emergency=276K
> [init -> gpio_drv] used after freeing emergency=260K
>
> These seem to be indicating an emergency allocation of memory had to be
> made. Does that mean the components RAM quota was insufficient?
>

Apart from the hints mentioned by Norman, we observed a regression
related to base-hw after introducing the new capability quota trading in
Genode. It has to do with capability memory shortage in the kernel. The
already available memory upgrade mechanism does not work correctly
anymore, because it got overloaded with other PD session upgrades. The
emergency memory release you are observing can be an indicator for this
problem.
Unfortunately, the regression got part of the release 17.05, but there
are two commits available that solve the problem. Those are its hashes:

  fb447f0727ca84d2f8907c344fa1954b7a9b217e
  e54b7174bcdb3fdc47d5b99e501c3620ea131caf

Alternatively, you may use today's staging branch to proceed, which do
already contain both commits.

Best regards
Stefan

> Thanks,
> Bob
> Get Outlook for Android <https://aka.ms/ghei36>
>
>
>
> ------------------------------------------------------------------------
> *From:* Norman Feske <norman.feske at ...1...>
> *Sent:* Tuesday, June 13, 2017 4:26:57 AM
> *To:* genode-main at lists.sourceforge.net
> *Subject:* Re: Release 17.05, base-hw, environment ROM session denied error
>
> Hi Bob,
>
>> "[init] Error: ctrl_module: environment ROM session denied
>> (label="ctrl_module",
>>
>> ram_quota=6144, cap_quota=3, diag=0) "
>>
>> What is this message telling me?
>
> traditionally, init created the initial sessions (aka environment
> sessions) of its children on the children's behalf without considering
> any child-specific routing. I.e., a child's PD session, CPU session, the
> ROM session with the executable binary, the ROM session with the dynamic
> linker were created by init directly via 'Connection' objects.
> Therefore, there was no need to route those sessions explicitly in the
> configuration.
>
> With version 16.11 and 17.02 [1], we revised the child-creation
> procedure. Now, the environment sessions are subjected to the routing
> rules as dictated by init's configuration.
>
> [1]
> http://genode.org/documentation/release-notes/17.02#Routing_of_environment_sessions
>
> In short, your routing rules for the "ctrl_module" lack a valid route
> for the executable binary.
>
>> Also, further down the log is the following output:
>>
>>
>>    init -> gpio_drv] resource_request: ram_quota=0,
>> cap_quota=4
>>
>>    [init -> gpio_drv] used before freeing
>> emergency=276K
>>
>>    [init -> gpio_drv] used after freeing emergency=260K
>>
>> I believe these are a result of the gpio server setting up a session
>> through the session interface.
>
> The 'gpio_drv' component runs out of its capability quota and politely
> asks its parent (init) for more (cap_quota=4). Capability quotas are new
> in version 17.05 and are described at [2].
>
> [2]
> http://genode.org/documentation/release-notes/17.05#Assignment_and_trading_of_capability_quota
>
> You may try to specify a 'caps=200' attribute to the start node of the
> corresponding component.
>
> 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
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> genode-main mailing list
> genode-main at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/genode-main
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
>
> _______________________________________________
> genode-main mailing list
> genode-main at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/genode-main
>

--
Stefan Kalkowski
Genode Labs

https://github.com/skalk · http://genode.org/

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
genode-main mailing list
genode-main at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/genode-main
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.genode.org/pipermail/users/attachments/20170619/a9e6b78e/attachment.html>


More information about the users mailing list