<br><br><div><span class="gmail_quote">2006/10/19, Eero Tamminen &lt;<a href="mailto:eero.tamminen@movial.fi">eero.tamminen@movial.fi</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br><br>ext Marius Gedminas wrote:<br>&gt;&gt;&gt;&gt; Hi, after upgrade to maemo 2.0 I have a problem. Some times my 770<br>&gt;&gt;&gt;&gt; reboot. This happen some times when I'm using the browser and every<br>&gt;&gt;&gt;&gt; time I try to use Gizmo. For now I never had problem with other
<br>&gt;&gt;&gt;&gt; programs. You think this is a software problem or hardware?<br>&gt;&gt;&gt; My 770 reboots once every two--three days.&nbsp;&nbsp;I think it's a software<br>&gt;&gt;&gt; problem.&nbsp;&nbsp;I could be wrong.<br>&gt;&gt; As mentioned in the following link, please file bugs against the errant
<br>&gt;&gt; applications.<br>&gt;&gt; <a href="http://maemo.org/maemowiki/ReportingRebootIssues?action=show">http://maemo.org/maemowiki/ReportingRebootIssues?action=show</a><br>&gt;&gt;<br>&gt;&gt; I remember in your case it was FBReader - report it to them.
<br>&gt;<br>&gt; /var/lib/dsme/lifeguard-resets claims it is maemo_af_desktop's fault.<br><br>Were there several reboots accounted for the Desktop process?<br><br>Btw. there are several reasons why Desktop might die:<br>- It's buggy :-)
<br>- Something in the device is forcing it to run completely out of memory<br>&nbsp;&nbsp;(and if alloc fails, Glib will abort the co. process), e.g. because<br>&nbsp;&nbsp;that something is leaking memory or otherwise using a lot of memory
<br>&nbsp;&nbsp;without integrating itself to the device memory management:<br>&nbsp;&nbsp;- If possible, app should implement support for the &quot;background killing&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;i.e. save UI state when backgrounded and then indicate[1] that it's
<br>&nbsp;&nbsp;&nbsp;&nbsp;killable when the device runs out of memory:<br>&nbsp;&nbsp;&nbsp;&nbsp;<a href="https://stage.maemo.org/svn/maemo/projects/haf/doc/api/hildon-libs/hildon-libs-HildonProgram.html#hildon-program-set-can-hibernate">https://stage.maemo.org/svn/maemo/projects/haf/doc/api/hildon-libs/hildon-libs-HildonProgram.html#hildon-program-set-can-hibernate
</a><br>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.maemo.org/platform/docs/api/libosso/html/group__Statesave.html">http://www.maemo.org/platform/docs/api/libosso/html/group__Statesave.html</a><br>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.maemo.org/platform/docs/api/libosso/html/group__Autosave.html">
http://www.maemo.org/platform/docs/api/libosso/html/group__Autosave.html</a><br>&nbsp;&nbsp;&nbsp;&nbsp;When foregrounded, I think app should then remove the state and<br>&nbsp;&nbsp;&nbsp;&nbsp;when being re-started, it should check whether there was some<br>&nbsp;&nbsp;&nbsp;&nbsp;UI-state.&nbsp;&nbsp;If there was, restore the UI-state (instead of going
<br>&nbsp;&nbsp;&nbsp;&nbsp;to the default application state).&nbsp;&nbsp;If you strace the device apps,<br>&nbsp;&nbsp;&nbsp;&nbsp;you see that UI state is stored under /tmp/osso-appl-states/ which<br>&nbsp;&nbsp;&nbsp;&nbsp;is on tmpfs i.e. goes away at reboot<br>&nbsp;&nbsp;- It could use the libosso osso_mem_saw_enable &amp; osso_mem_saw_disable
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://maemo.org/lxr/source/libosso/src/osso-mem.h#110">http://maemo.org/lxr/source/libosso/src/osso-mem.h#110</a><br>&nbsp;&nbsp;&nbsp;&nbsp;functions around operations that:<br>&nbsp;&nbsp;&nbsp;&nbsp;- could potentially take a lot of memory (loading large image etc)
<br>&nbsp;&nbsp;&nbsp;&nbsp;- handle allocation failures gracefully (not abort/assert)<br>&nbsp;&nbsp;- If app caches things or otherwise has some &quot;optional&quot; memory<br>&nbsp;&nbsp;&nbsp;&nbsp;usage, it could also listen to the system low memory notifications<br>
&nbsp;&nbsp;&nbsp;&nbsp;so that it can purge from RAM all of its caches when that happens:<br>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.maemo.org/platform/docs/api/libosso/html/group__Devstate.html">http://www.maemo.org/platform/docs/api/libosso/html/group__Devstate.html
</a><br>&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://www.maemo.org/platform/docs/api/libosso/html/group__outside.html#g231284109a21410088850beed324ea57">http://www.maemo.org/platform/docs/api/libosso/html/group__outside.html#g231284109a21410088850beed324ea57
</a><br><br>If the device runs _completely_ out of memory, I don't think the kernel<br>out-of-memory killer knows which process user would prefer to be killed<br>to get more memory :-).<br><br>Some more info on kernel OOM-killer:
<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://linux-mm.org/OOM_Killer">http://linux-mm.org/OOM_Killer</a><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="http://lwn.net/Articles/104179/">http://lwn.net/Articles/104179/</a><br><br>[1] You can check whether app is &quot;background-killable&quot; by:
<br>- using &quot;xwininfo|grep Window id&quot; and tapping to the application window,<br>- topping another window, and then<br>- doing &quot;xprop -id &lt;id&gt; | grep KILL&quot;<br>If you see the hibernate property set for the app,
<br>it is &quot;background killable&quot;.<br><br><br>&gt; FBReader just happens to be the application I use most often.<br>&gt;<br>&gt; I haven't reported it in Bugzilla yet, because I do not have a way to<br>&gt; reproduce the problem (other than &quot;try to use the device for a few
<br>&gt; days&quot;), and also because it is not that irritating -- the device boots<br>&gt; pretty fast, and the progress bar is kinda nice.&nbsp;&nbsp;:)<br><br><br>&nbsp;&nbsp;- Eero<br>_______________________________________________<br>maemo-developers mailing list
<br><a href="mailto:maemo-developers@maemo.org">maemo-developers@maemo.org</a><br><a href="https://maemo.org/mailman/listinfo/maemo-developers">https://maemo.org/mailman/listinfo/maemo-developers</a></blockquote><div><br>
<br>Thanks to everyone for&nbsp; suggestions. I will report any information I can collect , following those instructions <a href="http://maemo.org/maemowiki/ReportingRebootIssues?action=show">http://maemo.org/maemowiki/ReportingRebootIssues?action=show
</a>, in the hope that those can help to fix bugs.<br></div><br></div><br>