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

[Xen-changelog] [xen-unstable] force inclusion of xen/config.h through compiler option



# HG changeset patch
# User Jan Beulich <jbeulich@xxxxxxxx>
# Date 1326440011 -3600
# Node ID 86b8a1e3a419943801968da12042b4fe53fff537
# Parent  c5eadfd5c639a494b58cf6c0675b8f78412bcf43
force inclusion of xen/config.h through compiler option

As we expect all source files to include the header as the first thing
anyway, stop doing this by repeating the inclusion in each and every
source file (and in many headers), but rather enforce this uniformly
through the compiler command line.

As a first cleanup step, remove the explicit inclusion from all common
headers. Further cleanup can be done incrementally.

Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
Acked-by: Keir Fraser <keir@xxxxxxx>
---


diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/Rules.mk
--- a/xen/Rules.mk      Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/Rules.mk      Fri Jan 13 08:33:31 2012 +0100
@@ -41,7 +41,7 @@
 ALL_OBJS-y               += $(BASEDIR)/arch/$(TARGET_ARCH)/built_in.o
 ALL_OBJS-$(x86)          += $(BASEDIR)/crypto/built_in.o
 
-CFLAGS-y                += -g -D__XEN__
+CFLAGS-y                += -g -D__XEN__ --include 
$(BASEDIR)/include/xen/config.h
 CFLAGS-$(XSM_ENABLE)    += -DXSM_ENABLE
 CFLAGS-$(FLASK_ENABLE)  += -DFLASK_ENABLE -DXSM_MAGIC=0xf97cff8c
 CFLAGS-$(FLASK_ENABLE)  += -DFLASK_DEVELOP -DFLASK_BOOTPARAM -DFLASK_AVC_STATS
@@ -59,7 +59,7 @@
 CFLAGS-y                += -DMAX_PHYS_IRQS=$(max_phys_irqs)
 endif
 
-AFLAGS-y                += -D__ASSEMBLY__
+AFLAGS-y                += -D__ASSEMBLY__ --include 
$(BASEDIR)/include/xen/config.h
 
 # Clang's built-in assembler can't handle .code16/.code32/.code64 yet
 AFLAGS-$(clang)         += -no-integrated-as
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/bitmap.h
--- a/xen/include/xen/bitmap.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/bitmap.h  Fri Jan 13 08:33:31 2012 +0100
@@ -3,7 +3,6 @@
 
 #ifndef __ASSEMBLY__
 
-#include <xen/config.h>
 #include <xen/lib.h>
 #include <xen/types.h>
 #include <xen/bitops.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/byteorder/swab.h
--- a/xen/include/xen/byteorder/swab.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/byteorder/swab.h  Fri Jan 13 08:33:31 2012 +0100
@@ -10,8 +10,6 @@
  *    to clean up support for bizarre-endian architectures.
  */
 
-#include <xen/compiler.h>
-
 /* casts are necessary for constants, because we never know how for sure
  * how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way.
  */
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/cache.h
--- a/xen/include/xen/cache.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/cache.h   Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __LINUX_CACHE_H
 #define __LINUX_CACHE_H
 
-#include <xen/config.h>
 #include <asm/cache.h>
 
 #ifndef L1_CACHE_ALIGN
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/compat.h
--- a/xen/include/xen/compat.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/compat.h  Fri Jan 13 08:33:31 2012 +0100
@@ -5,8 +5,6 @@
 #ifndef __XEN_COMPAT_H__
 #define __XEN_COMPAT_H__
 
-#include <xen/config.h>
-
 #ifdef CONFIG_COMPAT
 
 #include <xen/types.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/cpumask.h
--- a/xen/include/xen/cpumask.h Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/cpumask.h Fri Jan 13 08:33:31 2012 +0100
@@ -75,7 +75,6 @@
  *    inside a macro, the way we do the other calls.
  */
 
-#include <xen/config.h>
 #include <xen/bitmap.h>
 #include <xen/kernel.h>
 
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/ctype.h
--- a/xen/include/xen/ctype.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/ctype.h   Fri Jan 13 08:33:31 2012 +0100
@@ -1,8 +1,6 @@
 #ifndef _LINUX_CTYPE_H
 #define _LINUX_CTYPE_H
 
