[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Minios-devel] [UNIKRAFT PATCH v2 3/5] lib/ukschedcoop: Set current thread on platform stack



This looks good, too.

Reviewed-by: Florian Schmidt <florian.schmidt@xxxxxxxxx>

On 5/29/19 6:56 AM, Costin Lupu wrote:
As soon as we find a new thread to be scheduled, we set it on the
platform stack as well in order to be accessed from interrupt context.

Signed-off-by: Costin Lupu <costin.lupu@xxxxxxxxx>
---
  lib/ukschedcoop/schedcoop.c | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/lib/ukschedcoop/schedcoop.c b/lib/ukschedcoop/schedcoop.c
index fcb9ac43..e0b116ee 100644
--- a/lib/ukschedcoop/schedcoop.c
+++ b/lib/ukschedcoop/schedcoop.c
@@ -30,6 +30,7 @@
   * to Round Robin algorithm.
   */
  #include <uk/plat/lcpu.h>
+#include <uk/plat/memory.h>
  #include <uk/plat/time.h>
  #include <uk/sched.h>
  #include <uk/schedcoop.h>
@@ -97,6 +98,7 @@ static void schedcoop_schedule(struct uk_sched *s)
                                                thread_list);
                                UK_TAILQ_INSERT_TAIL(&prv->thread_list, thread,
                                                thread_list);
+                               ukplat_stack_set_current_thread(next);
                                break;
                        }
                }


--
Dr. Florian Schmidt
フローリアン・シュミット
Research Scientist,
Systems and Machine Learning Group
NEC Laboratories Europe
Kurfürsten-Anlage 36, D-69115 Heidelberg
Tel.     +49 (0)6221 4342-265
Fax:     +49 (0)6221 4342-155
e-mail:  florian.schmidt@xxxxxxxxx
============================================================
Registered at Amtsgericht Mannheim, Germany, HRB728558

_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.