[09:53] asac, i milestoned bug #457878 (since it still exists with the recent BSP drop) [09:53] Launchpad bug 457878 in linux-fsl-imx51 "imx51 on board ethernet plug/unplug events not detected" [Medium,Confirmed] https://launchpad.net/bugs/457878 [09:53] cooloney, ^^^ [09:56] ogra: cool, will take a look when I am back to Shanghai, heh [10:43] ogra: you are sure your modules are loaded? [10:44] aka are you sure your kernel/initramfs you used for your uboot is identical with the one you have no your filesystem [10:44] i had the same behaviour yesterday, but it was all a version mismatch [10:44] dmart: thx for the email, could you please file a NEON bug in launchpad and assign it to me? [10:44] dmart: then we can tracker the discussion [10:45] ogra: asked for dmesg/syslog in bug [10:50] asac, ?? [10:51] ogra in your ethernet bug [10:51] are you referring to the bug above ? [10:51] or rather the bug you hi jacked [10:51] yes [10:51] sure the modules are loaded [10:51] its not related to uboot [10:51] yesterday you said there is no interface [10:51] now its just LOWER_UP? [10:51] thats on a redboot booted system and is a long standing missing feature in the FEC driver [10:52] yeah [10:52] ok [10:52] it was missing in all kernel versions we ever had [10:52] so that "no net at all" feature is fixed for you? [10:52] no [10:52] where is that bug? [10:52] thats what i'm looking at atm, i just wanted to make sure the above bug isnt forgotten [10:52] heh ok. [10:53] i havent filed it yet, just looking at uboot code to make sure we build the right driver [10:53] do you see your interface at all? [10:53] i saw it [10:53] though i only have a read-only fs [10:53] yes, you can see it, but you cant bring it up [10:54] usually you see the kernel setting the MAC in demsg, that part is missing, i see it initializing the driver but the line with MAC is missing [10:54] wireless is working flawlessly here :) [10:54] and ifconfig says it cant assign an address [10:54] so i think its not a blocker to stop the uboot move in debian-cd [10:55] (where it refers to the MAC) [10:55] yeah [10:55] the only interface the bnoard has doesnt work .. [10:55] i would consider that as a blocker :) [10:55] a release blocker yes, [10:55] but not a roll out blocker [10:55] well, at least highest prio [10:56] sure, but we should do the uboot move before that [10:56] well, uboot needs an upload anyway [10:56] for the changed defaults [10:56] we also need to consider that an installed system might not have /boot on the second partition [10:57] i'm not sure how to solve that yet but have some ideas (if uboot doesnt stop script execution we can just try to load from part1 and then from part2, but i'm not sure that works, needs testing) [10:57] ogra: atm we have a boot floppy and an install floppy. we can assume that its always on partition 2 for the boot floppy thing [10:57] its not a real solution [10:58] but we need to work on scripts to work on that [10:58] how are you doing that on redboot? [10:58] we cant assume that once we install uboot to mtd flash [10:58] redboot never goes into flash [10:58] once we install it there [10:58] as soon as you boot from flash the first partition will be gone [10:58] at that point we must be able to interate [10:58] thats what davidm wants as final install setup [10:59] sure [10:59] but we are not there yet ;) [10:59] so users just flip a DIP switch in the end [10:59] no, but i'd like to know in advance if it works :) [10:59] right. thats understood. just doesnt need to happen on the first iteration [10:59] it has to be made working. [11:00] it works already :) [11:00] so you have an iterating boot.scr? [11:00] but i dont feel good with all the hardcoding [11:00] no [11:00] it works as is [11:00] right. so dont bother about that [11:00] with the hardcoded part2 loading [11:00] what i meant with has to be made working is that we can do that [11:00] yes. [11:00] 11:59 < asac> right. thats understood. just doesnt need to happen on the first iteration [11:01] 11:59 < asac> it has to be made working. [11:01] -> thats iterating boot.scr [11:01] ok [11:01] i am getting cigarettes and coffee [11:01] and then will stop bothering you ; [11:01] ) [11:01] if i can put a bootscript into the defaults that tries part1 and moves on to part2 (without .scr since we need to load that as well) i prefer to do that directly [11:02] currently the only thing i want the scr for is the kernel cmdline [11:02] only boot.scr can test for something afaik [11:02] so you cannot test if something succeeded [11:02] boot.scr just replaces the bootcmd in the uboot defaults afaik [11:02] it gets compiled afaik [11:02] the whole for and if stuff is not available at command prompt [11:02] it just gets turned into a file uboot can load [11:03] but the content is what you see in printenv at the uboot prompt [11:03] so everything we do in .scr files should be possible directly too [11:04] afaik you can do "if ... then ... etc" in the hardcoded bootcmd [11:05] i dont see any docs about that [11:05] if you find that let me know [11:05] uboot has really sucky documentation [11:06] http://www.denx.de/wiki/view/DULG/CommandLineParsing [11:07] bootm $addr1 || bootm $addr2 || tftpboot $loadaddr $loadfile && bootm [11:07] ogra: ^ [11:07] so you can test that etc. [11:08] well, thats already what i look for [11:08] so we need hush shell support builtin [11:10] aha, needs the SHELL_HUSH option set at build time [11:10] * ogra looks in the code [11:13] CONFIG_SYS_HUSH_PARSER :) there it is [11:16] yes [11:18] http://paste.ubuntu.com/356511/ has the full config in case someone wants to look :) [11:18] * ogra wonders if #define CONFIG_FEC0_PHY_ADDR 0x1F is our prob with the NIC [11:35] * ogra builds [11:35] asac, how about ext2 support while i'm at it, do you want that ? [11:38] make[2]: Entering directory `/uboot-imx-2009.08/fs/fdos' [11:38] ar crv /uboot-imx-2009.08/build/build-imx51/fs/fdos/libfdos.a [11:38] make[2]: Leaving directory `/uboot-imx-2009.08/fs/fdos' [11:38] hmm [11:39] i wonder if fdos is actually the better fat filesystem :) [11:40] mxc_fec.c: In function 'mxc_fec_initialize': [11:40] mxc_fec.c:781: warning: passing argument 1 of 'mxc_fec_set_mac' from incompatible pointer type [11:40] mxc_fec.c:725: note: expected 'struct fec_info_s *' but argument is of type 'struct fec_info_s (*)[1]' [11:40] AHA ! [11:40] i guess thats the NIC issue [11:54] ogra: you can just include that i guess [11:54] i think we should [11:54] do it [11:54] having /boot ext2 formatted will gain us a lot more flexibility [11:54] i.e. symlinks [11:55] so we can have uimage being linked to uimage-$version [11:55] yes, go for it [11:55] yup, will do [11:55] testing hush support first [11:55] its just a config flag after all [11:55] right [11:55] hush + ext2 + fix fec [11:55] if you want me to lok at that code i can check [11:56] plars: so when did dove regress exactly? do we know that? [11:57] asac, fec ? yeah, that would help, so i can concentrate on the script [11:57] ok ... let me use jocote ;) [11:57] ogra: that happens on current archive uboot too, right? [11:58] gah, i hate that sshd doesnt log me out if i shut down the babbage [11:58] asac, yea, thats what i'm building [12:08] BBG U-Boot > setenv myload 'if mmcinfo; then echo MMC found;else echo MMC not found;fi' [12:08] BBG U-Boot > print myload [12:08] myload=if mmcinfo; then echo MMC found;else echo MMC not found;fi [12:08] BBG U-Boot > run myload [12:08] Device: FSL_ESDHC [12:08] Manufacturer ID: 1 [12:08] OEM: 5041 [12:08] Name: SM06G [12:08] Tran Speed: 25000000 [12:08] Rd Block Len: 512 [12:08] SD version 2.0 [12:08] High Capacity: Yes [12:08] Capacity: 1945882623 [12:08] Bus Width: 4-bit [12:08] MMC found [12:08] BBG U-Boot > [12:08] SWEET ! [12:08] ogra: can you say something like: [12:08] so now we can iterate over partitions, look for /casper etc [12:08] if fatinfo mmc 0:2; then [12:09] sure [12:09] if fatload mmc 0:2 /boot/...; then [12:09] well, fatls rather [12:09] ogra: where is that documented [12:09] yeah, exactly [12:09] i didnt see that on that patge [12:09] 14.2.16.3. Hush shell scripts [12:10] it supports similar syntax to shell [12:10] ok [12:10] still thats not a reference [12:10] its just examples [12:10] bad doc [12:10] well, as long as it works i dont care :) [12:10] is hushshell some wider standard [12:10] * asac checks google [12:10] no, its uboot specific [12:11] seems not [12:11] yeah [12:11] so ok. as long as it just works ;) [12:11] i'm happy with if, for, while and until :) [12:12] we can write a clever load script now that loads the .scr from predefined locations ... in the scr we can then put all the load commands [12:12] that gives us most flexibility [12:13] it expecially solves the prob that we have to set the UUID on cmdline after install [12:14] BBG U-Boot > if fatinfo mmc 0:0; then echo fat found on partition0; else echo no fat on partition0;fi [12:14] ** Partition 0 not valid on device 0 ** [12:14] ** Unable to use mmc 0:0 for fatinfo ** [12:14] no fat on partition0 [12:14] heh [12:15] BBG U-Boot > if fatinfo mmc 0:2; then echo fat found on partition2; else echo no fat on partition2;fi [12:15] Interface: MMC [12:15] Device 0: Vendor: Man 015041 Snr 41a4343b Rev: 9.4 Prod: SM06G [12:15] Type: Removable Hard Disk [12:15] Capacity: 5743.0 MB = 5.6 GB (11761664 x 512) [12:15] Partition 2: Filesystem: FAT16 " " [12:15] fat found on partition2 [12:15] cute [12:16] * ogra goes to make some coffee and will then work out a little script :) [12:29] hmm first i should enable ext2 i guess [12:30] * asac grabs more coffee while ogra makes good progress [12:30] * asac takes the cheerleader role for now [12:30] heh [12:39] ok, uploaded [12:46] ogra: wait ;) [12:46] to late :) [12:47] ogra: jocote:~asac/fix_fec_warnings.patch [12:47] try that [12:47] let me know if that works, there is a bunch of odd code surrouding that [12:47] will do [12:47] so it could well be that it doesnt and i have to fix a lot of code [12:47] but the warning is gone that way [12:47] but fec_initialize is a mystery code wise ;) [12:47] int mxc_fec_initialize(bd_t *bis) [12:47] { [12:48] for (i = 0; i < sizeof(fec_info) / sizeof(fec_info[0]); i++) { [12:48] feels they are on crack ;) [12:48] heh [12:48] i is used like fec_info[i] [12:48] but lets see ... if it just starts working let me know ... i can do the upload [12:50] i'm doing a testbuild anyway so i can quickly shove that in [12:50] you were too eager ;) [12:50] but well, you probably need some uploads just to excersize [12:50] nah, i just didnt want the changes to get lost :) [12:51] we have anout free version numbers :) [12:51] *enough [12:51] yeah. but if you upload quickly, it will end up with a upload failure [12:51] and the ftbfs will be stuck forever on ubuntuwire [12:51] e.g. .deb doesnt get accepted because newer source is avail [12:52] nah, ubuntuwire is clever enough [12:53] * ogra fires off dpkg-buildpackage ... [12:53] 20min or so [12:59] i wonder if we should have other filesystems too [12:59] ubifs, cramfs and jffs2 might be some that developers might use [13:00] (ext2 passes btw) [13:01] asac, mxc_fec.c passes the build with no errors now [13:01] I'd like ubifs support. [13:01] But I'm not sure I'd want a ubifs /boot, just because it'd be a pain to set up initially. [13:01] right [13:02] its only about /boot atm [13:02] i wonder what would happen if i just enabled USB support :) [13:02] something to play with on a weekend though [13:03] For /boot, don't bother about ubifs or jffs2. [13:03] yeah [13:03] I'm less familiar with cramfs: dunno if that'd be useful. [13:03] ext3 or 4 would be nice, but i doubt anyone ever implemented that [13:03] I *do* want to be able to put / on ubifs, but that's just a kernel thing. [13:03] yeah [13:03] ogra: let me know if it *works* [13:03] i know that the warning is gone ;) [13:03] heh [13:04] I'm not a fan of journaled boot. I use ext2 even on my amd64 systems. [13:04] will do, still building [13:04] just not sure if it works at all because there is strange code [13:04] persia, to avoid fsck [13:04] s$boot$/boot$ [13:04] fsck of 50MB is fast :p [13:04] still slows down the boot [13:04] especially on SD [13:05] I guess. I can't remember the last time I needed to fsck my /boot [13:05] ogra: enable all fs that are available [13:05] unless size explodes of course [13:05] asac, thats overkill [13:05] (but I tend to reboot only for kernel updates) [13:05] not sure how big uboot can be for flash usually [13:05] ogra: its not overkill if size is ok [13:05] otherwise stick with what we have now [13:05] as persia said, its unlikely that anyone puts /boot on ubifs ot jffs2 [13:06] asac: The rationale to *not* enable ubifs or jffs2 for /boot is that these filesystems need separate preparation and writing to flash, which gets ugly and complicated. [13:06] if we enable stuff it should add useful features [13:06] USB would rock [13:06] /boot on jffs2 basically means no kernel updates (in any sane way) [13:06] /boot on ubifs could be made to work, but it'd be a very ugly hack. [13:06] iots like squashfs, isnt it ? [13:07] you would have to recompress it each time [13:07] jffs2 is like squashfs [13:07] ubifs is just different. [13:07] (for a user perspective i mean) [13:07] dont care. if we have reasons against those - and uboot bin gets bigger it can be ignored [13:07] There's a procedure to create an initial filesystem, but writes thereafter are persistent. [13:07] i want usb-storage ;) [13:07] thats more important [13:07] uboot.bin gets surely bigger with each option i enable [13:07] Yes. [13:07] and musb :) [13:08] usb-storage is essential [13:08] but according to FSL it doesnt work [13:08] Depends on who you ask. [13:08] i'll tinker with it in a spare minute some day [13:08] they dont have the code for uboot there yet [13:08] only thing i found was support for some fsl powerpc stuff [13:08] well, should be only the driver init [13:09] I once confused an FSL engineer by demonstrating a redboot provided by FSL that booted from ext2 when told that FSL redboot didn't support ext2. [13:09] USB generally is in uboot [13:09] i know [13:09] see yourself. support isnt there imo [13:09] yes [13:09] but there is a kernel driver [13:10] most uboot drivers are just based on kernel drivers [13:10] ogra: Which means you can port it on saturday ? :) [13:10] asac: no, that's why I was wondering if tobin might know [13:10] nah [13:10] i'm no kernel hacker [13:10] but i can take a look :) [13:11] plars: i remember that we had working dove images [13:11] then at some day you said it broke [13:11] plars, well, according to isotracker tobin didnt test dove at all [13:14] did we have dove for A1 ? [13:14] iirc we didnt [13:22] asac, no go [13:23] still comes up with a MAC of 00:00:00:.... [13:23] SIOCSIFFLAGS Cannot assign requested address ... is what ifconfig gives me on ifconfig eth0 up [13:24] i guess we need FSL help here [13:25] * ogra hugs his USB NIC [13:26] Hi guys... is there an lp bug in the pixman/NEON issues we were seeing? This needs tracking, because we may revert to CONFIG_NEON=n by default... which will make the problem appear to be solved even though it's not. [13:26] s/lp bug in/lp bug on/ [13:28] dmart, Bug #385553 ?? [13:28] Launchpad bug 385553 in pixman "Integrate NEON optimisations for armel" [Wishlist,Fix released] https://launchpad.net/bugs/385553 [13:29] we could recycle that one i assume [13:29] ogra: yeah. i assume the code is completely busted [13:29] it looked really bad hackish [13:29] What code? [13:29] asac, the fun thing is that it defaults to tftpboot [13:29] ogra: the mcx_initialize function [13:29] dmart, different issue :) [13:29] dmart: the uboot fec driver has odd stuff [13:29] Oh, right :) [13:30] seems they moved to an array approach, but only did so at half of the places [13:30] like: [13:30] dmart, seems FEC doesnt get initialized at all when using uboot [13:30] 13:48 < asac> for (i = 0; i < sizeof(fec_info) / sizeof(fec_info[0]); i++) { [13:30] and then they use fec_info[i] [13:30] is that going to work? [13:30] dmart, leaving us without NIC since the kernel cant figure out a MAC for it [13:31] e.i would have expected it to be more like sizeof(struct fec_info_s) [13:31] doesn't look right [13:31] it looks completely wrong ;) [13:31] dmart, you boot with an older uboot, right, do you have NIC support on your babbage ? [13:31] esepecially since the fec_info array is a constant array [13:31] (we might just be able to roll back to an older patch) [13:31] that doesnt grow [13:31] it should just be i < 1 ;)( [13:31] let me check [13:31] Does the NIC work if a MAC is just arbitrarily assigned by userspace later? [13:32] It was on a nettop, and I don't remember whether the network was OK... I didn't check that. [13:32] persia, nope [13:32] Ugh. [13:32] SIOCSIFFLAGS Cannot assign requested address [13:32] no matter what i do [13:32] NIC not promiscuous? [13:32] the HW isnt completely up [13:32] we had such issues before with redboot [13:32] in jaunty iirc [13:34] ogra: get the new patch from same location [13:34] let me first try something [13:34] * ogra issues setenv ethaddr 00:04:9F:00:E8:C2 [13:34] ogra: the _initialize code doesnt initialize anything without that patch [13:34] sizeof(fec_info) / sizeof(fec_info[0]) is probably 0 [13:35] so no device gets initialized [13:35] yeah [13:35] but uboot reports FEC0 as primary interface [13:35] yes [13:35] so it knows its there [13:35] ogra: it knows about it, but doesnt initialize it [13:36] because the loop isnt entered [13:36] yes, thats why i try to check if initialzing it manually changes a thing [13:36] no [13:36] you cant initialize it manually [13:36] because the code that initializes it does nothing ;) [13:37] unless you can run C code at the prompt [13:37] at least i would try that patch first ;) [13:38] e.g. the drivers vtable isnt filled if it really doesnt go in there [13:39] same patch name ? [13:39] yes [13:39] hmm. if it knows the name it seems to have happened. but try anyway [13:40] ah cool, alternates got added to iso tracker today [13:41] yeah [13:41] so i think that is probably 1 ;) ... too bad [13:41] do you see any other errors ogra ? [13:42] just applying the change ... [13:42] one sec, cdbs-edit-patch isnt the fastest on the babbage :) [13:43] ogra: copy the patch in there [13:43] ogra: you should use quilt [13:43] asac, the package is 100% cdbs [13:43] and i wont touch quilt if i dont have to [13:43] its the biggest pain in the ass i've encountered after git [13:43] just replace the patch then :) [13:44] oh wait, then it fails to clean [13:44] hmm. quilt doesnt have that problem ;) [13:45] ogra: if you are still at it, grab a new version of the patch that enables debugging [13:45] CDBS simple-patchsys doesn't have that problem either. [13:45] ARGH! [13:45] fact is that simple-patchsys is for the weak ;) [13:46] did you notice there is fec_mxc.c and mxc_fec.c in the drivers dir [13:46] insanity !!! [13:46] really. the one i touched at least gets compiled ;) [13:46] * asac checks [13:46] Well, someone decided that simple-patchsys was the easiest to teach, so lots of interesting packages end up using it. [13:47] yes, but for professional development - aka if you really fix bugs and touch code - its inferior ;) [13:47] throwing existing patches together is simplest yes [13:47] but rebasing patches that dont apply anymore is a mess ;) [13:47] building [13:47] Depends on one's viewpoint. I also like quilt, which makes me a poor candidate as a simple-patchsys apologist :) [13:47] another 20min ... [13:48] often there are viewpoints/opinions ... but in this case there are only facts :-P [13:48] ogra: make O=debian/build-*/ [13:48] then debuild -nc [13:48] dpkg-buildpackage -b [13:49] i want a proper package to work with [13:49] yeah. thats why it takes 20 instead of 2 minutes [13:49] debuild -nc gives you a good package if you just change one patch [13:51] ok [13:51] me hopes the other fec source isnt used [13:52] me too :) [13:53] but given that the warnings go away after your first fix it doesnt look like [13:53] * ogra takes a coffebreak [13:53] ogra: i would abort the break. the enabling of debug fails to build [13:54] what a bad code :( [14:23] asac, to late to abort it :) [14:28] asac, no change [14:33] ogra: so you didnt pick the DEBUG change? [14:33] ok [14:33] well. then... [14:33] no, i just picked the fec change [14:33] i updated that a minute after you picked it ... thats why i am not sure [14:39] oh, bte, we'Re at 152k for .bin [14:39] vs 136k before switching on ext2 and hush [14:40] *btw [14:43] All, for the pixman issue I raised a new bug #507503 (since the current understanding is that it's not really a pixman bug) [14:43] Launchpad bug 507503 in linux-fsl-imx51 "VFP/NEON state is not preserved around signal handlers, causing state corruption between user processes" [Undecided,New] https://launchpad.net/bugs/507503 [15:08] sihg, is there any way to disable DCC offers in xchat ... [15:08] that spam is driving me insane [15:33] NCommander, do you happen to know if there is any way of command substitution in hush shell ? [15:34] ogra, define command substitution [15:35] files=$(fatls mmc 0:2) [15:36] ogra, yeah, you set the command you want in a variable and then run it [15:36] i.e. [15:36] setenv testcmd fatls mmc 0:2 [15:36] run testcmd [15:36] an that gives me the flie list in the files variable ? [15:36] ogra, oh, no [15:36] i want a variable i can work with [15:36] ogra, can't do that unfortantely [15:36] right, thats what i thought [15:36] * NCommander notes hush is very limited [15:37] yes, found that :) [15:37] How about: [15:37] setenv tmp mmcload ${file} [15:37] run tmp [15:37] (hang on, are you still talking about UBoot?) [15:37] yes :) [15:38] Something like the above might work then [15:38] what i want is some way to detect if uimage exists in a partition/dir [15:38] but i have no grep and fatls is pretty noisy [15:38] ogra, what I did for dove is just try and unconditionally load the boot.scr file [15:38] ogra, if that fails, then assume the uimage is MIA, and move on [15:38] "fatls mmc 0:2 uimage" unfortunately doesnt work [15:38] That might work [15:38] I dunno if fatls/ext2ls return an error code [15:38] ogra, it should work ... [15:38] That does work on Dove I think [15:39] doesnt here [15:39] *grummmmmmble* [15:39] BBG U-Boot > fatls mmc 0:2 uimage [15:39] No Fat FS detected [15:39] BBG U-Boot > fatls mmc 0:2 [15:39] 3085760 uimage [15:39] 3282905 uinitrd [15:39] ? [15:39] it somehow interprets the last parameter [15:39] Hmmm, not sure I ever tried that [15:40] ogra, try fatls mmc 0:2 /uimage [15:40] What does help fatload say? [15:40] it says the last param is a directory :P [15:40] BBG U-Boot > fatls mmc 0:2 / [15:40] 3085760 uimage [15:40] 3282905 uinitrd [15:40] so yes, that works [15:40] but i still dont know if uimage exists [15:40] since i cant parse the return value [15:41] What 's the end goal heer? [15:41] s/heer/here/ [15:41] i want to loop over all fat and ext2 partitions and find if there is a boot.scr [15:42] if boot.scr and uimage exist i want to load boot.scr and execute it [15:42] hmm arm SIMD fast paths are disabled in the pixman in lucid [15:42] ogra, look at how I did it on Dove, and rewrite :-) [15:42] ogra, I only check for boot.scr and not uImage [15:42] boot.scr then should have all env variables needed [15:42] Is there a way only to iterate over partitions that exist, or do we have to be dump and poll everything (slow?) [15:42] argh s/dump/dumb/ [15:42] dmart, the later, but it isn't too bad, only 3-4 seconds on Dove boot time [15:42] for i in 1 2 3 4 5;do if fatls mmc 0:$i;then fatload mmc 0:$i ${loadaddr} uImage; fatload mmc 0:$i ${loadaddr_initrd} uinitrd;fi;done [15:42] dmart, ^^^ that works fine [15:43] and isnt to slow [15:44] ogra, http://paste.ubuntu.com/356625/ [15:44] my point is i want to detect if i'm using a live image or not as the very first thing ... because then i know for sure where what file is [15:44] Can we do something like for ...; do if