Commit Graph

29720 Commits

Author SHA1 Message Date
Pavel Pisa
5746f108bd arm/tms570: define base addresses of all TMS570LS3137 SPI interfaces.
Generated header file ti_herc/reg_spi.h contains complete registers
and fields set for Ti MibSPI peripheral.
Care has to be taken that only TMS570_SPI1, TMS570_SPI3 and TMS570_SPI5
are of this complete multibuffer type. TMS570_SPI2 and TMS570_SPI4
have substantial part of registers removed but else they are compatible.
2016-09-22 08:26:29 +02:00
Pavel Pisa
a396ed4778 bsps/arm: Export bsp_start_hook_0_done symbol from ARM start.S.
The symbol can be used by bsp_start_hook_0 when complete
RAM memory is initialization and overwritten during BSP
self-test. The test overwrites even memory used to store
return address / link register and regular resturn from
bsp_start_hook_0 is not possible then.
2016-09-22 08:26:13 +02:00
Pavel Pisa
4d3c866aec classic networking: adapt FXP driver to work with actual PCI and IRQ code.
Tested to work with QEMU provided Intel i82557b network controller emulation.

qemu-system-x86_64 -enable-kvm -kernel $APP_BINARY \
      -vga cirrus \
      -append "--console=/dev/com1" \
      -serial stdio \
      -net nic,vlan=1,macaddr=be:be:be:10:00:01,model=i82557b \
      -net tap,ifname=tap1,vlan=1,script=no,downscript=no
2016-09-21 10:24:59 +02:00
Sebastian Huber
f6142c19f1 score: Scheduler node awareness for thread queues
Maintain the priority of a thread for each scheduler instance via the
thread queue enqueue, extract, priority actions and surrender
operations.  This replaces the primitive priority boosting.

Update #2556.
2016-09-21 08:59:33 +02:00
Sebastian Huber
8123cae864 rtems: Add rtems_task_get_priority()
Update #2556.
Update #2784.
2016-09-21 08:59:33 +02:00
Sebastian Huber
6ae309ec85 smptests/smpmutex01: Use test case functions 2016-09-21 08:59:33 +02:00
Sebastian Huber
266d3835d8 score: Manage scheduler nodes via thread queues
Update #2556.
2016-09-21 08:59:32 +02:00
Sebastian Huber
5d6b211981 score: Add scheduler node table for each thread
Update #2556.
2016-09-21 08:59:32 +02:00
Sebastian Huber
300f6a481a score: Rework thread priority management
Add priority nodes which contribute to the overall thread priority.

The actual priority of a thread is now an aggregation of priority nodes.
The thread priority aggregation for the home scheduler instance of a
thread consists of at least one priority node, which is normally the
real priority of the thread.  The locking protocols (e.g. priority
ceiling and priority inheritance), rate-monotonic period objects and the
POSIX sporadic server add, change and remove priority nodes.

A thread changes its priority now immediately, e.g. priority changes are
not deferred until the thread releases its last resource.

Replace the _Thread_Change_priority() function with

 * _Thread_Priority_perform_actions(),
 * _Thread_Priority_add(),
 * _Thread_Priority_remove(),
 * _Thread_Priority_change(), and
 * _Thread_Priority_update().

