From 17c6686753e583c8a8c37474beea6e67d9b5a43f Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Thu, 14 Aug 2003 20:04:18 +0000 Subject: 2003-08-14 Joel Sherrill PR 408/filesystem * score/Makefile.am, score/include/rtems/score/thread.h: Added sync() service. As part of adding this service, the new RTEMS service rtems_iterate_over_all_threads() was also added. This new service makes it easier to iterate over all the tasks/threads in a system and perform an action on them. * score/src/iterateoverthreads.c: New file. * ChangeLog: Fixed screwup. --- cpukit/score/include/rtems/score/thread.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'cpukit/score/include') diff --git a/cpukit/score/include/rtems/score/thread.h b/cpukit/score/include/rtems/score/thread.h index 18d4774a5d..1005aa2eff 100644 --- a/cpukit/score/include/rtems/score/thread.h +++ b/cpukit/score/include/rtems/score/thread.h @@ -763,6 +763,21 @@ Thread _Thread_Idle_body( ); #endif +/* + * rtems_iterate_over_all_tasks + * + * DESCRIPTION: + * + * This routine iterates over all threads regardless of API and + * invokes the specified routine. + */ + +typedef void (*rtems_per_thread_routine)( Thread_Control * ); + +void rtems_iterate_over_all_threads( + rtems_per_thread_routine routine +); + #ifndef __RTEMS_APPLICATION__ #include #endif -- cgit v1.2.3