maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Alternatives (https://talk.maemo.org/forumdisplay.php?f=36)
-   -   U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1) (https://talk.maemo.org/showthread.php?t=81613)

marmistrz 2013-07-09 19:05

I'm getting an error now that the Nemo platformfs can't be opened

Code:

VFS: CAnnot open root device "mmcblk0p5" or unknown-block(0,0)
When trying to mount the partition (ext4) in Maemo with kp52 I'm getting:

Code:

Unable to mount /dev/mmcblk0p5: Invalid argument.
What am I doing wrong?

pali 2013-07-09 19:19

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by marmistrz (Post 1357934)
Thanks.
and should I run u-boot-update-bootmenu as root or as user?

If you want kernel string of attached kernel visible in u-boot menu, run update script as root. Otherwise as normal user :-)

Quote:

Originally Posted by marmistrz (Post 1357938)
I'm getting an error now that the Nemo platformfs can't be opened

Code:

VFS: CAnnot open root device "mmcblk0p5" or unknown-block(0,0)

This means that kernel did not initialized or did not loaded driver for "mmcblk0p5". Make sure your kernel has mmc driver static linked into zImage or you have initramfs with external modules. You can try to add "rootwait" to cmdline, then kernel will wait some time before mounting rootfs.

Quote:

Originally Posted by marmistrz (Post 1357938)
When trying to mount the partition (ext4) in Maemo with kp52 I'm getting:

Code:

Unable to mount /dev/mmcblk0p5: Invalid argument.
What am I doing wrong?

Make sure that ext4 driver is loaded (or static linked into kernel). Use modprobe and lsmod for verifing. Specify also filesystem param via "-t ext4" in mount command. When kernel refuse to mount something it will print error message to dmesg.

peterleinchen 2013-07-23 22:37

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Hi pali,

I am updating my device a bit and also installed latest u-boot (bootimg and tools). On bootimg everything went smooth, but after tools I got some weird error.
Quote:

Originally Posted by pali (Post 1357921)
This looks like your first eMMC partition (MyDocs) is not valid fat, ext2 or ext4.

Weird, as I never repartitioned my p1 and it is still stock partitioned vfat.

So I investigated a bit and it seems there is a small glitch in update enu script. It will only be noticed when you have easy debian mounted and/or another loop device pointing to a file on MyDocs.
I have both :)

Easy to solve:
just change line
Code:

type=$(mount | grep "$BOOTMENU_EMMC_DIR" | sed 's/.*type //;s/ .*//')
to
Code:

type=$(mount | grep " $BOOTMENU_EMMC_DIR " | sed 's/.*type //;s/ .*//')
Thought I let you know.

--
reason is that "mount" will give two/three outputs for "/home/user/MyDocs":
/home/user/MyDocs
.debian/home/user/MyDocs
/home/user/MyDocs/myLoopDevice
so type ends in "vfat vfat vfat"

Estel 2013-07-24 02:12

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Nice catch. If we're at it, while fixing it, maybe we would finally merge kerio's patch, allowing to make u-boot menu without "attached kernel" boot option?

Sure it's not big deal, but having non-working u-boot entry is still a little irritating for people, that doesn't attach kernels to u-boot (as there is no real reason to do so - after loading, kernel sits in memory, anyway).

BTW, I wonder, if u-boot without kernel attached shouldn't become default method. After all, multiboot was railed for NAND-saving reasons... Having only u-boot flashed to NAND saves it from wear too, as there is no need to reflash it with your favorite kernel-attached- everytime new version of kernel appears (you only need to flash if/when new version of u-boot appears, which happen much less frequently than new version of kernel[s]).

/Estel

pali 2013-07-24 05:53

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by peterleinchen (Post 1361543)
Hi pali,

I am updating my device a bit and also installed latest u-boot (bootimg and tools). On bootimg everything went smooth, but after tools I got some weird error.

Weird, as I never repartitioned my p1 and it is still stock partitioned vfat.

So I investigated a bit and it seems there is a small glitch in update enu script. It will only be noticed when you have easy debian mounted and/or another loop device pointing to a file on MyDocs.
I have both :)

Easy to solve:
just change line
Code:

