--- Begin Message ---
Subject: |
PPC 405 board |
Date: |
Fri, 29 Jun 2007 08:41:43 -0700 |
I starting trying the qemu PPC system emulation for the 405 boards and
ran into an issue with where the board info pointer is located in
memory. The first Linux MMU entry only covers the first few megs of RAM
and the current code puts the bdloc at the very top of memory. And when
the kernel tries to copy the data it fails.
So this little patch just moves the location down into the first 16
Meg, like U-boot does. And I am able to boot the kernel after that.
Index: ppc405_uc.c
===================================================================
RCS file: /sources/qemu/qemu/hw/ppc405_uc.c,v
retrieving revision 1.4
diff -u -r1.4 ppc405_uc.c
--- ppc405_uc.c 8 Jun 2007 16:45:23 -0000 1.4
+++ ppc405_uc.c 29 Jun 2007 15:39:56 -0000
@@ -74,8 +74,8 @@
ram_addr_t bdloc;
int i, n;
- /* We put the bd structure at the top of memory */
- bdloc = bd->bi_memsize - sizeof(struct ppc4xx_bd_info_t);
+ /* We put the bd structure at the top of 16 Meg of memory */
+ bdloc = (16 << 20) - sizeof(struct ppc4xx_bd_info_t);
stl_raw(phys_ram_base + bdloc + 0x00, bd->bi_memstart);
stl_raw(phys_ram_base + bdloc + 0x04, bd->bi_memsize);
stl_raw(phys_ram_base + bdloc + 0x08, bd->bi_flashstart);
--- End Message ---
--- Begin Message ---
Subject: |
confirm c706d5543bb900051bd78f15bd99825cb5fcbf18 |
If you reply to this message, keeping the Subject: header intact,
Mailman will discard the held message. Do this if the message is
spam. If you reply to this message and include an Approved: header
with the list password in it, the message will be approved for posting
to the list. The Approved: header can also appear in the first line
of the body of the reply.
--- End Message ---