Dmitry Timoshkov dmitry@baikal.ru writes:
Signed-off-by: Dmitry Timoshkov dmitry@baikal.ru
dlls/schedsvc/atsvc.c | 22 +++++++++++++++++----- dlls/schedsvc/schedsvc_private.h | 1 + dlls/schedsvc/svc_main.c | 31 ++++++++++++++++++++++++++++--- 3 files changed, 46 insertions(+), 8 deletions(-)
Polling is usually not a good idea, especially for mobile devices. It would be better to trigger a wake up when something has changed. It looks to me like job flag changes in particular wouldn't need any polling.
If polling is necessary, for instance if there are more that MAXIMUM_WAIT_OBJECTS processes that you need to wait on for termination, it should be enabled only at that time.