Success! Subscription added.
Success! Subscription removed.
Sorry, you must verify to complete this action. Please click the verification link in your email. You may re-send via your profile.
For basics on getting started with U-Boot, read DasUBoot.
These instructions assume you have generated the file custom_fpga.h for your design, as described in Linux.
When porting U-Boot to a Nios II with an MMU, you have to take the memory map into account.
The Nios II Memory partitions are defined as follows:
Partition | Virtual Address Range | Used By | Memory Access | User Mode Access | Default Data Cacheability |
I/O (1) | 0xE0000000–0xFFFFFFFF | Operating system | Bypasses TLB | No | Disabled |
Kernel (1) | 0xC0000000–0xDFFFFFFF | Operating system | Bypasses TLB | No | Enabled |
Kernel MMU (1) | 0x80000000–0xBFFFFFFF | Operating system | Uses TLB | No | Set by TLB |
User | 0x00000000–0x7FFFFFFF | User processes | Uses TLB | Set by TLB | Set by TLB |
(1) Supervisor-only partition
(From Nios II Processor Reference Handbook, Table 3-2.)
The high four bits of the address are used to define which partition the memory appears in.
Your custom_fpga.h probably shows that all the devices are down in the "User" section. For example, my JTAG_UART_BASE is at 0x21208B0.
For U-Boot use the JTAG UART, it has to be in the I/O Address area. Fortunately, you do not need to change the design. You just need to address it as if it is there, at 0xE21208B0.
The same applies to flash. Your Flash Base Address is probably down at 0x00000000. To write flash, U-Boot needs to see it at 0xE0000000. This is where you need to define it at for your board configuration. To boot, it needs to see it at the RESET_ADDR, which is 0xC0000000. If you burn the U-Boot image to 0xE0000000, it will be there at 0xC0000000.
Community support is provided Monday to Friday. Other contact methods are available here.
Intel does not verify all solutions, including but not limited to any file transfers that may appear in this community. Accordingly, Intel disclaims all express and implied warranties, including without limitation, the implied warranties of merchantability, fitness for a particular purpose, and non-infringement, as well as any warranty arising from course of performance, course of dealing, or usage in trade.
For more complete information about compiler optimizations, see our Optimization Notice.