summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/sparc/shared (follow)
Commit message (Collapse)AuthorAgeFilesLines
* bsps/sparc: Move shared files to bspsSebastian Huber2018-04-2070-50057/+0
| | | | | | This patch is a part of the BSP source reorganization. Update #3285.
* sparc: Move irq_asm.SSebastian Huber2018-04-201-904/+0
| | | | | | | | This file is BSP-independent. This patch is a part of the BSP source reorganization. Update #3285.
* sparc: Move _CPU_Trap_slot_templateSebastian Huber2018-04-201-36/+0
| | | | | | | | | The definition of _CPU_Trap_slot_template is BSP-independent. A potential para-virtualization support may use <rtems/score/paravirt.h>. This patch is a part of the BSP source reorganization. Update #3285.
* bsps: Move benchmark timer to bspsSebastian Huber2018-04-203-1074/+0
| | | | | | This patch is a part of the BSP source reorganization. Update #3285.
* bsps: Move startup files to bspsSebastian Huber2018-04-204-330/+0
| | | | | | | | Adjust build support files to new directory layout. This patch is a part of the BSP source reorganization. Update #3285.
* bsps: Move start files to bspsSebastian Huber2018-04-201-374/+0
| | | | | | This patch is a part of the BSP source reorganization. Update #3285.
* bsps: Move clock drivers to bspsSebastian Huber2018-04-201-2/+2
| | | | | | This patch is a part of the BSP source reorganization. Update #3285.
* bsps: Move doxygen.h files to bspsSebastian Huber2018-04-201-15/+0
| | | | | | This patch is a part of the BSP source reorganization. Update #3285.
* bsps/sparc: Fix global construction/destructionThanassis Tsiodras2018-03-061-2/+4
| | | | | | | | | | | | | | | | | | | | | The KEEP (*(SORT(.ctors.*))) KEEP (*(.ctors)) cannot be simplified to KEEP (*(SORT(.ctors*))) since .ctors < .ctors.* in lexicographical order. See spglobalcon02 test case. Update #3319.
* sparc/*/linkcmds*: Move ENTRY() from linkcmds.base to top linkcmdsJoel Sherrill2018-02-051-1/+0
| | | | | | | | This was at the request of a user to make it easier to have a custom entry point. This way they just provide their own top level linkcmds and include linkcmds.base. Updates #3520.
* bsps: Move network define to source filesSebastian Huber2018-01-311-0/+3
| | | | | Define __INSIDE_RTEMS_BSD_TCPIP_STACK__ in the network interface driver source files to avoid some build system magic.
* Remove make preinstallChris Johns2018-01-2562-9661/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A speciality of the RTEMS build system was the make preinstall step. It copied header files from arbitrary locations into the build tree. The header files were included via the -Bsome/build/tree/path GCC command line option. This has at least seven problems: * The make preinstall step itself needs time and disk space. * Errors in header files show up in the build tree copy. This makes it hard for editors to open the right file to fix the error. * There is no clear relationship between source and build tree header files. This makes an audit of the build process difficult. * The visibility of all header files in the build tree makes it difficult to enforce API barriers. For example it is discouraged to use BSP-specifics in the cpukit. * An introduction of a new build system is difficult. * Include paths specified by the -B option are system headers. This may suppress warnings. * The parallel build had sporadic failures on some hosts. This patch removes the make preinstall step. All installed header files are moved to dedicated include directories in the source tree. Let @RTEMS_CPU@ be the target architecture, e.g. arm, powerpc, sparc, etc. Let @RTEMS_BSP_FAMILIY@ be a BSP family base directory, e.g. erc32, imx, qoriq, etc. The new cpukit include directories are: * cpukit/include * cpukit/score/cpu/@RTEMS_CPU@/include * cpukit/libnetworking The new BSP include directories are: * bsps/include * bsps/@RTEMS_CPU@/include * bsps/@RTEMS_CPU@/@RTEMS_BSP_FAMILIY@/include There are build tree include directories for generated files. The include directory order favours the most general header file, e.g. it is not possible to override general header files via the include path order. The "bootstrap -p" option was removed. The new "bootstrap -H" option should be used to regenerate the "headers.am" files. Update #3254.
* sparc/*/bsp_specs, shared/linkcmds: Simplify bsp_specsJoel Sherrill2017-12-191-0/+2
| | | | Updates #3520.
* leon, gr1553rt: adding SMP protectionDaniel Hellstrom2017-11-211-113/+69
| | | | | | | | | Add device spin-lock around internal data structures. Since the driver provides a low-level C API accessing the descriptors the application still needs to implement part of the SMP synchonization needed between Interrupt handler and tasks. Close #2355.
* leon, grspw_router: Clear only error bits defined by clear maskJavier Jalle2017-11-142-3/+3
|
* leon, grspw_router: Allow thread safe per-bit managing of pctrl regsJavier Jalle2017-11-142-93/+70
|
* leon, grspw_router: Move register bit defs to headerJavier Jalle2017-11-142-145/+166
|
* leon, grspw_router: Changed driver C APIJavier Jalle2017-11-142-386/+2212
| | | | | | | | | | | SMP safe by spin-lock protection and semaphore. On spin-lock per SpW/AMBA port to allow multiple parallel register operations per port. A common semaphore for general SpW router configuration such as routing table. Move to a C API instead of using the I/O Manager. The SpW router driver does not perform any I/O only management of the router. Update #2355.
* bsps: Clock_driver_support_install_isr()Sebastian Huber2017-09-181-1/+1
| | | | | | | Remove old ISR parameter since is not used by the clock driver shell. Make an implementation optional. Update #3139.
* leon,ambapp_bus: make unreferenced global function staticDaniel Hellstrom2017-08-292-51/+69
| | | | Fixes #3072
* leon,grascs: fix semaphore policiesDaniel Hellstrom2017-08-291-2/+3
| | | | Closes #2726
* leon,ambapp: fixes bad allocation checkDaniel Hellstrom2017-08-291-1/+1
| | | | Updates #2496 but to close needs to be applied to 4.11 accoring to ticket.
* leon,gr1553b: improve init checkDaniel Hellstrom2017-08-291-3/+8
| | | | | | | | Check in init3 not needed since same data is already checked in init2 stage. Adds an extra check that the APB register space is available before accessing it. Updates #2331 but needs to be applied to 4.11 according to ticket.
* leon,occan: remove dead code.Daniel Hellstrom2017-08-291-92/+0
| | | | Fixes #2878
* Include missing <string.h>Sebastian Huber2017-08-2511-0/+11
| | | | Update #2133.
* sparc: Add lazy floating point switchSebastian Huber2017-07-252-9/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The SPARC ABI is a bit special with respect to the floating point context. The complete floating point context is volatile. Thus, from an ABI point of view nothing needs to be saved and restored during a context switch. Instead the floating point context must be saved and restored during interrupt processing. Historically, the deferred floating point switch was used for SPARC and the complete floating point context is saved and restored during a context switch to the new floating point unit owner. This is a bit dangerous since post-switch actions (e.g. signal handlers) and context switch extensions may silently corrupt the floating point context. The floating point unit is disabled for interrupt handlers. Thus, in case an interrupt handler uses the floating point unit then this will result in a trap (INTERNAL_ERROR_ILLEGAL_USE_OF_FLOATING_POINT_UNIT). In uniprocessor configurations, a lazy floating point context switch is used. In case an active floating point thread is interrupted (PSR[EF] == 1) and a thread dispatch is carried out, then this thread is registered as the floating point owner. When a floating point owner is present during a context switch, the floating point unit is disabled for the heir thread (PSR[EF] == 0). The floating point disabled trap checks that the use of the floating point unit is allowed and saves/restores the floating point context on demand. Update #3077.
* sparc: Rename SPARC_USE_SAFE_FP_SUPPORTSebastian Huber2017-07-251-3/+3
| | | | | | | Rename SPARC_USE_SAFE_FP_SUPPORT in SPARC_USE_SYNCHRONOUS_FP_SWITCH. Update comment. Update #3077.
* sparc: Add assembly workaround for LEON3FT B2BST errataDaniel Cederman2017-07-171-0/+47
| | | | | | | | | | | | | | | This patch adds NOP instructions to prevent instruction sequences that are sensitive to the LEON3FT B2BST errata. See GRLIB-TN-0009: "LEON3FT Stale Cache Entry After Store with Data Tag Parity Error" for more information. The sequences are only modified if __FIX_LEON3FT_B2BST is defined. The patch works in conjunction with the -mfix-ut700, -mfix-gr712rc, and -mfix-ut699 GCC flags that prevents the sensitive sequences from being generated. Update #3057.
* Add interrupt vector set/get affinitySebastian Huber2017-07-121-18/+2
| | | | Close #3071.
* bsps/sparc: Fix ambapp_int_set_affinity()Sebastian Huber2017-07-111-1/+1
| | | | Update #3059.
* score: Introduce _SMP_Get_online_processors()Sebastian Huber2017-07-071-1/+1
| | | | Update #3059.
* score: Use <sys/bitset.h> for Processor_maskSebastian Huber2017-07-063-4/+4
| | | | | | | | Implement the Processor_mask via <sys/bitset.h>. Provide _Processor_mask_To_uint32_t() to enable its use in device specific routines, e.g. interrupt affinity register in an interrupt controller. Update #3059.
* bsps: Improve interrupt vector enable/disable APISebastian Huber2017-06-201-6/+4
| | | | | | Change bsp_interrupt_vector_enable() and bsp_interrupt_vector_disable() to not return a status code. Add bsp_interrupt_assert() and use it to validate the vector number in the vector enable/disable implementations.
* Simplify TLS support in context switchSebastian Huber2017-06-091-1/+5
| | | | | | There is no need to save the thread pointer in _CPU_Context_switch() since it is a thread invariant. It is initialized once in _CPU_Context_Initialize().
* sparc: only define start if it is different from SYM(start)Jacob Hansen2017-05-141-0/+2
| | | | | | | | The SYM define concatenates the input with the compiler set __USER_LABEL_PREFIX__ define. This define appears to be '_' in GCC but empty in Clang. Therefore when compiling with Clang/LLVM 'SYM(start)' and 'start' defines the same symbol, and the compiler complains that the symbol is defined twice.
* sparc: Adjust assembly to improve compability with LLVMJacob Hansen2017-05-142-8/+8
| | | | | | | | | | | | | - All references of %0 changed to %g0 - 'call label,0' changed to 'call label'. According to the sparc specification call does not take any registers - '.seg "text"' changed to '.section ".text"' - the synonym stub is replaced with stb - the synonym stuh is replaced with sth
* leon, grtc: SMP support by using spin-locksDaniel Hellstrom2017-05-141-37/+54
|
* leon, grtc: updated overrun condition handlingDaniel Hellstrom2017-05-141-11/+33
| | | | | | | | The following functions now reports to the user that an overrun has occured by returning errno EIO: * grtc_read, on overrun and no more data in the DMA buffer * ioctl(GRTC_IOC_RECV), on overrun and no more frames in the DMA buffer * ioctl(GRTC_IOC_ISSTARTED), EIO is returned on overrun
* leon, gr1553bm: SMP support by using spin-locksDaniel Hellstrom2017-05-141-14/+39
|
* leon, gr1553bc: SMP support by using spin-locksDaniel Hellstrom2017-05-141-39/+84
| | | | | Since DMA buffers are managed by the user, responsibility is put on the user to cope with SMP in the application.
* leon, apbuart: remove old RAW UART driverDaniel Hellstrom2017-05-142-930/+0
| | | | | | | | This driver was initially intended for APBUART access on GRLIB PCI peripherals (AMBA-over-PCI). There are already many APBUART drivers for LEON. Instead of using this one the termios APBUART should work on AMBA-over-PCI systems with recent changes on LEON3, however that has not been tested yet.
* leon, grtm: SMP support by using spin-locksDaniel Hellstrom2017-05-141-83/+115
|
* leon, ahbstat: remove printf warningsDaniel Hellstrom2017-05-141-2/+2
|
* leon, pci-peripherals: SMP support by spin-locks and updated genirqDaniel Hellstrom2017-05-148-142/+412
|
* leon, genirq: SMP support for PCI peripheralsDaniel Hellstrom2017-05-142-42/+63
| | | | | | | | | | | | The common interrupt layer for GRLIB PCI perihperals is prepared for SMP support by this patch. The existing locking (interrupt disabling) is replaced by a new requirement on the user to implement locking before calling the genirq API. This approach avoids taking more locks than necessary. The split up of the locks also introduces that the user must allocate memory to describe ISR handlers, to avoid calling malloc()/free() while possessing a spin-lock and interrupts are globally disabled.
* leon: allow SMP boot from any CPUMartin Aberg2017-05-141-5/+9
|
* leon, grcan: removed unused txerror, rxerrorMartin Aberg2017-05-141-13/+0
|
* leon, grcan: fixed historical commentMartin Aberg2017-05-141-4/+3
|
* leon, grcan: semaphore reset count required after flushingDaniel Hellstrom2017-05-141-30/+32
| | | | | | | | | | | | It is also required to use semaphore release instead of flush when stopping or on BUSOFF/AHBERR condition. Otherwise a task just about to wait (taking the semaphore) could end up locked because the semaphore count is still the same. There was previously a scenario where the semaphore flush would not always make semaphore obtain to return in case of BUSOFF, AHBERROR or grcan_stop. It has to do with the rtems_semaphore_flush() not releasing the semaphore but just aborts any _current_ waiter.
* leon, grcan: split hw_stop() into hw and sw stopDaniel Hellstrom2017-05-141-0/+13
| | | | this is to avoid owning the spin-lock during semaphore operations.