--- Log opened Thu Aug 13 00:00:57 2015 | ||
andrzejr | So, I have enabled the cache SR.ICE=1, ICCR.EW=0xff so now the cache is actually being accessed. But it still produces X's on cpu_dat_o so the cpu hangs on "unknown opcode 0xxx". Anything else to set? | 00:48 |
---|---|---|
stekern | andrzejr: what is the code you are trying to run? | 03:09 |
-!- Netsplit *.net <-> *.split quits: antgreen, Shentino | 07:41 | |
-!- Netsplit over, joins: antgreen, Shentino | 07:42 | |
andrzejr | stekern, I'm debugging the hardware, rom and ddr2 i/f, so I wrote a simple testcase in assembler to read/write some RAM locations. | 07:55 |
andrzejr | to summarize: cpu issues bus bursts but initially the (instruction) cache is off so bursts make no difference. I have enabled the cache as shown above but then the cpu hangs (cache returns X's) | 08:02 |
andrzejr | This code (http://pastebin.com/k6urYEp1) hangs 1 instruction after setting SR.ICE=1 - "Unknown opcode 0xxx" (*.mor1kx_icache.cpu_dat_o is stuck on 32'bx) | 08:16 |
latif | olofk: For orpsoc-v2 , I did many things successfully, adding IP modules, booting spi flash ... etc. But I did NOT try to add something in bootrom.v.. My applications (like LED blinker) were made using C language, not by adding something to bootrom.v ...For V3 I could not manage even boot it from spi. So, I could not try something else.. | 08:32 |
latif | olofk: There were a few guy here on this channel and They said that they can boot v3 from spi. I wanted them to send me their bootrom.S bootrom.v and rom.v files. After they sent, I realised that their codes are different from each other and my bootrom.v code (from v2). Then I tried their bootrom codes on my computer but the result was the same again. It ddin NOT work.. I dont know how these guys boot v3 from spi, or are they using an | 08:36 |
stekern | andrzejr: do you invalidate the caches before turning them on? | 09:03 |
olofk | latif: I know that you're having trouble booting from SPI, so I think the best way forward is to try to figure out exactly what the problem is. I can see several potential issues so we should narrow it down a bit first | 10:48 |
olofk | Potential issues could be: | 10:48 |
olofk | 1) The boot ROM is never executed | 10:48 |
olofk | 2) The code fails to read from SPI Flash | 10:49 |
olofk | 3) The code reads at the wrong location from SPI Flash | 10:49 |
olofk | 4) The image is broken in some way | 10:50 |
olofk | 5) The image is not copied properly to RAM | 10:50 |
olofk | 6) Everything is copied ok, but the image in RAM is never executed | 10:50 |
olofk | If you have an oscilloscope it would be great if you could measure the SPI lines to the Flash. That would let us know if it tries to read anything at all | 10:51 |
olofk | My sugggestion of putting a LED blinker in boot ROM was to see if it was executed at all (Issue 1) | 10:52 |
olofk | If you have a debugger, you could read out the RAM to see if anything was written there | 10:53 |
latif | olofk: While I was working on orpsoc-v2, I used an oscilloscope to measure the spi lines on Atlys board. But I did not do it for v3. I will try to do it today. But first, I will not add something to bootrom.. Then I will make the measurments to see wheter the rom is executed. | 11:31 |
olofk | Sounds like a plan. Let me know what happens | 11:32 |
latif | But there is problem.. | 11:32 |
olofk | I started work on improving the booting situation a few months ago, but I have only had time to properly finish it for de0_nano | 11:33 |
latif | which bootrom.v code should I use?? | 11:33 |
latif | the bootrom.v from orpsoc-v2?? | 11:33 |
olofk | I honestly don't know | 11:34 |
latif | or the codes which are sent me by some guys from this channel. :) they are all different.. | 11:34 |
olofk | I guess that since some people have managed to boot from the one in the Atlys port in orpsoc-cores, I guess that should be your first choice | 11:35 |
latif | ok. then. firstly, I will use the bootrom.v code from v2. | 11:35 |
latif | then I will try the others.. | 11:36 |
latif | I will share my measures from here if I can understand something.. | 11:38 |
andrzejr | stekern, that was the issue (or at least a part of it). I did't expect invalidating cache is required but since tags are kept in ram that makes sense | 19:15 |
andrzejr | not sure why, but if I enable cache ways (ICCR.EW) before enabling the cache (SR.ICE) I get some sort of a lock-up. Even when the cache was previously invalidated. | 19:18 |
olofk | wallento: Regarding disabling gdb, IIRC we haven't upstreamed GDB so we're still using the old or1k-src repo to build that | 21:05 |
wallento | ah, okay | 21:05 |
wallento | I was maybe just confusing it | 21:05 |
wallento | thanks olof | 21:06 |
olofk | wallento: This of course makes me a little confused about what the binutils-gdb repo contains :) | 21:07 |
wallento | yes | 21:07 |
wallento | like newlib-cygwin | 21:07 |
wallento | :) | 21:07 |
wallento | how about renaming to mor1kx-doom? ;) | 21:07 |
wallento | thanks for clarifying, I will adapt the automated builds | 21:12 |
olofk | wallento: Ahh.. that's a fork of upstream binutils-gdb? | 21:17 |
wallento | will use or1k-src solely for gdb | 21:17 |
wallento | upstreaming has the same problems as gcc? | 21:18 |
olofk | I don't think so actually. Just that no one has gotten around to do it | 21:18 |
wallento | ah, okay | 21:20 |
--- Log closed Fri Aug 14 00:00:58 2015 |
Generated by irclog2html.py 2.15.2 by Marius Gedminas - find it at mg.pov.lt!