[tracker-miners] libtracker-miners-common: Add comment to sched-idle fallback path
- From: Sam Thursfield <sthursfield src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker-miners] libtracker-miners-common: Add comment to sched-idle fallback path
- Date: Sun, 2 Feb 2020 20:00:05 +0000 (UTC)
commit 09c446ceabe7fa724229cd411a40043bd7b450bd
Author: Sam Thursfield <sam afuera me uk>
Date: Sun Feb 2 20:58:57 2020 +0100
libtracker-miners-common: Add comment to sched-idle fallback path
src/libtracker-miners-common/tracker-sched.c | 9 +++++++++
1 file changed, 9 insertions(+)
---
diff --git a/src/libtracker-miners-common/tracker-sched.c b/src/libtracker-miners-common/tracker-sched.c
index 4a87f7a02..f4cd65f5b 100644
--- a/src/libtracker-miners-common/tracker-sched.c
+++ b/src/libtracker-miners-common/tracker-sched.c
@@ -59,6 +59,15 @@ tracker_sched_idle (void)
#else /* __linux__ */
+/* Although pthread_setschedparam() should exist on any POSIX compliant OS,
+ * the SCHED_IDLE policy is Linux-specific. The POSIX standard only requires
+ * the existence of realtime and 'other' policies.
+ *
+ * We could set the priority to 0. On FreeBSD the default priority is already
+ * 0, and this may be true on other platforms, so we currently don't bother.
+ * See https://gitlab.gnome.org/GNOME/tracker-miners/merge_requests/140 for
+ * more discussion.
+ */
#include <glib.h>
#include "tracker-sched.h"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]