Nios® V/II Embedded Design Suite (EDS)
Support for Embedded Development Tools, Processors (SoCs and Nios® V/II processor), Embedded Development Suites (EDSs), Boot and Configuration, Operating Systems, C and C++
公告
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.

kernal build on custom board

Altera_Forum
名誉分销商 II
1,205 次查看

I am trying to build the uC linux kernal for a custom board. I am not using an Altera or Microtronix board. The kernal build fails wrt the JTAG UART. It fails, apparently, in the same spot whether or not the JTAG UART is part of the NIOS core or not. 

 

Any thoughts here? IRQ number wrong? Base address wrong? Something I have to change when configuring the kernal? 

 

Here is a list of the errors: Any and all help is much appreciated by this non-linux rookie. 

 

 

CC drivers/serial/altera_juart.o 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:347: error: `na_jtag_uart' undeclared here (not in a function) 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:347: error: initializer element is not constant 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:347: error: (near initialization for `juart_ports[0].port.membase') 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:348: error: `na_jtag_uart' undeclared here (not in a function) 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:348: error: initializer element is not constant 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:348: error: (near initialization for `juart_ports[0].port.mapbase') 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:350: error: `na_jtag_uart_irq' undeclared here (not in a function) 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:350: error: initializer element is not constant 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:350: error: (near initialization for `juart_ports[0].port.irq') 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:356: error: initializer element is not constant 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:356: error: (near initialization for `juart_ports[0].port') 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:357: error: initializer element is not constant 

/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x/drivers/serial/altera_juart.c:357: error: (near initialization for `juart_ports[0]') 

make[3]: *** [drivers/serial/altera_juart.o] Error 1 

make[2]: *** [drivers/serial] Error 2 

make[1]: *** [drivers] Error 2 

make: *** [all] Error 2 

make: Leaving directory `/cygdrive/c/altera/kits/nios2/bin/eclipse/plugins/com.microtronix.nios2linux.kernel_0.1.5/linux-2.6.x'
0 项奖励
3 回复数
Altera_Forum
名誉分销商 II
459 次查看

The first line, 

error: `na_jtag_uart' undeclared here (not in a function) 

means that the compiler can't find the expected symbol for the jtag uart. In SOPC-builder, rename the jtag uart to "jtag_uart", regenerate and try again.  

 

You might get more errors of the same kind if you have not named the modules exactly as the kernel expects them to be.
0 项奖励
Altera_Forum
名誉分销商 II
459 次查看

Much appreciated - I'll give it a shot. Now, if only Microtronix supplied a listing of what peripherals are required and what they are called.....

0 项奖励
Altera_Forum
名誉分销商 II
459 次查看

Sorry about that... 

 

It'll be fixed in the next release. Our maintenance release will coincide with the release of Nios II I.1
0 项奖励
回复