Update #2412.
Update #2556.
2016-09-21 08:59:26 +02:00
Pavel Pisa
8c83cbcc96 classic networking: do not reference BSP_irq_enabled_at_i8259s which is no more available on i386.
This change is required to build RTEMS with classic "--enable-networking"
and link applications/tests which reference RTEMS_BSP_NETWORK_DRIVER_ATTACH.
2016-09-20 22:45:16 +02:00
Sebastian Huber
e814a233ed termios: Add IO control handler
Update #2785.
2016-09-19 07:52:34 +02:00
Sebastian Huber
55e0be3606 termios: Use IMFS nodes for new Termios devices
This makes the new Termios devices independent of device major/minor
numbers.  It enables BSP independent Termios device drivers which may
reside in the cpukit domain.  These drivers require an IMFS and do not
work with the device file system.  However, the device file system
should go away in the future.
2016-09-19 07:52:33 +02:00
Sebastian Huber
610b9ef120 libtests/devfs: Use printk()
This avoids problems with console drivers that use generic nodes of the
IMFS.
2016-09-19 07:52:33 +02:00
Sebastian Huber
caf4064680 fstests: Use printk() for IMFS configuration tests
This avoids problems with console drivers that require a more complete
IMFS.
2016-09-19 07:22:30 +02:00
Sebastian Huber
29770e122e tests: CONFIGURE_USE_DEVFS_AS_BASE_FILESYSTEM
Avoid unnecessary use of CONFIGURE_USE_DEVFS_AS_BASE_FILESYSTEM.
2016-09-19 07:22:30 +02:00
Sebastian Huber
d496e0979a imfs: Untangle dependencies
This helps to use IMFS_make_generic_node() without pulling in the
complete IMFS implementation.
2016-09-19 07:22:01 +02:00
Sebastian Huber
a3e9ae5d0d imfs: Fix IMFS_stat_file()
Use the adjusted and not the requested memfile bytes per block.
Untangle dependencies.
2016-09-16 14:02:41 +02:00
Alexander Krutwig
0ab86d091a bsp/atsam: Add SPI bus driver 2016-09-16 10:07:03 +02:00
Alexander Krutwig
a42be52bbf Add SPI bus framework
User API is compatible to Linux userspace API.  New test libtests/spi01.

Update #2776.
2016-09-16 09:36:44 +02:00
Alexander Krutwig
c186de5cd1 bsp/atsam: Use normal memory for QSPI flash area
This is a performance improvement for execute-in-place (XIP).
2016-09-16 08:18:50 +02:00
Pavel Pisa
5eb769ca8b arm/raspberrypi: define bsp_reset to restart board by watchdog.
Whether the board is restarted after application finish/exit
is controlled by BSP_RESET_BOARD_AT_EXIT configure option.
2016-09-08 23:40:21 +02:00
Sebastian Huber
b20b736382 score: Introduce _Thread_Get_priority()
Avoid direct access to thread internal data fields.
2016-09-08 09:55:28 +02:00
Sebastian Huber
52a661e8f8 score: Add scheduler node implementation header
Update #2556.
2016-09-08 09:55:27 +02:00
Sebastian Huber
15b5678dcd score: Move thread wait node to scheduler node
Update #2556.
2016-09-08 09:55:27 +02:00
Sebastian Huber
e27421f386 score: Move scheduler node to own header file
This makes it possible to add scheduler nodes to structures defined in
<rtems/score/thread.h>.

Update #2556.
2016-09-08 09:55:27 +02:00
Sebastian Huber
1f210ac139 score: Optimize thread queue enqueue
Optimize the enqueue to empty thread queue case.
2016-09-08 09:55:27 +02:00
Sebastian Huber
e41308eab8 score: Introduce Thread_queue_Lock_context
Introduce Thread_queue_Lock_context to contain the context necessary for
thread queue lock and thread wait lock acquire/release operations to
reduce the Thread_Control size.
2016-09-08 09:55:27 +02:00
Sebastian Huber
114e40880b score: Simplify thread queue acquire/release 2016-09-08 09:55:26 +02:00
Sebastian Huber
db56369883 score: Fix warning 2016-09-08 09:55:26 +02:00
Sebastian Huber
63b36cbf17 score: Fix warning 2016-09-08 09:55:26 +02:00
Sebastian Huber
8af1663acc score: Fix for RTEMS_DEBUG 2016-09-08 09:55:26 +02:00
Sebastian Huber
275032b85a powerpc: Fix SMP context switch
We need the unmodified r4 for get_potential_new_heir.

