**** BEGIN LOGGING AT Wed Aug 03 23:59:56 2005 Aug 04 00:01:54 beewoolie: No, that's latest cvs - but as far as I can see the sercomm version is the same (minus the endianswap feature now in cvs) Aug 04 00:02:18 How do you mean? Have you checked the source? Aug 04 00:02:53 beewoolie: I know you're probably not interested, but it would be nice to get RedBoot a bit more functional (E.G. setting cmdline) for people who don't dare installing apex ;) Aug 04 00:03:17 You're right. I'm less than interested. Aug 04 00:03:22 beewoolie: yes, I checked the nslu2 sources from linksys - presumably that's what is in there Aug 04 00:03:37 beewoolie ;) Aug 04 00:03:51 It is possible that the nslu2 version doesn't use that code. Aug 04 00:03:58 That's part of the reason that I don't like redboot. Aug 04 00:04:05 It's really hard to tell what code is being executed. Aug 04 00:04:19 beewoolie: what was actually your motivation for writing yet another bootloader? Aug 04 00:04:27 The use so many macros that it requires a complete understanding of the code in order to modify it. Aug 04 00:04:37 since you asked, no Aug 04 00:04:55 I write APEX because blob suffers from some of the same problems. Aug 04 00:05:11 On my targets, the Sharp LH processors, I had a choice between blob and uboot. Aug 04 00:05:30 beewoolie: yes, it takes a bit of getting used to - but once you know it I actually think it's really nicely structured - you have generic->arch->variant->platform and you can always override if the layer above you doesn't fit you Aug 04 00:05:32 Both are quite awful because of how difficult they are to configure. Aug 04 00:05:47 I call that overdesign. Aug 04 00:06:09 It doesn't cope with the sorts of things that I care about. Aug 04 00:06:21 I want to be able to add and remove features quickly and reliably. Aug 04 00:06:22 well, uboot isn't called the universal bootloader for nothing ;) Aug 04 00:06:40 Uh huh. I've had plenty of experience with it and the author. Aug 04 00:06:49 It has some of the most irritating features. Aug 04 00:07:00 For example, it requires that all kernel images be prefixed with a header. Aug 04 00:07:03 Blech. Aug 04 00:07:11 beewoolie: come on, it's always fun to read wdenx's postings ;) Aug 04 00:08:04 beewoolie: well, that's just to keep metadata - I find it kinda neat - it's kinda similar to the FIS in redboot Aug 04 00:08:05 I don't have much of a sense of humor about it. I wasted several weeks worth of good effort. Denk wouldn't merge it and would only throw tantrums because some of my lines had whitespace at the end. Aug 04 00:08:25 That is a perfect example of an overgeneralization. Aug 04 00:08:45 A small group of users who like and need the feature are inconvenienced by it. Aug 04 00:09:16 true - he's hard, but I guess he needs to be to keep it from getting messy Aug 04 00:09:27 A better solution, IMHO, would be to append an executable header that could store the metadata, but wouldn't change the usability of the file. Aug 04 00:09:35 There is no reason for his tantrum. Aug 04 00:09:46 A simple script to strip the whitespace would have sufficed. Aug 04 00:09:53 Moreover, it is a trite complaint. Aug 04 00:10:13 APEX uses the kernel build system and it's configurator. Aug 04 00:10:20 Much much easier to work with. Aug 04 00:10:27 beewoolie: I don't see much difference between having the metadata before or after the image Aug 04 00:10:29 And, the build process is nearly optimal. Aug 04 00:10:41 Append doesn't mean 'after'. Aug 04 00:11:08 what do you mean then? Aug 04 00:11:09 The metadata could be a prefix on the file with a jump instruction to the real first intruction of the file. Aug 04 00:11:56 append: To fix to; attach: append a charm to the bracelet. Aug 04 00:12:23 beewoolie: yes it could, but as the uImage header is always 64bytes you could just execute from there Aug 04 00:12:24 A magic number in the file would let the metadata be recognizable. Aug 04 00:12:34 You miss the point. Aug 04 00:12:48 Kernel images are used in a uniform manner in every other situation. Aug 04 00:13:08 uImages are the *only* ones that don't execute from the first instruction. Aug 04 00:13:19 First word, that is. Aug 04 00:13:47 I cannot count the number of times I've seen messages on the list about the inability of users to boot Linux from uboot because of this. Aug 04 00:14:23 beewoolie: well, you cannot blaim uboot for the fact that users don't rtfm ;) Aug 04 00:14:37 it's like the path separator in Dos. Fine, once you get used to it. A perfectly stupid idea nonetheless. Aug 04 00:14:42 yes I can. Aug 04 00:14:52 It is a poorly conceieved idea. Aug 04 00:15:11 Kernel users don't really need it, either. Denk implemented it for his runtime tests. Aug 04 00:15:38 Users should not need to read the manual when there is a long history of others who have implemented something similar. Aug 04 00:15:41 a matter of opinion as always - I find it a relatively nice and simple solution Aug 04 00:15:50 Solution to what? Aug 04 00:16:16 attaching metadata to a binary blob Aug 04 00:16:25 ...and I wrote another boot loader so that I could make progress instead of reading his childish rants. Aug 04 00:16:42 In what way is this metadata interesting? it isn't even generalized? Aug 04 00:17:07 I cannot add comments or other arbitrary data. Aug 04 00:17:15 start address, image type, checksum, compression mode, .. Aug 04 00:17:29 Don't need any of that for kernel images. Aug 04 00:17:56 Start address is always the first word. Image type is irrelevent. Checksum isn't useful because the decompressor already checks it....and so on. Aug 04 00:18:12 compression and crc are interestring if you don't use a zImage Aug 04 00:18:23 I've never wanted to use anything else. Aug 04 00:18:52 And, as I said, it is very interesting to Denk and his customers who write stand-alone applications. Aug 04 00:19:02 Not very interesting to kernel users. Aug 04 00:19:41 It's nice if you already have zlib/bzip2/lzma support in yout bootloader (for E.G. fpga bitstreams) instead of ending up with yet another copy of zlib for each image Aug 04 00:21:17 but it's fine that you wrote a new loader - I was just wondering what you found lacking in the others Aug 04 00:21:18 For the kernel, this isn't that interesting. FPGA, sure. Aug 04 00:21:52 I probably have my 'I hate uboot' list around here somewhere, right next to the I hate blob list. Aug 04 00:22:06 heh ;) Aug 04 00:22:12 * Jacmet actually likes redboot Aug 04 00:22:30 but we do quite some eCos stuff, so that's probably why ;) Aug 04 00:22:33 Too bad you weren't around earlier. Aug 04 00:22:53 Someone was trying to get reboot to init 128MB slugs. As far as I can tell, no one was successful. Aug 04 00:23:27 odd, it shouldn't be more than a few lines of changes Aug 04 00:23:41 Search me. Aug 04 00:24:41 * Jacmet greps beewoolie .. Aug 04 00:24:55 tee hee. That tickles. Aug 04 00:25:09 ;) Aug 04 00:26:09 ok, I'll get jtag going then an recompile Redboot with some debugging prints to figure out the ATAG problem.. Aug 04 00:30:34 beewoolie: there's btw a little typo in README_build: Recusring Directories Aug 04 00:31:14 In APEX? Aug 04 00:31:48 beewoolie: yes, in 1.3.0 Aug 04 00:31:59 I'll check on it. thx. Aug 04 00:32:39 One of the main reasons I wrote APEX has to do with the way it extends things like ATAGS. Have you looked a the APEX code? Aug 04 00:32:57 beewoolie: only for around 30secs by now ;) Aug 04 00:33:13 beewoolie: I'll have a look - file? Aug 04 00:33:15 It uses linker sections the way that the kernel does. Aug 04 00:33:35 Look at the linker script and then look at some of the services and commands. Aug 04 00:34:30 ahh, ok - like Redboot does it for new commands and so on Aug 04 00:35:06 src/arch-arm/entry/apex.lds.S, src/apex/*.c Aug 04 00:35:22 Redboot doesn't use it for the startup code. Last I looked, it was all macros. Aug 04 00:36:07 I also don't think that redboot can start from RAM with the same image it runs from flash. Aug 04 00:37:14 beewoolie: no, Redboot is position dependent - and there's different configurations for RAM/ROM/ROMRAM startup (memcontroller init, ..) Aug 04 00:37:18 rwhitby-away: BTW, I'm building a new compiler. Aug 04 00:37:52 rwhitby-away: The latest crosstool wants to build 4.1.2 for ARM. So, I'll try that one first. Aug 04 00:38:12 Jacmet: The Logic PD loader is the same way. Very inconvenient. Aug 04 00:38:30 I was going for easy of use. Aug 04 00:42:31 Jacmet: One of the things I wanted to do was be able to run from SRAM. The automatic reloc code makes it easy to bootstrap without erasing flash in the first go. Aug 04 00:43:25 Also, the program image is immutable. The code as it appears in flash is the same code in SDRAM and can be written from SDRAM directly to flash. blob doesn't work this way. Aug 04 00:47:12 beewoolie: that's indeed a nice feature Aug 04 00:48:07 with Redboot you end up needing a RAM version to update a ROM version (unless you use ROMRAM) Aug 04 00:49:07 IIRC, redboot is hampered by the x86 legacy which is much more difficult when it comes to PIC code. Aug 04 00:49:37 ARM has very handy register handling that makes PIC calls feasible. Aug 04 00:50:04 well, the scope is ofcause also a lot bigger than apex as redboot supports 11 archs Aug 04 00:50:38 Just give me some time... Aug 04 00:50:57 ;) Aug 04 00:51:06 Jacmet: have a look at Sluggo for the work so far on recompiling RedBoot Aug 04 00:51:37 dyoung was doing that work Aug 04 00:51:40 rwhitby-treo: yo. I'm building a new toolchain. Aug 04 00:51:57 it's in the cvs at nslu.sf.net - see the wiki page Aug 04 00:52:08 beewoolie: yeah, saw that. Aug 04 00:52:24 um, gotta go - back in 45 Aug 04 00:54:28 rwhitby-away: ok Aug 04 02:32:29 is there some way I can test the memory with apex? Aug 04 02:47:31 DaKa2: There's nothing explicit in the code to test ram. Aug 04 02:47:45 The best way to test it is to use it. :-) Aug 04 02:48:05 :) Aug 04 02:48:10 ok.. Aug 04 02:48:22 I should try and boot the kernel then.. Aug 04 02:48:26 It does search memory to make sure it has the right stuff. Aug 04 02:48:43 IOW, it makes sure that it eliminates aliased regions. Aug 04 02:48:57 Does APEX start on your target? Aug 04 02:49:04 should booting the kernel work when running from sdram? Aug 04 02:49:11 nslu2 :) Aug 04 02:49:38 Uncompressing Linux..........................................................crc error -- System halted Aug 04 02:51:34 DaKa2: Yeah. That's what I'm looking into. Aug 04 02:51:54 I know that you folks are using a different compiler. Aug 04 02:51:57 Than I am. Aug 04 02:52:02 beewoolie-afk: oh.. Aug 04 02:52:07 I'm building a 3.4.4 compiler so I can test it. Aug 04 02:52:19 I've noticed that the code stream is different in subtle ways. Aug 04 02:52:25 I don't know if it breaks things. Aug 04 02:52:34 I used crosstool 0.38 actually, and skipped the OE cross env Aug 04 02:52:44 Ah. Which compiler are you using? Aug 04 02:53:08 good question... Aug 04 02:53:19 I just built gcc-3.4.4-glibc-2.3.5 Aug 04 02:53:32 I used gcc-3.4.0-glibc-2.3.2 Aug 04 02:53:35 It isn't in the default set of compilers that crosstool-0.38 builds for arm. Aug 04 02:53:44 Hmm. Interesting. Aug 04 02:54:09 Would you paste the version command output from APEX into pastebin for me? Aug 04 02:54:50 BTW, I'm using gcc-3.4.2-glibc-2.3.3 from crosstool-0.32 Aug 04 02:55:49 beewoolie-afk: http://pastebin.com/329084 Aug 04 02:57:19 thx Aug 04 03:04:25 DaKa2: Are you booting APEX from flash? Aug 04 03:04:52 no, sdram Aug 04 03:05:32 Um, then how are you getting 64MB of SDRAM? Aug 04 03:05:48 two banks of 32Mb? Aug 04 03:06:02 I didn't change anything in the source.. Aug 04 03:06:06 Right. Did you recompile redboot to initialize SDRAM? Aug 04 03:06:16 uhm, no? Aug 04 03:06:48 Maybe I'm crazy, but the machine comes with 32, right? Aug 04 03:06:53 You added some RAM. Aug 04 03:07:12 yes, maybe forgot to say that.. Aug 04 03:07:17 :) Aug 04 03:07:24 OK. So, there should only be 32MB recognizded. Aug 04 03:08:53 Can you do me a favor? I'd like to see the config on the memory controller. Aug 04 03:09:30 apex> du -4 0xcc000000#32 Aug 04 03:09:54 hm.. my slug no longer boots.. I think I managed to break the power on circuit... have to fix that first.. Aug 04 03:09:57 dammit Aug 04 03:10:09 it's not getting power.. Aug 04 03:10:25 sorry to hear it. Aug 04 03:10:47 well, I should probably be able to fix it, and then check that config Aug 04 03:12:20 According to [g2], APEX works fine in a system with 128MB of ram. I also think he's seen it working with 64MB, but of that I am not sure. Aug 04 03:12:46 I believe we're up against some sort of problem with the SDRAM init for you folks who have reconfigured memory. Aug 04 03:12:47 he is running one with 64Mb Aug 04 03:13:23 APEX won't do anything to the SDRAM config when it is being executed from SDRAM since that could be fatal. Aug 04 03:14:59 I'm gonna hafta bust my slug appart again so I can test this running from ram thing. Aug 04 03:18:23 DaKa2: Is your slug de-underclocked, too? Aug 04 03:18:52 beewoolie-afk: yep.. Aug 04 03:19:16 I wish there were an easy way to determine that. Aug 04 03:19:20 From software. Aug 04 03:21:11 sleep time. Aug 04 03:21:13 cheers Aug 04 03:53:17 now that it boots beewoolie went to sleep :-) Aug 04 03:55:59 just for the log so I can give it to beewoolie later: Aug 04 03:56:00 apex> du -4 0xcc000000#32 Aug 04 03:56:00 cc000000: 00000018 00000081 00000006 80000822 ........ ......." Aug 04 03:56:00 cc000010: 00001e17 00000a7f 00001e17 00000000 ........ ........ Aug 04 06:11:24 hm.. when I compile apex for just the first bank things work and I can boot, but when I compile for both banks it fails Aug 04 06:12:08 I guess that is because Im running from sdram and apex cannot initialise the sdram controller for the sezzond bank.. Aug 04 06:12:13 seccond* Aug 04 06:12:39 second* Aug 04 06:13:08 or.. it could be that by second bank of chips is broken.. Aug 04 13:01:15 is there nothing out there OSS wise that will allow me to step through code on the device letting me see the registers? **** BEGIN LOGGING AT Thu Aug 04 16:56:32 2005 **** BEGIN LOGGING AT Thu Aug 04 20:26:32 2005 Aug 04 20:50:24 test Aug 04 20:51:12 This channel is now logged http://www.loglibrary.com/show_page/latest/187 . Aug 04 20:51:14 FYI. Aug 04 20:51:38 paid for by the generous donations of nslu2-linux users. Aug 04 20:57:53 I have my boatload of MCP120-450's too Aug 04 20:58:00 whoops. **** ENDING LOGGING AT Thu Aug 04 23:59:56 2005