type=$(mount | grep "$BOOTMENU_EMMC_DIR" | sed 's/.*type //;s/ .*//')
to
Code:

type=$(mount | grep " $BOOTMENU_EMMC_DIR " | sed 's/.*type //;s/ .*//')
Thought I let you know.

--
reason is that "mount" will give two/three outputs for "/home/user/MyDocs":
/home/user/MyDocs
.debian/home/user/MyDocs
/home/user/MyDocs/myLoopDevice
so type ends in "vfat vfat vfat"

Fixed in git: https://gitorious.org/u-boot-shr/u-b...4ad7caaaa62d33

peterleinchen 2013-07-24 07:03

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by Estel (Post 1361561)
... allowing to make u-boot menu without "attached kernel" boot option?

Sure it's not big deal, but having non-working u-boot entry is still a little irritating for people, that doesn't attach kernels to u-boot (as there is no real reason to do so - after loading, kernel sits in memory, anyway).

Estel, what is your reason to request that?
Afaik the u-boot-flasher has attached the stock kernel, so there is no change of kernel at all.
Of course people who have attached their own kernel (like me, who not installed the u-boot flasher package) may need to change that on a kernel change. But I am thinking of going pali's way now and use the /etc/default symlink way...

Alecsandru 2013-07-24 08:14

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
the cssu3 kernel as default entry would be nice

reinob 2013-07-24 14:48

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by Estel (Post 1361561)
...as there is no need to reflash it with your favorite kernel-attached- everytime new version of kernel appears

Come on. It's not that frequent that the kernel gets updated. I submit that the mtd partition holding the kernel can be flashed about 10000 times, give or take a 0.1 or 10 factor.

Estel 2013-07-24 20:03

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Sure, but if we already depreciated multiboot due to NAND wear reasons (despite fact, that NAND wasn't worn so much, until you shuffle kernels on every reboot, and reboot twice a day), I don't see, why we should propagate flashing u-boot with kernels attached.

There is *no* valid reason to attach kernel to u-boot - having u-boot only in kernel area, and loading kernels from regular space is both technically and practically better.
---

Anyway, I don't request moving into u-boot only in NAND area for everyone - I just suggested it as side note (because it's logical, see all of the above).

Main thing I've requested, is to merge already existing (i.e. someone did it months ago) patch to update menu script, that detects lack of attached kernel, thus *in* creating useless menu entry.

/Estel

Alecsandru 2013-07-24 20:06

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
estel i wish you to get a corrupted MyDocs and see how your theory works in that case

pali 2013-07-24 20:24

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
I really do not see reason to use uboot image without attached kernel. kernel nand area is cleaned whole at one time. also you can configure default kernel for booting via etc. and as I remember correctly there was some problem with that patch... also I am not archeologist and I do not have time for finding some patch somewhere on internet. If you want to review some patch, please at least add link to it...

Estel 2013-07-25 08:18

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by Alecsandru (Post 1361844)
estel i wish you to get a corrupted MyDocs and see how your theory works in that case

And how it is related? If you use anything kernel-dependent (thumb), you would be screwed, anyway. Unless you, for once, "read manual" and discover, that in such cases, U-boot can run things from SD card (via u-boot console). Or you can use rescue Os from flasher. Or...

Quote:

Originally Posted by pali (Post 1361849)
I really do not see reason to use uboot image without attached kernel. kernel nand area is cleaned whole at one time. also you can configure default kernel for booting via etc. and as I remember correctly there was some problem with that patch... also I am not archeologist and I do not have time for finding some patch somewhere on internet. If you want to review some patch, please at least add link to it...

Well, I do not see any reason to use u-boot image *with* kernel attached ;) But thats OK - everyone haw own favorite ways. That's why I asked to make genbootmenu script respect lack of attached kernel, and stop creating non-working menu entries for it.

This way, someone who use attached kernel is happy, and people who prefer otherwise, doesn't "suffer", too.

As for patch - I don't have it, AFAIK, kerio send it to you, personally. As per his IRC'ing, you haven't had time to look into it. Probably, he should submit it to some git or whatsnot, if you don't have it, it means he didn't.

