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

[Xen-changelog] [xen-unstable] ACPI: __init-annotate APEI code



# HG changeset patch
# User Keir Fraser <keir@xxxxxxx>
# Date 1293185698 0
# Node ID 0292bec5e98d6fda3a40eab65cfa0c4e6d34a37d
# Parent  609da2035aab670e2c11f445e7eecdb21f88a775
ACPI: __init-annotate APEI code

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
 xen/drivers/acpi/apei/apei-base.c |   25 +++++++++++++------------
 xen/drivers/acpi/apei/apei-io.c   |   10 +++++-----
 xen/drivers/acpi/apei/erst.c      |    4 ++--
 3 files changed, 20 insertions(+), 19 deletions(-)

diff -r 609da2035aab -r 0292bec5e98d xen/drivers/acpi/apei/apei-base.c
--- a/xen/drivers/acpi/apei/apei-base.c Fri Dec 24 10:14:36 2010 +0000
+++ b/xen/drivers/acpi/apei/apei-base.c Fri Dec 24 10:14:58 2010 +0000
@@ -37,6 +37,7 @@
 #include <xen/string.h>
 #include <xen/types.h>
 #include <xen/spinlock.h>
+#include <xen/init.h>
 #include <xen/cper.h>
 #include <asm/io.h>
 #include <acpi/acpi.h>
@@ -201,10 +202,10 @@ typedef int (*apei_exec_entry_func_t)(st
                                      struct acpi_whea_header *entry,
                                      void *data);
 
-static int apei_exec_for_each_entry(struct apei_exec_context *ctx,
-                                   apei_exec_entry_func_t func,
-                                   void *data,
-                                   int *end)
+static int __init apei_exec_for_each_entry(struct apei_exec_context *ctx,
+                                          apei_exec_entry_func_t func,
+                                          void *data,
+                                          int *end)
 {
        u8 ins;
        int i, rc;
@@ -229,9 +230,9 @@ static int apei_exec_for_each_entry(stru
        return 0;
 }
 
-static int pre_map_gar_callback(struct apei_exec_context *ctx,
-                               struct acpi_whea_header *entry,
-                               void *data)
+static int __init pre_map_gar_callback(struct apei_exec_context *ctx,
+                                      struct acpi_whea_header *entry,
+                                      void *data)
 {
        u8 ins = entry->instruction;
 
@@ -242,7 +243,7 @@ static int pre_map_gar_callback(struct a
 }
 
 /* Pre-map all GARs in action table. */
-int apei_exec_pre_map_gars(struct apei_exec_context *ctx)
+int __init apei_exec_pre_map_gars(struct apei_exec_context *ctx)
 {
        int rc, end;
 
@@ -258,9 +259,9 @@ int apei_exec_pre_map_gars(struct apei_e
        return rc;
 }
 
-static int post_unmap_gar_callback(struct apei_exec_context *ctx,
-                                  struct acpi_whea_header *entry,
-                                  void *data)
+static int __init post_unmap_gar_callback(struct apei_exec_context *ctx,
+                                         struct acpi_whea_header *entry,
+                                         void *data)
 {
        u8 ins = entry->instruction;
 
@@ -271,7 +272,7 @@ static int post_unmap_gar_callback(struc
 }
 
 /* Post-unmap all GAR in action table. */
-int apei_exec_post_unmap_gars(struct apei_exec_context *ctx)
+int __init apei_exec_post_unmap_gars(struct apei_exec_context *ctx)
 {
        return apei_exec_for_each_entry(ctx, post_unmap_gar_callback,
                                        NULL, NULL);
diff -r 609da2035aab -r 0292bec5e98d xen/drivers/acpi/apei/apei-io.c
--- a/xen/drivers/acpi/apei/apei-io.c   Fri Dec 24 10:14:36 2010 +0000
+++ b/xen/drivers/acpi/apei/apei-io.c   Fri Dec 24 10:14:58 2010 +0000
@@ -75,7 +75,7 @@ static void __iomem *__apei_ioremap_fast
 
 static int apei_range_nr;
 
-static void __iomem *apei_range_map(paddr_t paddr, unsigned long size)
+static void __iomem *__init apei_range_map(paddr_t paddr, unsigned long size)
 {
        int i, pg;
        int start_nr, cur_nr;
@@ -101,7 +101,7 @@ static void __iomem *apei_range_map(padd
  * whether the area is already pre-mapped, if it is, return; otherwise,
  * do the real map, and add the mapping into apei_iomaps list.
  */
-void __iomem *apei_pre_map(paddr_t paddr, unsigned long size)
+void __iomem *__init apei_pre_map(paddr_t paddr, unsigned long size)
 {
        void __iomem *vaddr;
        struct apei_iomap *map;
@@ -139,7 +139,7 @@ void __iomem *apei_pre_map(paddr_t paddr
 /*
  * Used to post-unmap the specified IO memory area.
  */
-static void apei_post_unmap(paddr_t paddr, unsigned long size)
+static void __init apei_post_unmap(paddr_t paddr, unsigned long size)
 {
        struct apei_iomap *map;
        unsigned long flags;
@@ -191,7 +191,7 @@ static int apei_check_gar(struct acpi_ge
 }
 
 /* Pre-map, working on GAR */
-int apei_pre_map_gar(struct acpi_generic_address *reg)
+int __init apei_pre_map_gar(struct acpi_generic_address *reg)
 {
        u64 paddr;
        void __iomem *vaddr;
@@ -212,7 +212,7 @@ int apei_pre_map_gar(struct acpi_generic
 }
 
 /* Post-unmap, working on GAR */
-int apei_post_unmap_gar(struct acpi_generic_address *reg)
+int __init apei_post_unmap_gar(struct acpi_generic_address *reg)
 {
        u64 paddr;
        int rc;
diff -r 609da2035aab -r 0292bec5e98d xen/drivers/acpi/apei/erst.c
--- a/xen/drivers/acpi/apei/erst.c      Fri Dec 24 10:14:36 2010 +0000
+++ b/xen/drivers/acpi/apei/erst.c      Fri Dec 24 10:14:58 2010 +0000
@@ -713,7 +713,7 @@ int erst_clear(u64 record_id)
        return rc;
 }
 
-static int erst_check_table(struct acpi_table_erst *erst_tab)
+static int __init erst_check_table(struct acpi_table_erst *erst_tab)
 {
        if (erst_tab->header_length != sizeof(struct acpi_table_erst))
                return -EINVAL;
@@ -727,7 +727,7 @@ static int erst_check_table(struct acpi_
        return 0;
 }
 
-int erst_init(void)
+int __init erst_init(void)
 {
        int rc = 0;
        acpi_status status;

_______________________________________________
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®.