Commit Graph

29739 Commits

Author SHA1 Message Date
Sebastian Huber
475faef538 tmfine01: Add self-contained mutex test case
This demonstrates the effect of false cache line sharing in case of
Classic mutexes.
2016-10-10 08:49:05 +02:00
Sebastian Huber
a899549ed2 bsp/atsam: Provide default buffer counts 2016-10-05 14:04:23 +02:00
Sebastian Huber
10eedb9fa6 bsp/atsam: Fix PHY detection 2016-10-05 14:04:07 +02:00
Pavel Pisa
8714684129 score/arm: Correct logic to select 64 byte cache line maximum size for Cortex-A.
The use of actual cache line max bytes and minimum required alignment
in architecture but not-BSP dependent code could be problematic
because there exists even ARM instruction set implementations
with 128 byte line length and real maximum can be quite problematic
to say. But actually supported ARM BSPs should be OK with these values.
2016-10-04 23:30:22 +02:00
Pavel Pisa
89b4a5cc5f libdl/rtl-obj.c: synchronize cache should not depend on CPU_CACHE_LINE_BYTES.
Use of rtems_cache_get_maximal_line_size() is more descriptive
choice. The min/max data/instruction cache line size is not critical
there, value is used for optimization only to use single operation
for directly following sections.
2016-10-04 23:17:25 +02:00
Sebastian Huber
9b0445685b monitor: Support priority inheritance queues 2016-09-30 07:54:29 +02:00
Sebastian Huber
8797c76add score: Unify CORE mutex seize/surrender
Use the Thread_Control::resource_count for the no protocol mutexes.
Merge the no protocol and priority inherit CORE mutex seize/surrender
operations.
2016-09-27 15:23:00 +02:00
Sebastian Huber
4e02681b2f score: Simplify ISR lock name 2016-09-27 07:39:22 +02:00
Sebastian Huber
94d5b390e5 score: Simplify CORE mutex seize
Rename _CORE_mutex_Seize_no_protocol_slow() in _CORE_mutex_Seize_slow().
Remove previous _CORE_mutex_Seize_slow() since the protocol handling is
now done in the thread queue operations.
2016-09-27 07:39:03 +02:00
Sebastian Huber
f0115ab4a6 score: Fix warning 2016-09-27 07:38:53 +02:00
Sebastian Huber
938ee19c5a sptests/spsem03: Fix compile error 2016-09-23 10:14:54 +02:00
Sebastian Huber
8ace7ee42f bsp/mvme147*: Fix linker issue
The GNU linker does not allow a nonconstant expression for a region
length.
2016-09-23 08:41:58 +02:00
Sebastian Huber
bbe8833336 bsps/m68k: Add libatomic support to some bsp_specs
Update #2695.
2016-09-23 08:03:41 +02:00
Sebastian Huber
d6e58a0f14 bsps/m68k: Fix linker command file
Prevent garbage collection of interrupt vector table.
2016-09-23 06:57:12 +02:00
Sebastian Huber
9149c87ec7 score: Fix C/C++ compatibility issue
Only use CPU_Per_CPU_control if it contains at least one filed.  In GNU
C empty structures have a size of zero.  In C++ structures have a
non-zero size.  In case CPU_PER_CPU_CONTROL_SIZE is defined to zero,
then this structure is not used anymore.
2016-09-23 06:57:03 +02:00
Pavel Pisa
425f6cfa11 arm/tms570: document BSP setup with included hardware initialization. 2016-09-22 09:56:06 +02:00
Pavel Pisa
aae17bf32d arm/tms570: update bootstrap generated preinstall.am 2016-09-22 09:51:31 +02:00
Pavel Pisa
98b6874031 arm/tms570: include TMS570_USE_HWINIT_STARTUP option to select bare metal startup and selftest. 2016-09-22 09:51:21 +02:00
Pavel Pisa
29430a3a10 arm/tms570: include hardware initialization and selftest based on Ti HalCoGen generated files.
The configuration is specific for TMS570LS3137 based HDK.
Pins configuration can be easily changed in

  rtems/c/src/lib/libbsp/arm/tms570/hwinit/init_pinmux.c

file.

The list tms570_selftest_par_list in the file

  rtems/c/src/lib/libbsp/arm/tms570/hwinit/bspstarthooks-hwinit.c

specifies peripherals which health status is examined
by parity self-test at BSP start-up. It can be easily
modified for other TMS570 family members variants same
as the selection of other tests in bspstarthooks-hwinit.c.
2016-09-22 09:50:59 +02:00
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