Anyway, putting kerio aside (I can easily imagine, that his patch was less than ideal and could cause some problems you vaguely remember), *if* it's doable and doesn't cost you too much time, it would be nice, to have u-boot menu generator, that doesn't enforce non-working menu entry for attached kernel.

It could be as simple as parameter given to generate script, like --no-attached, which would disable - at user responsibility - that menu entry. This way, whole heuristic to determine things, would be spared.

If you don't see it as feasible, I can easily live with it. I just though that, while updating generating script anyway, it may be good to fix two nuisances at the same time. Killing two deer with one spear, or something like that...

/Estel

pali 2013-07-25 08:33

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Ok, here is simple patch:
https://gitorious.org/u-boot-shr/u-b...0e684eeb2a7363

Estel 2013-07-25 14:31

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
You're the man :) Thanks.

BTW, it is funny, that patch is probably 3244 shorter, than our 2-pages discussions about rationale for it ;)

/Estel

pali 2013-07-25 14:34

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
but only in last your post you proposed solutions with all details.

Akkumaru 2013-08-07 16:38

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
help. i'm new in the N900 world, and I can't seem to get the boot menu. updated the bootmenu, restarted with keyboard open and closed, restarted and pressing u, almost everything and i can't seem to get the menu. not even the fall back menu. i have thumb and kernel power 51 if that matters.

pali 2013-08-08 08:20

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
New version of package fiasco-image-update-ask is in extras-testing. Please vote for promoting this package to extras. Package is needed for kernel-power and u-boot to ask if you really want to change kernel version when installing u-boot or any kernel package

http://maemo.org/packages/package_in...pdate-ask/0.3/

pali 2013-08-08 09:00

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Now you can vote also for u-boot packages:
http://maemo.org/packages/package_in...img/2013.04-1/
http://maemo.org/packages/package_in...her/2013.04-1/
http://maemo.org/packages/package_in...ols/2013.04-1/

sponka 2013-08-14 16:21

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
I made something stupid ... Had u-boot and power kernel installed + nemo on sd card. It's been some time since I last fiddled with device and forgot to be extra cautious -- went and simply uninstalled u-boot via HAM.

Now I have unbootable device -- u-boot is still present and tries to load "something" and device just power off.

Any other way other than flashing?

Thanks,
b.

pali 2013-08-14 16:33

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
@sponka: flash, but only kernel.

sponka 2013-08-14 16:42

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by pali (Post 1367229)
@sponka: flash, but only kernel.

Thanks! (and fingers crossed :p )

reinob 2013-09-05 14:19

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
@Pali,

I was thinking about which possibilities U-boot allows to boot kernels which are not locally stored.

AFAIK U-boot doesn't support WLAN networks so tftpboot is out of the question (but would be seriously cool :).

