summaryrefslogtreecommitdiffstats
path: root/cpukit/include
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-02-15 11:09:16 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-02-25 07:18:35 +0100
commit1ada3e55f695f77452bd4eb6ebb5d7a4054e1edf (patch)
tree2983bb496f6674cc1d6204d21fdca257580f1eeb /cpukit/include
parentlibio: Add POSIX user environment pointer to TCB (diff)
downloadrtems-1ada3e55f695f77452bd4eb6ebb5d7a4054e1edf.tar.bz2
score: Add _SMP_Need_inter_processor_interrupts()
Test for the proper system condition instead of using the rtems_configuration_is_smp_enabled() workaround. Update #3876.
Diffstat (limited to 'cpukit/include')
-rw-r--r--cpukit/include/rtems/score/smpimpl.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/cpukit/include/rtems/score/smpimpl.h b/cpukit/include/rtems/score/smpimpl.h
index 889ef5be58..dbca09d5cb 100644
--- a/cpukit/include/rtems/score/smpimpl.h
+++ b/cpukit/include/rtems/score/smpimpl.h
@@ -324,6 +324,21 @@ RTEMS_INLINE_ROUTINE const Processor_mask *_SMP_Get_online_processors( void )
#endif
}
+/**
+ * @brief Indicate if inter-processor interrupts are needed.
+ *
+ * @return True if inter-processor interrupts are needed for the correct system
+ * operation, otherwise false.
+ */
+RTEMS_INLINE_ROUTINE const bool _SMP_Need_inter_processor_interrupts( void )
+{
+ /*
+ * Use the configured processor maximum instead of the actual to allow
+ * testing on uni-processor systems.
+ */
+ return _SMP_Processor_configured_maximum > 1;
+}
+
/** @} */
#ifdef __cplusplus