Ignore:
Timestamp:
Nov 3, 2014, 6:53:40 PM (6 years ago)
Author:
Ben Gras <beng@…>
Branches:
4.11, 5, master
Children:
a2e1e30d
Parents:
7a66986
git-author:
Ben Gras <beng@…> (11/03/14 18:53:40)
git-committer:
Joel Sherrill <joel.sherrill@…> (11/03/14 20:19:47)
Message:

BSP for several Beagle products

Specifically the beagleboard, beagleboard xM, beaglebone, beaglebone black.

More info on these targets: http://www.beagleboard.org/

This commit forms a basic BSP by combining Claas's work with

. new clock and irq code and definitions for

beagle targets (beagleboard and beaglebones), mostly
reused from the Minix codebase, thus making
irqs, ticks and non-polled console mode work too

. new timer code for ns timing with high timer resolution,

24MHz on the AM335X and 13MHz on the DM37XX

. select the console uart based on target at configure time
. removing all the lpc32xx-specific macros and code and

other unused code and definitions that the beagle bsp
was based on

. re-using some standard functions instead of lpc32xx versions
. fixed some whitespace problem in preinstall.am
. fixed some compile warnings
. configure MMU: set 1MB sections directly in the TTBR,

just to show the difference between cacheable RAM and
non-cacheable device memory and invalid ranges; this lets us
turn on caches and not rely on boot loader MMU configuration.
Verified to work when MMU is initially either on or off when
RTEMS gets control.

Thanks for testing, commentary, improvements and fixes to Chris Johns,
Brandon Matthews, Matt Carberry, Romain Bornet, AZ technology and others.

