diff options
Diffstat (limited to 'arch/ia64')
-rw-r--r-- | arch/ia64/include/asm/Kbuild | 1 | ||||
-rw-r--r-- | arch/ia64/include/asm/atomic.h | 6 | ||||
-rw-r--r-- | arch/ia64/include/asm/byteorder.h | 37 | ||||
-rw-r--r-- | arch/ia64/include/asm/swab.h | 34 | ||||
-rw-r--r-- | arch/ia64/include/asm/swiotlb.h | 39 | ||||
-rw-r--r-- | arch/ia64/kernel/kprobes.c | 8 | ||||
-rw-r--r-- | arch/ia64/kernel/pci-dma.c | 2 | ||||
-rw-r--r-- | arch/ia64/mm/init.c | 2 | ||||
-rw-r--r-- | arch/ia64/sn/kernel/tiocx.c | 3 |
9 files changed, 45 insertions, 87 deletions
diff --git a/arch/ia64/include/asm/Kbuild b/arch/ia64/include/asm/Kbuild index ccbe8ae47a6..3b25bd9dca9 100644 --- a/arch/ia64/include/asm/Kbuild +++ b/arch/ia64/include/asm/Kbuild | |||
@@ -14,3 +14,4 @@ unifdef-y += gcc_intrin.h | |||
14 | unifdef-y += intrinsics.h | 14 | unifdef-y += intrinsics.h |
15 | unifdef-y += perfmon.h | 15 | unifdef-y += perfmon.h |
16 | unifdef-y += ustack.h | 16 | unifdef-y += ustack.h |
17 | unifdef-y += swab.h | ||
diff --git a/arch/ia64/include/asm/atomic.h b/arch/ia64/include/asm/atomic.h index 50c2b83fd5a..d37292bd987 100644 --- a/arch/ia64/include/asm/atomic.h +++ b/arch/ia64/include/asm/atomic.h | |||
@@ -17,12 +17,6 @@ | |||
17 | #include <asm/intrinsics.h> | 17 | #include <asm/intrinsics.h> |
18 | #include <asm/system.h> | 18 | #include <asm/system.h> |
19 | 19 | ||
20 | /* | ||
21 | * On IA-64, counter must always be volatile to ensure that that the | ||
22 | * memory accesses are ordered. | ||
23 | */ | ||
24 | typedef struct { volatile __s32 counter; } atomic_t; | ||
25 | typedef struct { volatile __s64 counter; } atomic64_t; | ||
26 | 20 | ||
27 | #define ATOMIC_INIT(i) ((atomic_t) { (i) }) | 21 | #define ATOMIC_INIT(i) ((atomic_t) { (i) }) |
28 | #define ATOMIC64_INIT(i) ((atomic64_t) { (i) }) | 22 | #define ATOMIC64_INIT(i) ((atomic64_t) { (i) }) |
diff --git a/arch/ia64/include/asm/byteorder.h b/arch/ia64/include/asm/byteorder.h index 69bd41d7c26..0f84c5cb703 100644 --- a/arch/ia64/include/asm/byteorder.h +++ b/arch/ia64/include/asm/byteorder.h | |||
@@ -1,42 +1,7 @@ | |||
1 | #ifndef _ASM_IA64_BYTEORDER_H | 1 | #ifndef _ASM_IA64_BYTEORDER_H |
2 | #define _ASM_IA64_BYTEORDER_H | 2 | #define _ASM_IA64_BYTEORDER_H |
3 | 3 | ||
4 | /* | 4 | #include <asm/swab.h> |
5 | * Modified 1998, 1999 | ||
6 | * David Mosberger-Tang <davidm@hpl.hp.com>, Hewlett-Packard Co. | ||
7 | */ | ||
8 | |||
9 | #include <asm/types.h> | ||
10 | #include <asm/intrinsics.h> | ||
11 | #include <linux/compiler.h> | ||
12 | |||
13 | static __inline__ __attribute_const__ __u64 | ||
14 | __ia64_swab64 (__u64 x) | ||
15 | { | ||
16 | __u64 result; | ||
17 | |||
18 | result = ia64_mux1(x, ia64_mux1_rev); | ||
19 | return result; | ||
20 | } | ||
21 | |||
22 | static __inline__ __attribute_const__ __u32 | ||
23 | __ia64_swab32 (__u32 x) | ||
24 | { | ||
25 | return __ia64_swab64(x) >> 32; | ||
26 | } | ||
27 | |||
28 | static __inline__ __attribute_const__ __u16 | ||
29 | __ia64_swab16(__u16 x) | ||
30 | { | ||
31 | return __ia64_swab64(x) >> 48; | ||
32 | } | ||
33 | |||
34 | #define __arch__swab64(x) __ia64_swab64(x) | ||
35 | #define __arch__swab32(x) __ia64_swab32(x) | ||
36 | #define __arch__swab16(x) __ia64_swab16(x) | ||
37 | |||
38 | #define __BYTEORDER_HAS_U64__ | ||
39 | |||
40 | #include <linux/byteorder/little_endian.h> | 5 | #include <linux/byteorder/little_endian.h> |
41 | 6 | ||
42 | #endif /* _ASM_IA64_BYTEORDER_H */ | 7 | #endif /* _ASM_IA64_BYTEORDER_H */ |
diff --git a/arch/ia64/include/asm/swab.h b/arch/ia64/include/asm/swab.h new file mode 100644 index 00000000000..6aa58b699ee --- /dev/null +++ b/arch/ia64/include/asm/swab.h | |||
@@ -0,0 +1,34 @@ | |||
1 | #ifndef _ASM_IA64_SWAB_H | ||
2 | #define _ASM_IA64_SWAB_H | ||
3 | |||
4 | /* | ||
5 | * Modified 1998, 1999 | ||
6 | * David Mosberger-Tang <davidm@hpl.hp.com>, Hewlett-Packard Co. | ||
7 | */ | ||
8 | |||
9 | #include <asm/types.h> | ||
10 | #include <asm/intrinsics.h> | ||
11 | #include <linux/compiler.h> | ||
12 | |||
13 | static __inline__ __attribute_const__ __u64 __arch_swab64(__u64 x) | ||
14 | { | ||
15 | __u64 result; | ||
16 | |||
17 | result = ia64_mux1(x, ia64_mux1_rev); | ||
18 | return result; | ||
19 | } | ||
20 | #define __arch_swab64 __arch_swab64 | ||
21 | |||
22 | static __inline__ __attribute_const__ __u32 __arch_swab32(__u32 x) | ||
23 | { | ||
24 | return __arch_swab64(x) >> 32; | ||
25 | } | ||
26 | #define __arch_swab32 __arch_swab32 | ||
27 | |||
28 | static __inline__ __attribute_const__ __u16 __arch_swab16(__u16 x) | ||
29 | { | ||
30 | return __arch_swab64(x) >> 48; | ||
31 | } | ||
32 | #define __arch_swab16 __arch_swab16 | ||
33 | |||
34 | #endif /* _ASM_IA64_SWAB_H */ | ||
diff --git a/arch/ia64/include/asm/swiotlb.h b/arch/ia64/include/asm/swiotlb.h index fb79423834d..dcbaea7ce12 100644 --- a/arch/ia64/include/asm/swiotlb.h +++ b/arch/ia64/include/asm/swiotlb.h | |||
@@ -2,44 +2,7 @@ | |||
2 | #define ASM_IA64__SWIOTLB_H | 2 | #define ASM_IA64__SWIOTLB_H |
3 | 3 | ||
4 | #include <linux/dma-mapping.h> | 4 | #include <linux/dma-mapping.h> |
5 | 5 | #include <linux/swiotlb.h> | |
6 | /* SWIOTLB interface */ | ||
7 | |||
8 | extern dma_addr_t swiotlb_map_single(struct device *hwdev, void *ptr, | ||
9 | size_t size, int dir); | ||
10 | extern void *swiotlb_alloc_coherent(struct device *hwdev, size_t size, | ||
11 | dma_addr_t *dma_handle, gfp_t flags); | ||
12 | extern void swiotlb_unmap_single(struct device *hwdev, dma_addr_t dev_addr, | ||
13 | size_t size, int dir); | ||
14 | extern void swiotlb_sync_single_for_cpu(struct device *hwdev, | ||
15 | dma_addr_t dev_addr, | ||
16 | size_t size, int dir); | ||
17 | extern void swiotlb_sync_single_for_device(struct device *hwdev, | ||
18 | dma_addr_t dev_addr, | ||
19 | size_t size, int dir); | ||
20 | extern void swiotlb_sync_single_range_for_cpu(struct device *hwdev, | ||
21 | dma_addr_t dev_addr, | ||
22 | unsigned long offset, | ||
23 | size_t size, int dir); | ||
24 | extern void swiotlb_sync_single_range_for_device(struct device *hwdev, | ||
25 | dma_addr_t dev_addr, | ||
26 | unsigned long offset, | ||
27 | size_t size, int dir); | ||
28 | extern void swiotlb_sync_sg_for_cpu(struct device *hwdev, | ||
29 | struct scatterlist *sg, int nelems, | ||
30 | int dir); | ||
31 | extern void swiotlb_sync_sg_for_device(struct device *hwdev, | ||
32 | struct scatterlist *sg, int nelems, | ||
33 | int dir); | ||
34 | extern int swiotlb_map_sg(struct device *hwdev, struct scatterlist *sg, | ||
35 | int nents, int direction); | ||
36 | extern void swiotlb_unmap_sg(struct device *hwdev, struct scatterlist *sg, | ||
37 | int nents, int direction); | ||
38 | extern int swiotlb_dma_mapping_error(struct device *hwdev, dma_addr_t dma_addr); | ||
39 | extern void swiotlb_free_coherent(struct device *hwdev, size_t size, | ||
40 | void *vaddr, dma_addr_t dma_handle); | ||
41 | extern int swiotlb_dma_supported(struct device *hwdev, u64 mask); | ||
42 | extern void swiotlb_init(void); | ||
43 | 6 | ||
44 | extern int swiotlb_force; | 7 | extern int swiotlb_force; |
45 | 8 | ||
diff --git a/arch/ia64/kernel/kprobes.c b/arch/ia64/kernel/kprobes.c index 0017b9de2dd..f90be51b112 100644 --- a/arch/ia64/kernel/kprobes.c +++ b/arch/ia64/kernel/kprobes.c | |||
@@ -670,9 +670,11 @@ void __kprobes arch_disarm_kprobe(struct kprobe *p) | |||
670 | 670 | ||
671 | void __kprobes arch_remove_kprobe(struct kprobe *p) | 671 | void __kprobes arch_remove_kprobe(struct kprobe *p) |
672 | { | 672 | { |
673 | mutex_lock(&kprobe_mutex); | 673 | if (p->ainsn.insn) { |
674 | free_insn_slot(p->ainsn.insn, p->ainsn.inst_flag & INST_FLAG_BOOSTABLE); | 674 | free_insn_slot(p->ainsn.insn, |
675 | mutex_unlock(&kprobe_mutex); | 675 | p->ainsn.inst_flag & INST_FLAG_BOOSTABLE); |
676 | p->ainsn.insn = NULL; | ||
677 | } | ||
676 | } | 678 | } |
677 | /* | 679 | /* |
678 | * We are resuming execution after a single step fault, so the pt_regs | 680 | * We are resuming execution after a single step fault, so the pt_regs |
diff --git a/arch/ia64/kernel/pci-dma.c b/arch/ia64/kernel/pci-dma.c index 2a92f637431..d0ada067a4a 100644 --- a/arch/ia64/kernel/pci-dma.c +++ b/arch/ia64/kernel/pci-dma.c | |||
@@ -39,7 +39,7 @@ int iommu_detected __read_mostly; | |||
39 | be probably a smaller DMA mask, but this is bug-to-bug compatible | 39 | be probably a smaller DMA mask, but this is bug-to-bug compatible |
40 | to i386. */ | 40 | to i386. */ |
41 | struct device fallback_dev = { | 41 | struct device fallback_dev = { |
42 | .bus_id = "fallback device", | 42 | .init_name = "fallback device", |
43 | .coherent_dma_mask = DMA_32BIT_MASK, | 43 | .coherent_dma_mask = DMA_32BIT_MASK, |
44 | .dma_mask = &fallback_dev.coherent_dma_mask, | 44 | .dma_mask = &fallback_dev.coherent_dma_mask, |
45 | }; | 45 | }; |
diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c index 054bcd9439a..56e12903973 100644 --- a/arch/ia64/mm/init.c +++ b/arch/ia64/mm/init.c | |||
@@ -692,7 +692,7 @@ int arch_add_memory(int nid, u64 start, u64 size) | |||
692 | pgdat = NODE_DATA(nid); | 692 | pgdat = NODE_DATA(nid); |
693 | 693 | ||
694 | zone = pgdat->node_zones + ZONE_NORMAL; | 694 | zone = pgdat->node_zones + ZONE_NORMAL; |
695 | ret = __add_pages(zone, start_pfn, nr_pages); | 695 | ret = __add_pages(nid, zone, start_pfn, nr_pages); |
696 | 696 | ||
697 | if (ret) | 697 | if (ret) |
698 | printk("%s: Problem encountered in __add_pages() as ret=%d\n", | 698 | printk("%s: Problem encountered in __add_pages() as ret=%d\n", |
diff --git a/arch/ia64/sn/kernel/tiocx.c b/arch/ia64/sn/kernel/tiocx.c index a88eba3314d..3f864238566 100644 --- a/arch/ia64/sn/kernel/tiocx.c +++ b/arch/ia64/sn/kernel/tiocx.c | |||
@@ -206,8 +206,7 @@ cx_device_register(nasid_t nasid, int part_num, int mfg_num, | |||
206 | cx_dev->dev.parent = NULL; | 206 | cx_dev->dev.parent = NULL; |
207 | cx_dev->dev.bus = &tiocx_bus_type; | 207 | cx_dev->dev.bus = &tiocx_bus_type; |
208 | cx_dev->dev.release = tiocx_bus_release; | 208 | cx_dev->dev.release = tiocx_bus_release; |
209 | snprintf(cx_dev->dev.bus_id, BUS_ID_SIZE, "%d", | 209 | dev_set_name(&cx_dev->dev, "%d", cx_dev->cx_id.nasid); |
210 | cx_dev->cx_id.nasid); | ||
211 | device_register(&cx_dev->dev); | 210 | device_register(&cx_dev->dev); |
212 | get_device(&cx_dev->dev); | 211 | get_device(&cx_dev->dev); |
213 | 212 | ||