The Following User Says Thank You to Estel For This Useful Post: | ||
![]() |
2012-05-11
, 05:52
|
Posts: 2,154 |
Thanked: 8,464 times |
Joined on May 2010
|
#22
|
![]() |
2012-11-13
, 12:20
|
Posts: 1,808 |
Thanked: 4,272 times |
Joined on Feb 2011
@ Germany
|
#24
|
![]() |
2012-11-13
, 12:49
|
Posts: 2,154 |
Thanked: 8,464 times |
Joined on May 2010
|
#25
|
@pali,
I have a question about getbootstate, in particular regarding bootmode and bootreason:
AFAIK the Fremantle version reads bootreason from /proc/bootreason and bootmode from /proc/component_version. The Harmattan version (again, AFAIK) takes these two values from the kernel commandline (bootreason=X, bootmode=Y).
I remember having read a getbootstate.c where both methods were attempted (first Harmattan, then Maemo), but it was not clear if that was the stock Fremantle getbootstate, or what.
So the first question is:
* do you know if stock getbootstate checks the cmdline first?
And the first "request" is:
* can you make it that way on the open-source version of getbootstate?
This way one could, e.g. make a U-boot entry for booting Maemo with a chosen bootmode/bootreason (e.g. always "pwr_key" and "normal"), in case something goes bad.
It would be also *very* nice if we could include in the kernel commandline a kind of "bypass" for the whole getbootstate, e.g. "init=... bootstate=USER ..."
This way getbootstate would check if that parameter was included in the command line and immediately return it, without checking anything else (no BSI, no boot count, no thing).
This would provide an additional back-up in case something goes horribly wrong.
I don't think anyone will have anything against the proposal here. After all, as long as you don't touch the kernel commandline everything will work as normal.
If I find the time I will try to do it myself (I have now installed gcc and libcal-dev in my spare-N900s so I could do this while on the trainbut obviously it would be good if you did that for my benefit
(oh, and for the rest of the community, natürlich
Cheers.
![]() |
2012-11-13
, 19:19
|
Posts: 1,808 |
Thanked: 4,272 times |
Joined on Feb 2011
@ Germany
|
#26
|
This is possible now too. Just enable R&D mode (which is designed for above problematic situations) nad getbootstate (both closed and my new open) will set USER bootstate if you are booting from power off.
The Following User Says Thank You to reinob For This Useful Post: | ||
![]() |
2012-11-13
, 19:22
|
Posts: 2,154 |
Thanked: 8,464 times |
Joined on May 2010
|
#27
|
Yeah, I have activated R&D mode with pwr_key. It's just that on my N900 without bme I sometimes forget to tell dsme that the charger is not connected, so instead of powering off it goes to some half-act-dead-but-not-quite-nirvana state, so when I turn it on again it doesn't quite know what to do (I think it gets bootstate = ACTDEAD even though pwr_key is forced) until it reboots again, this time with pwr_key/normal/USER bootstate.
The Following 3 Users Say Thank You to pali For This Useful Post: | ||
![]() |
2012-11-14
, 08:43
|
Posts: 1,808 |
Thanked: 4,272 times |
Joined on Feb 2011
@ Germany
|
#28
|
![]() |
Tags |
getbootstate, preinit |
Thread Tools | |
|
/Estel
N900's aluminum backcover / body replacement
-
N900's HDMI-Out
-
Camera cover MOD
-
Measure battery's real capacity on-device
-
TrueCrypt 7.1 | ereswap | bnf
-
Hardware's mods research is costly. To support my work, please consider donating. Thank You!