Signed-Off-By: Ben Gras <beng@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/arm/beagle/configure.ac

    r7a66986 r53dd6d61  
    1919RTEMS_PROG_CCAS
    2020
    21 RTEMS_CHECK_NETWORKING
    22 AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes")
     21RTEMS_BSPOPTS_SET([IS_DM3730],[beagleboard*],[1])
     22RTEMS_BSPOPTS_HELP([IS_DM3730],[true if SOC is DM3730])
    2323
    24 RTEMS_BSPOPTS_SET([BSP_SMALL_MEMORY],[beagle_mzx_stage_1],[1])
    25 RTEMS_BSPOPTS_SET([BSP_SMALL_MEMORY],[*],[])
    26 RTEMS_BSPOPTS_HELP([BSP_SMALL_MEMORY],[disable testsuite samples with high memory demands])
     24RTEMS_BSPOPTS_SET([IS_AM335X],[beaglebone*],[1])
     25RTEMS_BSPOPTS_HELP([IS_AM335X],[true if SOC is AM335X])
    2726
    28 RTEMS_BSPOPTS_SET([BEAGLE_OSCILLATOR_MAIN],[*],[13000000U])
    29 RTEMS_BSPOPTS_HELP([BEAGLE_OSCILLATOR_MAIN],[main oscillator frequency in Hz])
     27RTEMS_BSPOPTS_SET([CONSOLE_BAUD],[*],[115200])
     28RTEMS_BSPOPTS_HELP([CONSOLE_BAUD],[initial baud for console UART])
    3029
    31 RTEMS_BSPOPTS_SET([BEAGLE_OSCILLATOR_RTC],[*],[32768U])
    32 RTEMS_BSPOPTS_HELP([BEAGLE_OSCILLATOR_RTC],[RTC oscillator frequency in Hz])
    33 
    34 RTEMS_BSPOPTS_SET([BEAGLE_PERIPH_CLK],[*],[13000000U])
    35 RTEMS_BSPOPTS_HELP([BEAGLE_PERIPH_CLK],[peripheral clock in Hz])
    36 
    37 RTEMS_BSPOPTS_SET([BEAGLE_ETHERNET_RMII],[*],[1])
    38 RTEMS_BSPOPTS_HELP([BEAGLE_ETHERNET_RMII],[enable RMII for Ethernet])
    39 
    40 RTEMS_BSPOPTS_SET([BEAGLE_UART_1_BAUD],[*],[])
    41 RTEMS_BSPOPTS_HELP([BEAGLE_UART_1_BAUD],[baud for UART 1])
    42 
    43 RTEMS_BSPOPTS_SET([BEAGLE_UART_2_BAUD],[*],[])
    44 RTEMS_BSPOPTS_HELP([BEAGLE_UART_2_BAUD],[baud for UART 2])
    45 
    46 RTEMS_BSPOPTS_SET([BEAGLE_UART_7_BAUD],[*],[])
    47 RTEMS_BSPOPTS_HELP([BEAGLE_UART_7_BAUD],[baud for UART 7])
    48 
    49 RTEMS_BSPOPTS_SET([BEAGLE_CONFIG_U3CLK],[*],[])
    50 RTEMS_BSPOPTS_HELP([BEAGLE_CONFIG_U3CLK],[clock configuration for UART 3])
    51 
    52 RTEMS_BSPOPTS_SET([BEAGLE_CONFIG_U4CLK],[*],[])
    53 RTEMS_BSPOPTS_HELP([BEAGLE_CONFIG_U4CLK],[clock configuration for UART 4])
    54 
    55 RTEMS_BSPOPTS_SET([BEAGLE_CONFIG_U5CLK],[*],[0x00001386U])
    56 RTEMS_BSPOPTS_HELP([BEAGLE_CONFIG_U5CLK],[clock configuration for UART 5])
    57 
    58 RTEMS_BSPOPTS_SET([BEAGLE_CONFIG_U6CLK],[*],[])
    59 RTEMS_BSPOPTS_HELP([BEAGLE_CONFIG_U6CLK],[clock configuration for UART 6])
    60 
    61 RTEMS_BSPOPTS_SET([BEAGLE_CONFIG_UART_CLKMODE],[*],[0x00000200U])
    62 RTEMS_BSPOPTS_HELP([BEAGLE_CONFIG_UART_CLKMODE],[clock mode configuration for UARTs])
    63 
    64 RTEMS_BSPOPTS_SET([BEAGLE_DISABLE_MMU],[*],[])
    65 RTEMS_BSPOPTS_HELP([BEAGLE_DISABLE_MMU],[disable MMU])
    66 
    67 RTEMS_BSPOPTS_SET([BEAGLE_DISABLE_READ_WRITE_DATA_CACHE],[*],[])
    68 RTEMS_BSPOPTS_HELP([BEAGLE_DISABLE_READ_WRITE_DATA_CACHE],[disable cache for read-write data sections])
    69 
    70 RTEMS_BSPOPTS_SET([BEAGLE_DISABLE_READ_ONLY_PROTECTION],[*],[])
    71 RTEMS_BSPOPTS_HELP([BEAGLE_DISABLE_READ_ONLY_PROTECTION],[disable MMU protection of read-only sections])
    72 
    73 RTEMS_BSPOPTS_SET([BEAGLE_SCRATCH_AREA_SIZE],[beagle_mzx*],[4096])
    74 RTEMS_BSPOPTS_HELP([BEAGLE_SCRATCH_AREA_SIZE],[size of scratch area])
    75 
    76 RTEMS_BSPOPTS_SET([BEAGLE_STOP_GPDMA],[*],[1])
    77 RTEMS_BSPOPTS_HELP([BEAGLE_STOP_GPDMA],[stop general purpose DMA at start-up to avoid DMA interference])
    78 
    79 RTEMS_BSPOPTS_SET([BEAGLE_STOP_ETHERNET],[*],[1])
    80 RTEMS_BSPOPTS_HELP([BEAGLE_STOP_ETHERNET],[stop Ethernet controller at start-up to avoid DMA interference])
    81 
    82 RTEMS_BSPOPTS_SET([BEAGLE_STOP_USB],[*],[1])
    83 RTEMS_BSPOPTS_HELP([BEAGLE_STOP_USB],[stop USB controller at start-up to avoid DMA interference])
    84 
    85 RTEMS_BSPOPTS_SET([BEAGLE_ENABLE_WATCHDOG_RESET],[*],[1])
    86 RTEMS_BSPOPTS_HELP([BEAGLE_ENABLE_WATCHDOG_RESET],[bsp_reset() will use the watchdog to reset the chip])
    87 
    88 RTEMS_BSPOPTS_SET([BSP_START_RESET_VECTOR],[*],[])
    89 RTEMS_BSPOPTS_HELP([BSP_START_RESET_VECTOR],[reset vector address for BSP start])
    90 
    91 RTEMS_BSPOPTS_SET([TESTS_USE_PRINTK],[*],[1])
    92 RTEMS_BSPOPTS_HELP([TESTS_USE_PRINTK],[tests use printk() for output])
     30RTEMS_BSPOPTS_SET([CONSOLE_POLLED],[*],[0])
     31RTEMS_BSPOPTS_HELP([CONSOLE_POLLED],[polled console i/o (e.g. to run testsuite)])
    9332
    9433RTEMS_BSP_CLEANUP_OPTIONS(0, 0)
Note: See TracChangeset for help on using the changeset viewer.