source: rtems/c/src/lib/libbsp/arm/xilinx-zynq/configure.ac @ 8100e71

4.11
Last change on this file since 8100e71 was 8100e71, checked in by Sebastian Huber <sebastian.huber@…>, on Nov 12, 2014 at 1:02:53 PM

bsp/xilinx-zynq: Adjust BSP_ARM_A9MPCORE_PERIPHCLK

  • Property mode set to 100644
File size: 5.4 KB
Line 
1##
2#
3# @file
4#
5# @brief Configure script of LibBSP for the Xilinx Zynq platform.
6#
7
8AC_PREREQ([2.69])
9AC_INIT([rtems-c-src-lib-libbsp-arm-xilinx-zynq-a9],[_RTEMS_VERSION],[http://www.rtems.org/bugzilla])
10AC_CONFIG_SRCDIR([bsp_specs])
11RTEMS_TOP(../../../../../..)
12
13RTEMS_CANONICAL_TARGET_CPU
14AM_INIT_AUTOMAKE([no-define nostdinc foreign 1.12.2])
15RTEMS_BSP_CONFIGURE
16
17RTEMS_PROG_CC_FOR_TARGET
18RTEMS_CANONICALIZE_TOOLS
19RTEMS_PROG_CCAS
20
21RTEMS_CHECK_NETWORKING
22AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes")
23
24RTEMS_BSPOPTS_SET([BSP_START_RESET_VECTOR],[*],[])
25RTEMS_BSPOPTS_HELP([BSP_START_RESET_VECTOR],[reset vector address for BSP start])
26
27RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_PERIPHCLK],[xilinx_zynq_zc702*],[333333333U])
28RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_PERIPHCLK],[xilinx_zynq_zedboard*],[666666667U])
29RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_PERIPHCLK],[*],[100000000U])
30RTEMS_BSPOPTS_HELP([BSP_ARM_A9MPCORE_PERIPHCLK],[ARM Cortex-A9 MPCore PERIPHCLK clock frequency in Hz])
31
32RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_UARTCLK],[xilinx_zynq_zc702*],[50000000UL])
33RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_UARTCLK],[xilinx_zynq_zedboard*],[50000000UL])
34RTEMS_BSPOPTS_SET([BSP_ARM_A9MPCORE_UARTCLK],[*],[50000000UL])
35RTEMS_BSPOPTS_HELP([BSP_ARM_A9MPCORE_UARTCLK],[ARM Cortex-A9 MPCore UART 0 clock frequency in Hz])
36
37USE_FAST_IDLE=0
38AS_IF([test "x${RTEMS_BSP}" == xxilinx_zynq_a9_qemu], [USE_FAST_IDLE=1])
39
40RTEMS_BSPOPTS_SET([CLOCK_DRIVER_USE_FAST_IDLE],[*qemu],[${USE_FAST_IDLE}])
41RTEMS_BSPOPTS_HELP([CLOCK_DRIVER_USE_FAST_IDLE],
42[This sets a mode where the time runs as fast as possible when a clock ISR
43occurs while the IDLE thread is executing.  This can significantly reduce
44simulation times.])
45
46RTEMS_BSPOPTS_SET([BSP_CONSOLE_MINOR],[*],[1])
47RTEMS_BSPOPTS_HELP([BSP_CONSOLE_MINOR],[minor number of console device])
48
49ZYNQ_CPUS="1"
50RTEMS_CHECK_SMP
51AM_CONDITIONAL(HAS_SMP,[test "$rtems_cv_HAS_SMP" = "yes"])
52AS_IF([test "$rtems_cv_HAS_SMP" = "yes"],
53      [ZYNQ_CPUS="2"])
54
55#
56# Zynq Memory map can be controlled from the configure command line. Use ...
57#
58#   ..../configure --target=arm-rtems4.11 ... BSP_ZYNQ_RAM_LENGTH=256M
59#
60RTEMS_BSPOPTS_SET([BSP_ZYNQ_RAM_LENGTH],[xilinx_zynq_a9_qemu],[256M])
61RTEMS_BSPOPTS_SET([BSP_ZYNQ_RAM_LENGTH],[xilinx_zynq_zc702],[1024M])
62RTEMS_BSPOPTS_SET([BSP_ZYNQ_RAM_LENGTH],[xilinx_zynq_zc706],[1024M])
63RTEMS_BSPOPTS_SET([BSP_ZYNQ_RAM_LENGTH],[xilinx_zynq_zedboard],[512M])
64RTEMS_BSPOPTS_SET([BSP_ZYNQ_RAM_LENGTH],[*],[256M])
65RTEMS_BSPOPTS_HELP([BSP_ZYNQ_RAM_LENGTH],[override a BSP's default RAM length])
66
67AS_IF([test "x${RTEMS_BSP}" == xxilinx_zynq_a9_qemu],
68      [ZYNQ_RAM_ORIGIN="0x00000000"
69       ZYNQ_RAM_MMU="0x0fffc000"
70       ZYNQ_RAM_MMU_LENGTH="16k"
71       ZYNQ_RAM_ORIGIN_AVAILABLE="${ZYNQ_RAM_ORIGIN}"
72       ZYNQ_RAM_LENGTH_AVAILABLE="${BSP_ZYNQ_RAM_LENGTH} - 16k"
73       ZYNQ_RAM_INT_0_ORIGIN="0x00000000"
74       ZYNQ_RAM_INT_0_LENGTH="64k + 64k + 64k"
75       ZYNQ_RAM_INT_1_ORIGIN="0xFFFF0000"
76       ZYNQ_RAM_INT_1_LENGTH="64k - 512"])
77
78AS_IF([test "x${RTEMS_BSP}" == xxilinx_zynq_zc702],
79      [ZYNQ_RAM_ORIGIN="0x00100000"
80       ZYNQ_RAM_MMU="${ZYNQ_RAM_ORIGIN}"
81       ZYNQ_RAM_MMU_LENGTH="16k"
82       ZYNQ_RAM_ORIGIN_AVAILABLE="${ZYNQ_RAM_ORIGIN} + 0x00004000"
83       ZYNQ_RAM_LENGTH_AVAILABLE="${BSP_ZYNQ_RAM_LENGTH} - 1M - 16k"
84       ZYNQ_RAM_INT_0_ORIGIN="0x00000000"
85       ZYNQ_RAM_INT_0_LENGTH="64k + 64k + 64k"
86       ZYNQ_RAM_INT_1_ORIGIN="0xFFFF0000"
87       ZYNQ_RAM_INT_1_LENGTH="64k - 512"])
88
89AS_IF([test "x${RTEMS_BSP}" == xxilinx_zynq_zc706],
90      [ZYNQ_RAM_ORIGIN="0x00400000"
91       ZYNQ_RAM_MMU="${ZYNQ_RAM_ORIGIN}"
92       ZYNQ_RAM_MMU_LENGTH="16k"
93       ZYNQ_RAM_ORIGIN_AVAILABLE="${ZYNQ_RAM_ORIGIN} + 0x00004000"
94       ZYNQ_RAM_LENGTH_AVAILABLE="${BSP_ZYNQ_RAM_LENGTH} - 4M - 16k"
95       ZYNQ_RAM_INT_0_ORIGIN="0x00000000"
96       ZYNQ_RAM_INT_0_LENGTH="64k + 64k + 64k"
97       ZYNQ_RAM_INT_1_ORIGIN="0xFFFF0000"
98       ZYNQ_RAM_INT_1_LENGTH="64k - 512"])
99
100AS_IF([test "x${RTEMS_BSP}" == xxilinx_zynq_zedboard],
101      [ZYNQ_RAM_ORIGIN="0x00100000"
102       ZYNQ_RAM_MMU="${ZYNQ_RAM_ORIGIN}"
103       ZYNQ_RAM_MMU_LENGTH="16k"
104       ZYNQ_RAM_ORIGIN_AVAILABLE="${ZYNQ_RAM_ORIGIN} + 0x00004000"
105       ZYNQ_RAM_LENGTH_AVAILABLE="${BSP_ZYNQ_RAM_LENGTH} - 1M - 16k"
106       ZYNQ_RAM_INT_0_ORIGIN="0x00000000"
107       ZYNQ_RAM_INT_0_LENGTH="64k + 64k + 64k"
108       ZYNQ_RAM_INT_1_ORIGIN="0xFFFF0000"
109       ZYNQ_RAM_INT_1_LENGTH="64k - 512"])
110
111AC_DEFUN([ZYNQ_LINKCMD],[
112AC_ARG_VAR([$1],[$2; default $3])dnl
113[$1]=[$]{[$1]:-[$3]}
114])
115
116ZYNQ_LINKCMD([ZYNQ_CPUS],[Number of active cores],[${ZYNQ_CPUS}])
117ZYNQ_LINKCMD([ZYNQ_RAM_ORIGIN],[normal RAM region origin],[${ZYNQ_RAM_ORIGIN}])
118ZYNQ_LINKCMD([ZYNQ_RAM_LENGTH],[normal RAM region length],[${BSP_ZYNQ_RAM_LENGTH}])
119ZYNQ_LINKCMD([ZYNQ_RAM_MMU],[MMU region origin],[${ZYNQ_RAM_MMU}])
120ZYNQ_LINKCMD([ZYNQ_RAM_MMU_LENGTH],[MMU region length],[${ZYNQ_RAM_MMU_LENGTH}])
121ZYNQ_LINKCMD([ZYNQ_RAM_ORIGIN_AVAILABLE],[origin of available RAM],[${ZYNQ_RAM_ORIGIN_AVAILABLE}])
122ZYNQ_LINKCMD([ZYNQ_RAM_LENGTH_AVAILABLE],[length of available RAM],[${ZYNQ_RAM_LENGTH_AVAILABLE}])
123ZYNQ_LINKCMD([ZYNQ_RAM_INT_0_ORIGIN],[internal 0 RAM region origin],[${ZYNQ_RAM_INT_0_ORIGIN}])
124ZYNQ_LINKCMD([ZYNQ_RAM_INT_0_LENGTH],[internal 0 RAM region length],[${ZYNQ_RAM_INT_0_LENGTH}])
125ZYNQ_LINKCMD([ZYNQ_RAM_INT_1_ORIGIN],[internal 1 RAM region origin],[${ZYNQ_RAM_INT_1_ORIGIN}])
126ZYNQ_LINKCMD([ZYNQ_RAM_INT_1_LENGTH],[internal 1 RAM region length],[${ZYNQ_RAM_INT_1_LENGTH}])
127
128RTEMS_BSP_CLEANUP_OPTIONS(0, 1)
129
130AC_CONFIG_FILES([
131Makefile
132startup/linkcmds])
133AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.