Apparently U-boot can use USB mass storage, which would be half as cool, but still very interesting (http://processors.wiki.ti.com/index....ot#USB_Storage).

Obviously this requires host-mode on the N900s side (the PC/stick would contain the kernel to fatload).

Is this supported at all in N900's U-boot, or can you add support for this?

Having host-mode would also allow for USB-Ethernet adapters, and hence tftp, dhcp, nfs, etc.

pali 2013-09-05 15:08

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
@reinob: U-Boot musb driver is totally broken. It some older version of u-boot it was possible to establish tty serial console, but after some time of usage it did something with n900 HW and after booting linux kernel it crashed. Full reset (removing battery) was needed. But I remember that I was able to use u-boot console via usb from PC. And I think that u-boot can use serial console also for loading kernels... But new musb driver which is in last u-boot now totally not working. And forgot for usb host mode. Only in linux kernel it is semi-possible (with helper userspace applicaion). Only thing which could be possible is to fix new musb driver for serial console tty support.

reinob 2013-09-05 18:41

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
@pali,

Thanks. I'm not sure it would be worth the effort, but some kind of serial-over-USB console might come in handy when un-bricking (if only for the convenience of a real keyboard). Plus sending over a kernel (or initrd) via serial (xmodem, zmodem, kermit? :) might also save the day, some day :).

int_ua 2013-09-16 12:43

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Can we disable -omap option creation for -thumb installations? It doesn't boot anyway.

Update:
--no-attach option commit:
https://gitorious.org/u-boot-shr/u-b...0e684eeb2a7363

Question at -thumb thread: http://talk.maemo.org/showthread.php...86#post1374686

Update 2:
Code:

$ dpkg -s apt | grep Version | grep thumb
?

pali 2013-09-17 01:03

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Quote:

Originally Posted by int_ua (Post 1374533)
Can we disable -omap option creation for -thumb installations? It doesn't boot anyway.

I do not want to disable it by default, because bootmenu and backupmenu working fine (because it not using thumb binaries)

frank umoren 2013-09-17 07:19

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
pls help, i installed (with FAM): u-boot with kernel 2.6.28-omap1; linux kernel for power user v52; linux kernel for power user boot image for u-boot; linux kernel for power user settings and overclock. then i typed in xterm: u-boot-update-bootmenu. rebooted and u-boot came up but didnt boot into OS. please what do i do?

frank umoren 2013-09-17 15:52

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
pls someone should help, its my first time here, i guess this issue has been addressed before, but i've read tons of post here to no avail, i just want a step by step guide on how to make kernel power v52 work with u-boot. and nitdroid. thanks in advance.

Alecsandru 2013-09-18 09:58

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Install kp52 first and after u-boot .both of them from fam
close fam
open x-term :
root
apt-get update
apt-get install kernel-power-bootimg
u-boot-update bootmenu
shut down phone
slide keyboard
chose kernel power 52 and press enter

Dhicky 2013-09-28 07:59

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
I Installed NITDroid ics 4.0.4 with u-boot, but i can not find NITDroid menu in u-boot, can someone help me :|

frank umoren 2013-09-29 23:38

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Posts: 5 | Thanked: 1 time | Joined on Jan 2013

Report This | #162
well. i've read carefully almost every post on u-boot releted thread. what i dont understand is how to create config file in /etc/bootmenu.d with suffix .item and copying zimage to /boot.
Because when i install (with apt-get) u-boot-bootimg, u-boot-tools, u-boot-flasher, kernel-power-bootimg and kernel-power-settings and then run in xterminal: u-boot-update-bootmenu, the .item file will be generated in /etc/bootmenu.d and the zimage will be there in /boot. but then, once i restart the phone with slide out keyboard, and select power kernel (or stock), u-boot will show "starting kernel" then go off. i end up flashing the stock kernel each time.

so pls what am i doing wrong? what am i missing? cos this is really freaking me out now. i know you guys are good and offer help to those who dont understand. help me pls.

Alecsandru 2014-02-03 15:41

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
how about creating a vfat partition only for u-boot(bootmenu folder & etc)?
let°s say mmcblk0p6(use that instead of MyDocs)
can that be done pali?
how?(what configs must be changed?)

pali 2014-02-03 16:31

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
boot script in CONFIG_PREBOOT which is hardcoded in include/configs/nokia_rx51.h

Alecsandru 2014-02-03 18:16

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
how about doing it on the phone without recompiling?

pali 2014-02-03 19:00

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
as you can see it is not possible (with binary from maemo extras)

Estel 2014-05-10 19:34

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
It is follow up to:
http://talk.maemo.org/showpost.php?p...&postcount=232
...and:
http://talk.maemo.org/showpost.php?p...&postcount=233
...as I didn't wanted to clutter kernel-power thread.
---

Quote:

Originally Posted by pali (Post 1424831)
This looks like damaged uboot mtd as uboot is not able to boot attached kernel. BTW, if you did not create custom combined uboot image, than attached image is not kp53...

I have *only* u-boot in mtd, I don't use *any* attached kernel. Also, my default entry for creation was symlinked to kp53 .item (just like it was for kp52 before), and I have NFC why it is trying to load attached kernel at all.

BTW, it just got more and more strange. I went through u-boot internal help (and u-boot thread to help me remember where exactly uimages are stored), and issued:
Code:

fatload mmc 1:1 some_random_garbage_text bootmenu.img.d/zimage-2.6.28.10-power53
...which resulted in few lines scrolling too fast to read, and device rebooting (nokia logo, etc) instantly, then - to my surprise - presenting me with usual u-boot startup menu that I was expecting from the very start (with kp53 as one of boot options).

Just because I'm stubborn f*cker like that, I ignored it, choosing "u-boot console" and issued:
Code:

reset
This resulted in device rebooting again, this time throwing the error I described in first post, again. After re-issuing fatload as above, it thrown me into proper startup menu again, from where I selected kp53 entry and booted normally (BTw, this is where I ensured that it doesn't matter what I write to "some_random_garbage_text" argument - which was described as 'addr' in u-boot internal help, whatever address it mean).

Now, after I shutdown device and boot again, I'm back at point 1 - u-boot errors, that I can recover from by fatload uimage from bootmenu.img.d, just like I did two times before.
---

Now, the obvious question - given the procedure of updating to kp53 I described in already mentioned:
http://talk.maemo.org/showpost.php?p...&postcount=232

...what I did wrong, and how the heck recover from it to the point of having usable u-boot startup menu I used to have before? What the hell is happening, from technical point of view, BTW?

Sorry if I'm just extremely clumsy and overlooked something obvious,

/Estel

pali 2014-05-10 20:00

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Try to charge battery to full and also run fsck on MyDocs. Or try to use uboot binary from extras (with attached default kernel). I do not know where can be problem. Sometimes NOLO does not initialize mmc device properly (charging battery can help), sometimes u-boot cannot read MyDocs due to different/unsupported fat format (this can also happen by MS windows fat driver)...

Estel 2014-05-10 20:34

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Thanks Pali, I'll do that and try to pinpoint the problem. What makes me wonder, is that - in case of my device - it is perfectly reproducible, i.e. I could go through the steps I've described again, 1:1, with exactly the same results.

Considering that, it strikes me as highly unlikely that it's some random initialization failure from NOLO, and if it's fckd fat on MyDocs, then u-boot assumes it *wrong* that it can't read it for the first time, and proceed to read it properly after I explicitly write command to load that uImage from fat.

Anyway, I'll do some more research and report back on my findings (or lack of).

/Estel

pali 2014-05-10 20:53

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Uboot has some special code for rx51 for initializing one mmc device (do not remember if mmc0 or mmc1). Other one mmc device is initialized by NOLO. And sometimes (only sometimes on my n900 with low battery) I saw that one mmc device was not initialized (that one from NOLO). And because of that sometimes problem I was not able to properly write code for initialzing other one mmc device... And maybe you are seeing this NOLO problem and there is maybe other condition when mmc device is not initialized...

Other problem when uboot does not see bootmenu is when uboot fat driver cannot read files from MyDocs partition. And this can happen if some fsck tool change something in fat structure. Until now I still do not know which fat format structure is OK for uboot. What we know is that default vanilla eMMC fiasco image contains fat partition which is OK for uboot.

Estel 2014-05-10 21:42

Re: U-Boot for Nokia RX-51 with BootMenu (updated version 2012.10-rc3-1)
 
Update:
I've checked /dev/mmcblk0p1 via Maemo's fsck.vfat and it didn't found any problems. Without changing anything re Mydocs filesystem (I suppose it wasn't FAT problem this time, as u-boot driver was perfectly fine with loading/listing it's content, even when it failed to boot kernel/etc), I reinstalled kernel-power-bootimg for kp53, and invoked u-boot-update-bootmenu again. Sync'ed afterwards just in case, although it shouldn't matter here.

Powered device down, booted, and of course, everything is working fine. My uneducated guess - for some reason, bootmenu.scr on MyDocs got screwed, and u-boot tried to load attached kernel upon boot (which it couldn't, as I don't have attached kernel).

The thing I don't get, is why after telling it (manually, via u-boot console) to load kp53 (or any correct one, in fact) uImage from bootmenu.img.d folder on MyDocs, it mysteriously loaded *the same* bootmenu.scr on it's own, without asking. I suspect some sneaky, hard to pinpoint bug, here.

One pointer - I just noticed, that my /etc/default/bootmenu.item was broken symlink, after all. It *shouldn't* result in such weirdo, as I was trying to boot with keyboard open, too (which should result in u-boot menu appearing), but who knows. The latest bootmenu.scr generation that worked fine was done *after* I fixed that symlink (making it point to proper kp53.item).

/Estel


All times are GMT. The time now is 18:57.

vBulletin® Version 3.8.8