-#include <xen/config.h>
-
 /*
  * NOTE! This ctype does not handle EOF like the standard C
  * library is required to.
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/domain_page.h
--- a/xen/include/xen/domain_page.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/domain_page.h     Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
 #ifndef __XEN_DOMAIN_PAGE_H__
 #define __XEN_DOMAIN_PAGE_H__
 
-#include <xen/config.h>
 #include <xen/mm.h>
 
 #ifdef CONFIG_DOMAIN_PAGE
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/event.h
--- a/xen/include/xen/event.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/event.h   Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
 #ifndef __XEN_EVENT_H__
 #define __XEN_EVENT_H__
 
-#include <xen/config.h>
 #include <xen/sched.h>
 #include <xen/smp.h>
 #include <xen/softirq.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/grant_table.h
--- a/xen/include/xen/grant_table.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/grant_table.h     Fri Jan 13 08:33:31 2012 +0100
@@ -24,7 +24,6 @@
 #ifndef __XEN_GRANT_TABLE_H__
 #define __XEN_GRANT_TABLE_H__
 
-#include <xen/config.h>
 #include <public/grant_table.h>
 #include <asm/grant_table.h>
 
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/hypercall.h
--- a/xen/include/xen/hypercall.h       Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/hypercall.h       Fri Jan 13 08:33:31 2012 +0100
@@ -5,7 +5,6 @@
 #ifndef __XEN_HYPERCALL_H__
 #define __XEN_HYPERCALL_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/time.h>
 #include <public/xen.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/init.h
--- a/xen/include/xen/init.h    Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/init.h    Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef _LINUX_INIT_H
 #define _LINUX_INIT_H
 
-#include <xen/config.h>
 #include <asm/init.h>
 
 /*
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/inttypes.h
--- a/xen/include/xen/inttypes.h        Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/inttypes.h        Fri Jan 13 08:33:31 2012 +0100
@@ -23,7 +23,6 @@
 #ifndef _XEN_INTTYPES_H
 #define _XEN_INTTYPES_H        1
 
-#include <xen/config.h>
 #include <xen/types.h>
 
 # if BITS_PER_LONG == 64
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/irq.h
--- a/xen/include/xen/irq.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/irq.h     Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __XEN_IRQ_H__
 #define __XEN_IRQ_H__
 
-#include <xen/config.h>
 #include <xen/cpumask.h>
 #include <xen/rcupdate.h>
 #include <xen/spinlock.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/irq_cpustat.h
--- a/xen/include/xen/irq_cpustat.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/irq_cpustat.h     Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
  * Keith Owens <kaos@xxxxxxxxxx> July 2000.
  */
 
