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

[Xen-changelog] [xen-unstable] arm: shutdown, smp and smpboot



# HG changeset patch
# User Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
# Date 1328787210 0
# Node ID d112c692b49599ecdbb6d8c86e910f26cd485ffc
# Parent  a6ba766d6d4f84b203d9e849b496ba7b958593df
arm: shutdown, smp and smpboot

Dummy implementation of machine_* and smp_*

Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
Signed-off-by: Tim Deegan <Tim.Deegan@xxxxxxxxxx>
Committed-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
---


diff -r a6ba766d6d4f -r d112c692b495 xen/arch/arm/shutdown.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/xen/arch/arm/shutdown.c   Thu Feb 09 11:33:30 2012 +0000
@@ -0,0 +1,23 @@
+#include <xen/config.h>
+#include <xen/lib.h>
+
+void machine_halt(void)
+{
+        /* TODO: halt */
+        while(1) ;
+}
+
+void machine_restart(unsigned int delay_millisecs)
+{
+        /* TODO: restart */
+        printk("Cannot restart yet\n");
+        while(1);
+}
+/*
+ * Local variables:
+ * mode: C
+ * c-set-style: "BSD"
+ * c-basic-offset: 4
+ * indent-tabs-mode: nil
+ * End:
+ */
diff -r a6ba766d6d4f -r d112c692b495 xen/arch/arm/smp.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/xen/arch/arm/smp.c        Thu Feb 09 11:33:30 2012 +0000
@@ -0,0 +1,29 @@
+#include <xen/config.h>
+#include <asm/smp.h>
+
+void smp_call_function(
+    void (*func) (void *info),
+    void *info,
+    int wait)
+{
+    /* TODO: No SMP just now, does not include self so nothing to do.
+       cpumask_t allbutself = cpu_online_map;
+       cpu_clear(smp_processor_id(), allbutself);
+       on_selected_cpus(&allbutself, func, info, wait);
+    */
+}
+void smp_send_event_check_mask(const cpumask_t *mask)
+{
+    /* TODO: No SMP just now, does not include self so nothing to do.
+       send_IPI_mask(mask, EVENT_CHECK_VECTOR);
+    */
+}
+
+/*
+ * Local variables:
+ * mode: C
+ * c-set-style: "BSD"
+ * c-basic-offset: 4
+ * indent-tabs-mode: nil
+ * End:
+ */
diff -r a6ba766d6d4f -r d112c692b495 xen/arch/arm/smpboot.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/xen/arch/arm/smpboot.c    Thu Feb 09 11:33:30 2012 +0000
@@ -0,0 +1,50 @@
+/*
+ * xen/arch/arm/smpboot.c
+ *
+ * Dummy smpboot support
+ *
+ * Copyright (c) 2011 Citrix Systems.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ */
+
+#include <xen/cpumask.h>
+#include <xen/smp.h>
+#include <xen/init.h>
+
+cpumask_t cpu_online_map;
+EXPORT_SYMBOL(cpu_online_map);
+cpumask_t cpu_present_map;
+EXPORT_SYMBOL(cpu_online_map);
+cpumask_t cpu_possible_map;
+EXPORT_SYMBOL(cpu_possible_map);
+
+void __init
+smp_prepare_cpus (unsigned int max_cpus)
+{
+        set_processor_id(0); /* needed early, for smp_processor_id() */
+
+        cpumask_clear(&cpu_online_map);
+        cpumask_clear(&cpu_present_map);
+        cpumask_clear(&cpu_possible_map);
+        cpumask_set_cpu(0, &cpu_online_map);
+        cpumask_set_cpu(0, &cpu_present_map);
+        cpumask_set_cpu(0, &cpu_possible_map);
+        return;
+}
+/*
+ * Local variables:
+ * mode: C
+ * c-set-style: "BSD"
+ * c-basic-offset: 4
+ * indent-tabs-mode: nil
+ * End:
+ */

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

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