mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-04-05 01:59:55 +00:00
dc111845411176bae4593c27bafaf626c11432e4
Fix two issues in the STM32F4 I2C driver related to mutex handling. The mutex protecting the I2C bus was created with an initial count of 0. For a binary semaphore used as a mutex this causes the first rtems_semaphore_obtain() call to block indefinitely since the semaphore starts in the locked state. Initialize the semaphore with a count of 1 so it starts unlocked. Additionally, stm32f4_i2c_process_message() could return early if the STOP bit was set in CR1 without releasing the mutex. This would leave the mutex locked and cause subsequent calls to deadlock. Release the mutex before returning in this case. Also cast dummy SR2 reads to (void) to make the intent explicit and avoid potential compiler warnings about statements with no effect. arm/stm32f4: Fix I2C mutex initialization and potential mutex leak fix the indentation on these lines.
Real-Time Executive for Multiprocessing Systems
RTEMS is a real-time executive (kernel) which provides a high performance environment for embedded applications with the following features:
- Standards based user interfaces.
- Multitasking capabilities.
- Homogeneous and heterogeneous multiprocessor systems.
- Symmetric Multiprocessing (SMP):
- Cluster scheduling: Job-level fixed prority scheduler (EDF) with support for one-to-one and one-to-all thread to processor affinities.
- Locking protocols with transitive priority inheritance, priority ceiling, MRsP and OMIP.
- Event-driven, priority-based, preemptive scheduling.
- Scalable timer and timeout support.
- Optional rate monotonic scheduling.
- Intertask communication and synchronisation.
- Priority inheritance.
- Responsive interrupt management.
- Dynamic memory allocation.
- Dynamic code loading using run-time link editing.
- File systems, IMFS, FAT, RFS, JFFS, NSFv4 (with LibBSD)
- High level of user configurability.
- Link-time configurable schedulers.
- Linker-set based initialization (similar to global C++ constructors).
- Drivers for I2C, SPI and LibBSD has NIC, USB, SD/MMC and Framebuffer.
- Open source with a friendly user license.
RTEMS Project:
Project git repositories are located at:
Online documentation is available at:
RTEMS Doxygen for CPUKit:
RTEMS POSIX 1003.1 Compliance Guide:
RTEMS Discourse User forum for questions, answers and examples:
RTEMS Discord for support:
RTEMS Mailing Lists for general purpose use the users list and for developers use the devel list.
The version number for this software in releases is located in the VERSION file if present.
Description
RTEMS is a real-time executive in use by embedded systems applications around the world and beyond
Languages
C
94.6%
Assembly
3.1%
Ada
1.2%
Python
0.3%
HTML
0.2%
Other
0.3%