Please CC relevant maintainers for the code you modify. You can use scripts/get_maintainers.pl for that. I have CCed them for you this time.


On 11/04/18 14:19, Mirela Simonovic wrote:
Secondary pCPUs will be offlined on system suspend and hotplugged
on resume. When offlining secondary CPUs all interrupts targeted
to those CPUs will be routed to the boot CPU. The boot CPU
is responsible for finalizing suspend procedure. All wake-up
interrupts are therefore targeted to the boot CPU. Existing code
was missing the restoration of interrupts affinity after
hotplugging a CPU. This patch restores the IRQ affinity after
a CPU is hotplugged.

Signed-off-by: Mirela Simonovic <mirela.simono...@aggios.com>
  xen/common/schedule.c | 4 ++++
  1 file changed, 4 insertions(+)

diff --git a/xen/common/schedule.c b/xen/common/schedule.c
index 343ab6306e..e3956019bc 100644
--- a/xen/common/schedule.c
+++ b/xen/common/schedule.c
@@ -692,6 +692,7 @@ void restore_vcpu_affinity(struct domain *d)
      for_each_vcpu ( d, v )
          spinlock_t *lock;
+        bool affinity_was_broken = v->affinity_broken;
ASSERT(!vcpu_runnable(v)); @@ -724,6 +725,9 @@ void restore_vcpu_affinity(struct domain *d)
          lock = vcpu_schedule_lock_irq(v);
          v->processor = SCHED_OP(vcpu_scheduler(v), pick_cpu, v);
+        if ( affinity_was_broken )
+            sched_move_irqs(v);

Julien Grall

Xen-devel mailing list

Reply via email to