aboutsummaryrefslogtreecommitdiffstats
path: root/include/asm-generic
diff options
context:
space:
mode:
Diffstat (limited to 'include/asm-generic')
-rw-r--r--include/asm-generic/Kbuild.asm5
-rw-r--r--include/asm-generic/device.h3
-rw-r--r--include/asm-generic/dma-mapping-common.h6
-rw-r--r--include/asm-generic/pci.h13
-rw-r--r--include/asm-generic/percpu.h3
-rw-r--r--include/asm-generic/socket.h3
-rw-r--r--include/asm-generic/vmlinux.lds.h24
7 files changed, 45 insertions, 12 deletions
diff --git a/include/asm-generic/Kbuild.asm b/include/asm-generic/Kbuild.asm
index 290910e4ede4..96d7c9804dc1 100644
--- a/include/asm-generic/Kbuild.asm
+++ b/include/asm-generic/Kbuild.asm
@@ -3,6 +3,11 @@ ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/asm/kvm.h \
3header-y += kvm.h 3header-y += kvm.h
4endif 4endif
5 5
6ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/asm/kvm_para.h \
7 $(srctree)/include/asm-$(SRCARCH)/kvm_para.h),)
8header-y += kvm_para.h
9endif
10
6ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/asm/a.out.h \ 11ifneq ($(wildcard $(srctree)/arch/$(SRCARCH)/include/asm/a.out.h \
7 $(srctree)/include/asm-$(SRCARCH)/a.out.h),) 12 $(srctree)/include/asm-$(SRCARCH)/a.out.h),)
8unifdef-y += a.out.h 13unifdef-y += a.out.h
diff --git a/include/asm-generic/device.h b/include/asm-generic/device.h
index c17c9600f220..d7c76bba640d 100644
--- a/include/asm-generic/device.h
+++ b/include/asm-generic/device.h
@@ -9,4 +9,7 @@
9struct dev_archdata { 9struct dev_archdata {
10}; 10};
11 11
12struct pdev_archdata {
13};
14
12#endif /* _ASM_GENERIC_DEVICE_H */ 15#endif /* _ASM_GENERIC_DEVICE_H */
diff --git a/include/asm-generic/dma-mapping-common.h b/include/asm-generic/dma-mapping-common.h
index 5406a601185c..e694263445f7 100644
--- a/include/asm-generic/dma-mapping-common.h
+++ b/include/asm-generic/dma-mapping-common.h
@@ -103,7 +103,6 @@ static inline void dma_sync_single_for_cpu(struct device *dev, dma_addr_t addr,
103 if (ops->sync_single_for_cpu) 103 if (ops->sync_single_for_cpu)
104 ops->sync_single_for_cpu(dev, addr, size, dir); 104 ops->sync_single_for_cpu(dev, addr, size, dir);
105 debug_dma_sync_single_for_cpu(dev, addr, size, dir); 105 debug_dma_sync_single_for_cpu(dev, addr, size, dir);
106 flush_write_buffers();
107} 106}
108 107
109static inline void dma_sync_single_for_device(struct device *dev, 108static inline void dma_sync_single_for_device(struct device *dev,
@@ -116,7 +115,6 @@ static inline void dma_sync_single_for_device(struct device *dev,
116 if (ops->sync_single_for_device) 115 if (ops->sync_single_for_device)
117 ops->sync_single_for_device(dev, addr, size, dir); 116 ops->sync_single_for_device(dev, addr, size, dir);
118 debug_dma_sync_single_for_device(dev, addr, size, dir); 117 debug_dma_sync_single_for_device(dev, addr, size, dir);
119 flush_write_buffers();
120} 118}
121 119
122static inline void dma_sync_single_range_for_cpu(struct device *dev, 120static inline void dma_sync_single_range_for_cpu(struct device *dev,
@@ -132,7 +130,6 @@ static inline void dma_sync_single_range_for_cpu(struct device *dev,
132 ops->sync_single_range_for_cpu(dev, addr, offset, size, dir); 130 ops->sync_single_range_for_cpu(dev, addr, offset, size, dir);
133 debug_dma_sync_single_range_for_cpu(dev, addr, offset, size, dir); 131 debug_dma_sync_single_range_for_cpu(dev, addr, offset, size, dir);
134 132
135 flush_write_buffers();
136 } else 133 } else
137 dma_sync_single_for_cpu(dev, addr, size, dir); 134 dma_sync_single_for_cpu(dev, addr, size, dir);
138} 135}
@@ -150,7 +147,6 @@ static inline void dma_sync_single_range_for_device(struct device *dev,
150 ops->sync_single_range_for_device(dev, addr, offset, size, dir); 147 ops->sync_single_range_for_device(dev, addr, offset, size, dir);
151 debug_dma_sync_single_range_for_device(dev, addr, offset, size, dir); 148 debug_dma_sync_single_range_for_device(dev, addr, offset, size, dir);
152 149
153 flush_write_buffers();
154 } else 150 } else
155 dma_sync_single_for_device(dev, addr, size, dir); 151 dma_sync_single_for_device(dev, addr, size, dir);
156} 152}
@@ -165,7 +161,6 @@ dma_sync_sg_for_cpu(struct device *dev, struct scatterlist *sg,
165 if (ops->sync_sg_for_cpu) 161 if (ops->sync_sg_for_cpu)
166 ops->sync_sg_for_cpu(dev, sg, nelems, dir); 162 ops->sync_sg_for_cpu(dev, sg, nelems, dir);
167 debug_dma_sync_sg_for_cpu(dev, sg, nelems, dir); 163 debug_dma_sync_sg_for_cpu(dev, sg, nelems, dir);
168 flush_write_buffers();
169} 164}
170 165
171static inline void 166static inline void
@@ -179,7 +174,6 @@ dma_sync_sg_for_device(struct device *dev, struct scatterlist *sg,
179 ops->sync_sg_for_device(dev, sg, nelems, dir); 174 ops->sync_sg_for_device(dev, sg, nelems, dir);
180 debug_dma_sync_sg_for_device(dev, sg, nelems, dir); 175 debug_dma_sync_sg_for_device(dev, sg, nelems, dir);
181 176
182 flush_write_buffers();
183} 177}
184 178
185#define dma_map_single(d, a, s, r) dma_map_single_attrs(d, a, s, r, NULL) 179#define dma_map_single(d, a, s, r) dma_map_single_attrs(d, a, s, r, NULL)
diff --git a/include/asm-generic/pci.h b/include/asm-generic/pci.h
index b4326b5466eb..26373cff4546 100644
--- a/include/asm-generic/pci.h
+++ b/include/asm-generic/pci.h
@@ -30,7 +30,18 @@ pcibios_bus_to_resource(struct pci_dev *dev, struct resource *res,
30 res->end = region->end; 30 res->end = region->end;
31} 31}
32 32
33#define pcibios_scan_all_fns(a, b) 0 33static inline struct resource *
34pcibios_select_root(struct pci_dev *pdev, struct resource *res)
35{
36 struct resource *root = NULL;
37
38 if (res->flags & IORESOURCE_IO)
39 root = &ioport_resource;
40 if (res->flags & IORESOURCE_MEM)
41 root = &iomem_resource;
42
43 return root;
44}
34 45
35#ifndef HAVE_ARCH_PCI_GET_LEGACY_IDE_IRQ 46#ifndef HAVE_ARCH_PCI_GET_LEGACY_IDE_IRQ
36static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel) 47static inline int pci_get_legacy_ide_irq(struct pci_dev *dev, int channel)
diff --git a/include/asm-generic/percpu.h b/include/asm-generic/percpu.h
index aa00800adacc..90079c373f1c 100644
--- a/include/asm-generic/percpu.h
+++ b/include/asm-generic/percpu.h
@@ -81,14 +81,17 @@ extern void setup_per_cpu_areas(void);
81 81
82#ifdef MODULE 82#ifdef MODULE
83#define PER_CPU_SHARED_ALIGNED_SECTION "" 83#define PER_CPU_SHARED_ALIGNED_SECTION ""
84#define PER_CPU_ALIGNED_SECTION ""
84#else 85#else
85#define PER_CPU_SHARED_ALIGNED_SECTION ".shared_aligned" 86#define PER_CPU_SHARED_ALIGNED_SECTION ".shared_aligned"
87#define PER_CPU_ALIGNED_SECTION ".shared_aligned"
86#endif 88#endif
87#define PER_CPU_FIRST_SECTION ".first" 89#define PER_CPU_FIRST_SECTION ".first"
88 90
89#else 91#else
90 92
91#define PER_CPU_SHARED_ALIGNED_SECTION "" 93#define PER_CPU_SHARED_ALIGNED_SECTION ""
94#define PER_CPU_ALIGNED_SECTION ".shared_aligned"
92#define PER_CPU_FIRST_SECTION "" 95#define PER_CPU_FIRST_SECTION ""
93 96
94#endif 97#endif
diff --git a/include/asm-generic/socket.h b/include/asm-generic/socket.h
index 5d79e409241c..538991cef6f0 100644
--- a/include/asm-generic/socket.h
+++ b/include/asm-generic/socket.h
@@ -60,4 +60,7 @@
60#define SO_TIMESTAMPING 37 60#define SO_TIMESTAMPING 37
61#define SCM_TIMESTAMPING SO_TIMESTAMPING 61#define SCM_TIMESTAMPING SO_TIMESTAMPING
62 62
63#define SO_PROTOCOL 38
64#define SO_DOMAIN 39
65
63#endif /* __ASM_GENERIC_SOCKET_H */ 66#endif /* __ASM_GENERIC_SOCKET_H */
diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h
index 98b37cf3ac6d..29ca8f53ffbe 100644
--- a/include/asm-generic/vmlinux.lds.h
+++ b/include/asm-generic/vmlinux.lds.h
@@ -33,13 +33,10 @@
33 * BSS_SECTION(0, 0, 0) 33 * BSS_SECTION(0, 0, 0)
34 * _end = .; 34 * _end = .;
35 * 35 *
36 * /DISCARD/ : {
37 * EXIT_TEXT
38 * EXIT_DATA
39 * EXIT_CALL
40 * }
41 * STABS_DEBUG 36 * STABS_DEBUG
42 * DWARF_DEBUG 37 * DWARF_DEBUG
38 *
39 * DISCARDS // must be the last
43 * } 40 * }
44 * 41 *
45 * [__init_begin, __init_end] is the init section that may be freed after init 42 * [__init_begin, __init_end] is the init section that may be freed after init
@@ -627,6 +624,23 @@
627#define INIT_RAM_FS 624#define INIT_RAM_FS
628#endif 625#endif
629 626
627/*
628 * Default discarded sections.
629 *
630 * Some archs want to discard exit text/data at runtime rather than
631 * link time due to cross-section references such as alt instructions,
632 * bug table, eh_frame, etc. DISCARDS must be the last of output
633 * section definitions so that such archs put those in earlier section
634 * definitions.
635 */
636#define DISCARDS \
637 /DISCARD/ : { \
638 EXIT_TEXT \
639 EXIT_DATA \
640 EXIT_CALL \
641 *(.discard) \
642 }
643
630/** 644/**
631 * PERCPU_VADDR - define output section for percpu area 645 * PERCPU_VADDR - define output section for percpu area
632 * @vaddr: explicit base address (optional) 646 * @vaddr: explicit base address (optional)