-#include <xen/config.h>
 #include <asm/hardirq.h>
 
 /*
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/lib.h
--- a/xen/include/xen/lib.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/lib.h     Fri Jan 13 08:33:31 2012 +0100
@@ -3,7 +3,6 @@
 
 #include <xen/inttypes.h>
 #include <xen/stdarg.h>
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/xmalloc.h>
 #include <xen/string.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/mm.h
--- a/xen/include/xen/mm.h      Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/mm.h      Fri Jan 13 08:33:31 2012 +0100
@@ -28,7 +28,6 @@
 #ifndef __XEN_MM_H__
 #define __XEN_MM_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/list.h>
 #include <xen/spinlock.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/notifier.h
--- a/xen/include/xen/notifier.h        Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/notifier.h        Fri Jan 13 08:33:31 2012 +0100
@@ -10,7 +10,6 @@
 #ifndef __XEN_NOTIFIER_H__
 #define __XEN_NOTIFIER_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/errno.h>
 #include <xen/kernel.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/numa.h
--- a/xen/include/xen/numa.h    Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/numa.h    Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef _XEN_NUMA_H
 #define _XEN_NUMA_H
 
-#include <xen/config.h>
 #include <asm/numa.h>
 
 #ifndef NODES_SHIFT
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/paging.h
--- a/xen/include/xen/paging.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/paging.h  Fri Jan 13 08:33:31 2012 +0100
@@ -2,8 +2,6 @@
 #ifndef __XEN_PAGING_H__
 #define __XEN_PAGING_H__
 
-#include <xen/config.h>
-
 #if defined CONFIG_PAGING_ASSISTANCE
 
 #include <asm/paging.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/pci.h
--- a/xen/include/xen/pci.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/pci.h     Fri Jan 13 08:33:31 2012 +0100
@@ -7,7 +7,6 @@
 #ifndef __XEN_PCI_H__
 #define __XEN_PCI_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/list.h>
 #include <xen/spinlock.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/percpu.h
--- a/xen/include/xen/percpu.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/percpu.h  Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __XEN_PERCPU_H__
 #define __XEN_PERCPU_H__
 
-#include <xen/config.h>
 #include <asm/percpu.h>
 
 /*
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/preempt.h
--- a/xen/include/xen/preempt.h Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/preempt.h Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
 #ifndef __XEN_PREEMPT_H__
 #define __XEN_PREEMPT_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/percpu.h>
 
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/radix-tree.h
--- a/xen/include/xen/radix-tree.h      Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/radix-tree.h      Fri Jan 13 08:33:31 2012 +0100
@@ -20,7 +20,6 @@
 #ifndef _XEN_RADIX_TREE_H
 #define _XEN_RADIX_TREE_H
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/lib.h>
 #include <xen/rcupdate.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/sched.h
--- a/xen/include/xen/sched.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/sched.h   Fri Jan 13 08:33:31 2012 +0100
@@ -2,7 +2,6 @@
 #ifndef __SCHED_H__
 #define __SCHED_H__
 
-#include <xen/config.h>
 #include <xen/types.h>
 #include <xen/spinlock.h>
 #include <xen/shared.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/shared.h
--- a/xen/include/xen/shared.h  Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/shared.h  Fri Jan 13 08:33:31 2012 +0100
@@ -1,8 +1,6 @@
 #ifndef __XEN_SHARED_H__
 #define __XEN_SHARED_H__
 
-#include <xen/config.h>
-
 #ifdef CONFIG_COMPAT
 
 #include <compat/xen.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/smp.h
--- a/xen/include/xen/smp.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/smp.h     Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __XEN_SMP_H__
 #define __XEN_SMP_H__
 
-#include <xen/config.h>
 #include <asm/smp.h>
 
 /*
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/softirq.h
--- a/xen/include/xen/softirq.h Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/softirq.h Fri Jan 13 08:33:31 2012 +0100
@@ -11,7 +11,6 @@
     NR_COMMON_SOFTIRQS
 };
 
-#include <xen/config.h>
 #include <xen/lib.h>
 #include <xen/smp.h>
 #include <asm/bitops.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/spinlock.h
--- a/xen/include/xen/spinlock.h        Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/spinlock.h        Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __SPINLOCK_H__
 #define __SPINLOCK_H__
 
-#include <xen/config.h>
 #include <asm/system.h>
 #include <asm/spinlock.h>
 
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/symbols.h
--- a/xen/include/xen/symbols.h Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/symbols.h Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef _XEN_SYMBOLS_H
 #define _XEN_SYMBOLS_H
 
-#include <xen/config.h>
 #include <xen/types.h>
 
 #define KSYM_NAME_LEN 127
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/tmem_xen.h
--- a/xen/include/xen/tmem_xen.h        Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/tmem_xen.h        Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
 #ifndef __XEN_TMEM_XEN_H__
 #define __XEN_TMEM_XEN_H__
 
-#include <xen/config.h>
 #include <xen/mm.h> /* heap alloc/free */
 #include <xen/xmalloc.h> /* xmalloc/xfree */
 #include <xen/sched.h>  /* struct domain */
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/trace.h
--- a/xen/include/xen/trace.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/trace.h   Fri Jan 13 08:33:31 2012 +0100
@@ -23,7 +23,6 @@
 
 extern int tb_init_done;
 
-#include <xen/config.h>
 #include <public/sysctl.h>
 #include <public/trace.h>
 #include <asm/trace.h>
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/types.h
--- a/xen/include/xen/types.h   Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/types.h   Fri Jan 13 08:33:31 2012 +0100
@@ -1,7 +1,6 @@
 #ifndef __TYPES_H__
 #define __TYPES_H__
 
-#include <xen/config.h>
 #include <asm/types.h>
 
 #define BITS_TO_LONGS(bits) \
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/vga.h
--- a/xen/include/xen/vga.h     Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/vga.h     Fri Jan 13 08:33:31 2012 +0100
@@ -9,7 +9,6 @@
 #ifndef _XEN_VGA_H
 #define _XEN_VGA_H
 
-#include <xen/config.h>
 #include <public/xen.h>
 
 #ifdef CONFIG_VGA
diff -r c5eadfd5c639 -r 86b8a1e3a419 xen/include/xen/xenoprof.h
--- a/xen/include/xen/xenoprof.h        Thu Jan 12 17:51:11 2012 +0000
+++ b/xen/include/xen/xenoprof.h        Fri Jan 13 08:33:31 2012 +0100
@@ -10,7 +10,6 @@
 #ifndef __XEN_XENOPROF_H__
 #define __XEN_XENOPROF_H__
 
-#include <xen/config.h>
 #include <xen/inttypes.h>
 #include <public/xenoprof.h>
 #include <asm/xenoprof.h>

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