This partially reverts commit 8d785f72d9.
2016-09-08 09:55:26 +02:00
Chris Johns
d416061846 testsuite: Add libdl/dl05 reloc test. 2016-09-08 16:52:39 +10:00
Chris Johns
11323b7da9 libdl: Add ARM C++ relocation record support.
Closes #2767
2016-09-08 16:41:59 +10:00
Sebastian Huber
84e960e951 stackchk: Fix stack checker thread initialization
Commit 0fd6f25507 relaxed the thread begin
extension execution environment.  This broke the stack check which only
partially initialized the stack pattern in its create extension.  Move
the part of the begin extension to the create extension.
2016-09-08 07:43:02 +02:00
Sebastian Huber
8bb9d4100c stackchk: Use a const pattern to check 2016-09-08 07:43:02 +02:00
Sebastian Huber
bba988d313 stackchk: Remove superfluous internal header file 2016-09-08 07:43:02 +02:00
Sebastian Huber
531924df8b bsp/raspberrypi: Rename file 2016-09-08 07:43:02 +02:00
Pavel Pisa
5d369c8572 arm/raspberrypi: use GPU/system timer as clock source.
It has advantage that it is designed as free-running counter
with compare registers and can easily serve for for both
timecounter and tick interrupt.
2016-09-07 20:29:39 +02:00
Pavel Pisa
40f49d11cf arm/raspberrypi: correct and extend definitions for GPU timer. 2016-09-07 20:29:39 +02:00
Pavel Pisa
df2ee9d377 arm/raspberrypi: basic BCM2836 SMP implementation.
The BSP support is divided to startup/bspsmp_api.c file where
functions required by SuperCore are defined and BCM2836 hardware
initialization part in startup/bspsmp_init.c.

Separation is done to prevent smpfatal08 test build failure.
2016-09-07 20:29:39 +02:00
Pavel Pisa
38a5385bc0 arm/raspberrypi: propagate number of configured CPUs into linker script. 2016-09-07 20:29:39 +02:00
Pavel Pisa
dfbedf366d arm/raspberrypi: rename linkcmds to linkcmds.in to allow their configure processing. 2016-09-07 20:29:39 +02:00
Pavel Pisa
4c53be196d arm/raspberrypi: more definitions of BCM2836 core local peripherals. 2016-09-07 20:29:39 +02:00
Rohini Kulkarni
bf62c39021 arm/raspberrypi: include definitions of BCM2836 SMP mailboxes. 2016-09-07 20:29:39 +02:00
Pavel Pisa
6e6a77a690 bsps/arm: reorganize CP15 code to allow clean and invalidate ARMv7 cache by level.
New function arm_cp15_cache_invalidate_level and arm_cp15_cache_clean_level
can be used to maintain single cache level (instruction or data).
2016-09-07 20:29:39 +02:00
Pavel Pisa
5c49464108 bsps/arm: remove lock in arm_cp15_set_translation_table_entries().
Protection by rtems_interrupt_disable() is incompatible with SMP build.
Actual page table entries manipulation function does not need locking
and disabling cache and can be run concurrently even on multiple
CPUs as long as changes do not modify same region. If the function
is called from more threads/CPUs to modify same region with different
mapping options concurrently then there is problem at another level
of virtual address space management  and has to be solved by mutex
or other locking at that level.
2016-09-07 20:29:38 +02:00
Pavel Pisa
7ec689adc7 bsps/arm: use defines for cache type register format field.
The change documents meaning of codes and opens
well defined way to use cache type format for cache
examination/debugging outside of arm-cp15.h file.
2016-09-07 20:29:38 +02:00
Christian Mauderer
b9cc5aa9d3 bsp/atsam: Add SDRAM IS42S16320F-7BL. 2016-09-07 13:38:53 +02:00
Christian Mauderer
beb289eb5b bsp/atsam: Move ram init values to structure. 2016-09-07 13:38:53 +02:00