diff options
author | Ingo Molnar <mingo@elte.hu> | 2009-01-10 18:51:06 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-01-10 18:51:06 -0500 |
commit | 0811a433c61e85f895018239c4466a36311cd5de (patch) | |
tree | 276933e518e5525d24ae37b02df2db9909679260 /arch/ia64 | |
parent | c299030765292434b73572f9bcfe84951ff06614 (diff) | |
parent | 3d14bdad40315b54470cb7812293d14c8af2bf7d (diff) |
Merge branch 'linus' into core/iommu
Diffstat (limited to 'arch/ia64')
-rw-r--r-- | arch/ia64/include/asm/Kbuild | 1 | ||||
-rw-r--r-- | arch/ia64/include/asm/acpi-ext.h | 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/irq.h | 2 | ||||
-rw-r--r-- | arch/ia64/include/asm/sn/acpi.h | 2 | ||||
-rw-r--r-- | arch/ia64/include/asm/swab.h | 34 | ||||
-rw-r--r-- | arch/ia64/include/asm/topology.h | 2 | ||||
-rw-r--r-- | arch/ia64/kernel/acpi.c | 1 | ||||
-rw-r--r-- | arch/ia64/kernel/irq.c | 15 | ||||
-rw-r--r-- | arch/ia64/kernel/kprobes.c | 10 | ||||
-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/io_acpi_init.c | 103 | ||||
-rw-r--r-- | arch/ia64/sn/kernel/io_common.c | 5 | ||||
-rw-r--r-- | arch/ia64/sn/kernel/tiocx.c | 3 |
16 files changed, 112 insertions, 114 deletions
diff --git a/arch/ia64/include/asm/Kbuild b/arch/ia64/include/asm/Kbuild index ccbe8ae47a61..3b25bd9dca91 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/acpi-ext.h b/arch/ia64/include/asm/acpi-ext.h index 734d137dda6e..7f8362b379eb 100644 --- a/arch/ia64/include/asm/acpi-ext.h +++ b/arch/ia64/include/asm/acpi-ext.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #define _ASM_IA64_ACPI_EXT_H | 14 | #define _ASM_IA64_ACPI_EXT_H |
15 | 15 | ||
16 | #include <linux/types.h> | 16 | #include <linux/types.h> |
17 | #include <acpi/actypes.h> | ||
18 | 17 | ||
19 | extern acpi_status hp_acpi_csr_space (acpi_handle, u64 *base, u64 *length); | 18 | extern acpi_status hp_acpi_csr_space (acpi_handle, u64 *base, u64 *length); |
20 | 19 | ||
diff --git a/arch/ia64/include/asm/atomic.h b/arch/ia64/include/asm/atomic.h index 50c2b83fd5a0..d37292bd9875 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 69bd41d7c26e..0f84c5cb703d 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/irq.h b/arch/ia64/include/asm/irq.h index 36429a532630..5282546cdf82 100644 --- a/arch/ia64/include/asm/irq.h +++ b/arch/ia64/include/asm/irq.h | |||
@@ -27,7 +27,7 @@ irq_canonicalize (int irq) | |||
27 | } | 27 | } |
28 | 28 | ||
29 | extern void set_irq_affinity_info (unsigned int irq, int dest, int redir); | 29 | extern void set_irq_affinity_info (unsigned int irq, int dest, int redir); |
30 | bool is_affinity_mask_valid(cpumask_var_t cpumask); | 30 | bool is_affinity_mask_valid(const struct cpumask *cpumask); |
31 | 31 | ||
32 | #define is_affinity_mask_valid is_affinity_mask_valid | 32 | #define is_affinity_mask_valid is_affinity_mask_valid |
33 | 33 | ||
diff --git a/arch/ia64/include/asm/sn/acpi.h b/arch/ia64/include/asm/sn/acpi.h index 9ce2801cbd57..fd480db25565 100644 --- a/arch/ia64/include/asm/sn/acpi.h +++ b/arch/ia64/include/asm/sn/acpi.h | |||
@@ -9,8 +9,6 @@ | |||
9 | #ifndef _ASM_IA64_SN_ACPI_H | 9 | #ifndef _ASM_IA64_SN_ACPI_H |
10 | #define _ASM_IA64_SN_ACPI_H | 10 | #define _ASM_IA64_SN_ACPI_H |
11 | 11 | ||
12 | #include "acpi/acglobal.h" | ||
13 | |||
14 | extern int sn_acpi_rev; | 12 | extern int sn_acpi_rev; |
15 | #define SN_ACPI_BASE_SUPPORT() (sn_acpi_rev >= 0x20101) | 13 | #define SN_ACPI_BASE_SUPPORT() (sn_acpi_rev >= 0x20101) |
16 | 14 | ||
diff --git a/arch/ia64/include/asm/swab.h b/arch/ia64/include/asm/swab.h new file mode 100644 index 000000000000..6aa58b699eea --- /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/topology.h b/arch/ia64/include/asm/topology.h index 76a33a91ca69..32f3af1641c5 100644 --- a/arch/ia64/include/asm/topology.h +++ b/arch/ia64/include/asm/topology.h | |||
@@ -124,7 +124,7 @@ extern void arch_fix_phys_package_id(int num, u32 slot); | |||
124 | 124 | ||
125 | #define cpumask_of_pcibus(bus) (pcibus_to_node(bus) == -1 ? \ | 125 | #define cpumask_of_pcibus(bus) (pcibus_to_node(bus) == -1 ? \ |
126 | cpu_all_mask : \ | 126 | cpu_all_mask : \ |
127 | cpumask_from_node(pcibus_to_node(bus))) | 127 | cpumask_of_node(pcibus_to_node(bus))) |
128 | 128 | ||
129 | #include <asm-generic/topology.h> | 129 | #include <asm-generic/topology.h> |
130 | 130 | ||
diff --git a/arch/ia64/kernel/acpi.c b/arch/ia64/kernel/acpi.c index 0553648b7595..d541671caf4a 100644 --- a/arch/ia64/kernel/acpi.c +++ b/arch/ia64/kernel/acpi.c | |||
@@ -65,6 +65,7 @@ EXPORT_SYMBOL(pm_idle); | |||
65 | void (*pm_power_off) (void); | 65 | void (*pm_power_off) (void); |
66 | EXPORT_SYMBOL(pm_power_off); | 66 | EXPORT_SYMBOL(pm_power_off); |
67 | 67 | ||
68 | u32 acpi_rsdt_forced; | ||
68 | unsigned int acpi_cpei_override; | 69 | unsigned int acpi_cpei_override; |
69 | unsigned int acpi_cpei_phys_cpuid; | 70 | unsigned int acpi_cpei_phys_cpuid; |
70 | 71 | ||
diff --git a/arch/ia64/kernel/irq.c b/arch/ia64/kernel/irq.c index 95ff16cb05d8..a58f64ca9f0e 100644 --- a/arch/ia64/kernel/irq.c +++ b/arch/ia64/kernel/irq.c | |||
@@ -102,17 +102,14 @@ static char irq_redir [NR_IRQS]; // = { [0 ... NR_IRQS-1] = 1 }; | |||
102 | 102 | ||
103 | void set_irq_affinity_info (unsigned int irq, int hwid, int redir) | 103 | void set_irq_affinity_info (unsigned int irq, int hwid, int redir) |
104 | { | 104 | { |
105 | cpumask_t mask = CPU_MASK_NONE; | ||
106 | |||
107 | cpu_set(cpu_logical_id(hwid), mask); | ||
108 | |||
109 | if (irq < NR_IRQS) { | 105 | if (irq < NR_IRQS) { |
110 | irq_desc[irq].affinity = mask; | 106 | cpumask_copy(&irq_desc[irq].affinity, |
107 | cpumask_of(cpu_logical_id(hwid))); | ||
111 | irq_redir[irq] = (char) (redir & 0xff); | 108 | irq_redir[irq] = (char) (redir & 0xff); |
112 | } | 109 | } |
113 | } | 110 | } |
114 | 111 | ||
115 | bool is_affinity_mask_valid(cpumask_var_t cpumask) | 112 | bool is_affinity_mask_valid(const struct cpumask *cpumask) |
116 | { | 113 | { |
117 | if (ia64_platform_is("sn2")) { | 114 | if (ia64_platform_is("sn2")) { |
118 | /* Only allow one CPU to be specified in the smp_affinity mask */ | 115 | /* Only allow one CPU to be specified in the smp_affinity mask */ |
@@ -128,7 +125,7 @@ bool is_affinity_mask_valid(cpumask_var_t cpumask) | |||
128 | unsigned int vectors_in_migration[NR_IRQS]; | 125 | unsigned int vectors_in_migration[NR_IRQS]; |
129 | 126 | ||
130 | /* | 127 | /* |
131 | * Since cpu_online_map is already updated, we just need to check for | 128 | * Since cpu_online_mask is already updated, we just need to check for |
132 | * affinity that has zeros | 129 | * affinity that has zeros |
133 | */ | 130 | */ |
134 | static void migrate_irqs(void) | 131 | static void migrate_irqs(void) |
@@ -158,7 +155,7 @@ static void migrate_irqs(void) | |||
158 | */ | 155 | */ |
159 | vectors_in_migration[irq] = irq; | 156 | vectors_in_migration[irq] = irq; |
160 | 157 | ||
161 | new_cpu = any_online_cpu(cpu_online_map); | 158 | new_cpu = cpumask_any(cpu_online_mask); |
162 | 159 | ||
163 | /* | 160 | /* |
164 | * Al three are essential, currently WARN_ON.. maybe panic? | 161 | * Al three are essential, currently WARN_ON.. maybe panic? |
@@ -191,7 +188,7 @@ void fixup_irqs(void) | |||
191 | * Find a new timesync master | 188 | * Find a new timesync master |
192 | */ | 189 | */ |
193 | if (smp_processor_id() == time_keeper_id) { | 190 | if (smp_processor_id() == time_keeper_id) { |
194 | time_keeper_id = first_cpu(cpu_online_map); | 191 | time_keeper_id = cpumask_first(cpu_online_mask); |
195 | printk ("CPU %d is now promoted to time-keeper master\n", time_keeper_id); | 192 | printk ("CPU %d is now promoted to time-keeper master\n", time_keeper_id); |
196 | } | 193 | } |
197 | 194 | ||
diff --git a/arch/ia64/kernel/kprobes.c b/arch/ia64/kernel/kprobes.c index f07688da947c..f90be51b1123 100644 --- a/arch/ia64/kernel/kprobes.c +++ b/arch/ia64/kernel/kprobes.c | |||
@@ -434,7 +434,7 @@ int __kprobes trampoline_probe_handler(struct kprobe *p, struct pt_regs *regs) | |||
434 | /* | 434 | /* |
435 | * It is possible to have multiple instances associated with a given | 435 | * It is possible to have multiple instances associated with a given |
436 | * task either because an multiple functions in the call path | 436 | * task either because an multiple functions in the call path |
437 | * have a return probe installed on them, and/or more then one return | 437 | * have a return probe installed on them, and/or more than one return |
438 | * return probe was registered for a target function. | 438 | * return probe was registered for a target function. |
439 | * | 439 | * |
440 | * We can handle this because: | 440 | * We can handle this because: |
@@ -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 b30209ec8c6e..a647f116a155 100644 --- a/arch/ia64/kernel/pci-dma.c +++ b/arch/ia64/kernel/pci-dma.c | |||
@@ -36,7 +36,7 @@ int force_iommu __read_mostly; | |||
36 | be probably a smaller DMA mask, but this is bug-to-bug compatible | 36 | be probably a smaller DMA mask, but this is bug-to-bug compatible |
37 | to i386. */ | 37 | to i386. */ |
38 | struct device fallback_dev = { | 38 | struct device fallback_dev = { |
39 | .bus_id = "fallback device", | 39 | .init_name = "fallback device", |
40 | .coherent_dma_mask = DMA_32BIT_MASK, | 40 | .coherent_dma_mask = DMA_32BIT_MASK, |
41 | .dma_mask = &fallback_dev.coherent_dma_mask, | 41 | .dma_mask = &fallback_dev.coherent_dma_mask, |
42 | }; | 42 | }; |
diff --git a/arch/ia64/mm/init.c b/arch/ia64/mm/init.c index 054bcd9439aa..56e12903973c 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/io_acpi_init.c b/arch/ia64/sn/kernel/io_acpi_init.c index bc610a6c7851..c5a214026a77 100644 --- a/arch/ia64/sn/kernel/io_acpi_init.c +++ b/arch/ia64/sn/kernel/io_acpi_init.c | |||
@@ -13,7 +13,6 @@ | |||
13 | #include <asm/sn/sn_sal.h> | 13 | #include <asm/sn/sn_sal.h> |
14 | #include "xtalk/hubdev.h" | 14 | #include "xtalk/hubdev.h" |
15 | #include <linux/acpi.h> | 15 | #include <linux/acpi.h> |
16 | #include <acpi/acnamesp.h> | ||
17 | 16 | ||
18 | 17 | ||
19 | /* | 18 | /* |
@@ -64,6 +63,7 @@ static acpi_status __init | |||
64 | sn_acpi_hubdev_init(acpi_handle handle, u32 depth, void *context, void **ret) | 63 | sn_acpi_hubdev_init(acpi_handle handle, u32 depth, void *context, void **ret) |
65 | { | 64 | { |
66 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | 65 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; |
66 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
67 | u64 addr; | 67 | u64 addr; |
68 | struct hubdev_info *hubdev; | 68 | struct hubdev_info *hubdev; |
69 | struct hubdev_info *hubdev_ptr; | 69 | struct hubdev_info *hubdev_ptr; |
@@ -77,11 +77,12 @@ sn_acpi_hubdev_init(acpi_handle handle, u32 depth, void *context, void **ret) | |||
77 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, | 77 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, |
78 | &sn_uuid, &buffer); | 78 | &sn_uuid, &buffer); |
79 | if (ACPI_FAILURE(status)) { | 79 | if (ACPI_FAILURE(status)) { |
80 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
80 | printk(KERN_ERR | 81 | printk(KERN_ERR |
81 | "sn_acpi_hubdev_init: acpi_get_vendor_resource() " | 82 | "sn_acpi_hubdev_init: acpi_get_vendor_resource() " |
82 | "(0x%x) failed for: ", status); | 83 | "(0x%x) failed for: %s\n", status, |
83 | acpi_ns_print_node_pathname(handle, NULL); | 84 | (char *)name_buffer.pointer); |
84 | printk("\n"); | 85 | kfree(name_buffer.pointer); |
85 | return AE_OK; /* Continue walking namespace */ | 86 | return AE_OK; /* Continue walking namespace */ |
86 | } | 87 | } |
87 | 88 | ||
@@ -89,11 +90,12 @@ sn_acpi_hubdev_init(acpi_handle handle, u32 depth, void *context, void **ret) | |||
89 | vendor = &resource->data.vendor_typed; | 90 | vendor = &resource->data.vendor_typed; |
90 | if ((vendor->byte_length - sizeof(struct acpi_vendor_uuid)) != | 91 | if ((vendor->byte_length - sizeof(struct acpi_vendor_uuid)) != |
91 | sizeof(struct hubdev_info *)) { | 92 | sizeof(struct hubdev_info *)) { |
93 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
92 | printk(KERN_ERR | 94 | printk(KERN_ERR |
93 | "sn_acpi_hubdev_init: Invalid vendor data length: %d for: ", | 95 | "sn_acpi_hubdev_init: Invalid vendor data length: " |
94 | vendor->byte_length); | 96 | "%d for: %s\n", |
95 | acpi_ns_print_node_pathname(handle, NULL); | 97 | vendor->byte_length, (char *)name_buffer.pointer); |
96 | printk("\n"); | 98 | kfree(name_buffer.pointer); |
97 | goto exit; | 99 | goto exit; |
98 | } | 100 | } |
99 | 101 | ||
@@ -120,6 +122,7 @@ sn_get_bussoft_ptr(struct pci_bus *bus) | |||
120 | { | 122 | { |
121 | u64 addr; | 123 | u64 addr; |
122 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | 124 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; |
125 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
123 | acpi_handle handle; | 126 | acpi_handle handle; |
124 | struct pcibus_bussoft *prom_bussoft_ptr; | 127 | struct pcibus_bussoft *prom_bussoft_ptr; |
125 | struct acpi_resource *resource; | 128 | struct acpi_resource *resource; |
@@ -131,11 +134,11 @@ sn_get_bussoft_ptr(struct pci_bus *bus) | |||
131 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, | 134 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, |
132 | &sn_uuid, &buffer); | 135 | &sn_uuid, &buffer); |
133 | if (ACPI_FAILURE(status)) { | 136 | if (ACPI_FAILURE(status)) { |
137 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
134 | printk(KERN_ERR "%s: " | 138 | printk(KERN_ERR "%s: " |
135 | "acpi_get_vendor_resource() failed (0x%x) for: ", | 139 | "acpi_get_vendor_resource() failed (0x%x) for: %s\n", |
136 | __func__, status); | 140 | __func__, status, (char *)name_buffer.pointer); |
137 | acpi_ns_print_node_pathname(handle, NULL); | 141 | kfree(name_buffer.pointer); |
138 | printk("\n"); | ||
139 | return NULL; | 142 | return NULL; |
140 | } | 143 | } |
141 | resource = buffer.pointer; | 144 | resource = buffer.pointer; |
@@ -168,6 +171,7 @@ sn_extract_device_info(acpi_handle handle, struct pcidev_info **pcidev_info, | |||
168 | { | 171 | { |
169 | u64 addr; | 172 | u64 addr; |
170 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | 173 | struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL }; |
174 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
171 | struct sn_irq_info *irq_info, *irq_info_prom; | 175 | struct sn_irq_info *irq_info, *irq_info_prom; |
172 | struct pcidev_info *pcidev_ptr, *pcidev_prom_ptr; | 176 | struct pcidev_info *pcidev_ptr, *pcidev_prom_ptr; |
173 | struct acpi_resource *resource; | 177 | struct acpi_resource *resource; |
@@ -182,11 +186,11 @@ sn_extract_device_info(acpi_handle handle, struct pcidev_info **pcidev_info, | |||
182 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, | 186 | status = acpi_get_vendor_resource(handle, METHOD_NAME__CRS, |
183 | &sn_uuid, &buffer); | 187 | &sn_uuid, &buffer); |
184 | if (ACPI_FAILURE(status)) { | 188 | if (ACPI_FAILURE(status)) { |
189 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
185 | printk(KERN_ERR | 190 | printk(KERN_ERR |
186 | "%s: acpi_get_vendor_resource() failed (0x%x) for: ", | 191 | "%s: acpi_get_vendor_resource() failed (0x%x) for: %s\n", |
187 | __func__, status); | 192 | __func__, status, (char *)name_buffer.pointer); |
188 | acpi_ns_print_node_pathname(handle, NULL); | 193 | kfree(name_buffer.pointer); |
189 | printk("\n"); | ||
190 | return 1; | 194 | return 1; |
191 | } | 195 | } |
192 | 196 | ||
@@ -194,11 +198,12 @@ sn_extract_device_info(acpi_handle handle, struct pcidev_info **pcidev_info, | |||
194 | vendor = &resource->data.vendor_typed; | 198 | vendor = &resource->data.vendor_typed; |
195 | if ((vendor->byte_length - sizeof(struct acpi_vendor_uuid)) != | 199 | if ((vendor->byte_length - sizeof(struct acpi_vendor_uuid)) != |
196 | sizeof(struct pci_devdev_info *)) { | 200 | sizeof(struct pci_devdev_info *)) { |
201 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
197 | printk(KERN_ERR | 202 | printk(KERN_ERR |
198 | "%s: Invalid vendor data length: %d for: ", | 203 | "%s: Invalid vendor data length: %d for: %s\n", |
199 | __func__, vendor->byte_length); | 204 | __func__, vendor->byte_length, |
200 | acpi_ns_print_node_pathname(handle, NULL); | 205 | (char *)name_buffer.pointer); |
201 | printk("\n"); | 206 | kfree(name_buffer.pointer); |
202 | ret = 1; | 207 | ret = 1; |
203 | goto exit; | 208 | goto exit; |
204 | } | 209 | } |
@@ -239,6 +244,9 @@ get_host_devfn(acpi_handle device_handle, acpi_handle rootbus_handle) | |||
239 | acpi_handle parent; | 244 | acpi_handle parent; |
240 | int slot; | 245 | int slot; |
241 | acpi_status status; | 246 | acpi_status status; |
247 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
248 | |||
249 | acpi_get_name(device_handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
242 | 250 | ||
243 | /* | 251 | /* |
244 | * Do an upward search to find the root bus device, and | 252 | * Do an upward search to find the root bus device, and |
@@ -249,9 +257,8 @@ get_host_devfn(acpi_handle device_handle, acpi_handle rootbus_handle) | |||
249 | status = acpi_get_parent(child, &parent); | 257 | status = acpi_get_parent(child, &parent); |
250 | if (ACPI_FAILURE(status)) { | 258 | if (ACPI_FAILURE(status)) { |
251 | printk(KERN_ERR "%s: acpi_get_parent() failed " | 259 | printk(KERN_ERR "%s: acpi_get_parent() failed " |
252 | "(0x%x) for: ", __func__, status); | 260 | "(0x%x) for: %s\n", __func__, status, |
253 | acpi_ns_print_node_pathname(child, NULL); | 261 | (char *)name_buffer.pointer); |
254 | printk("\n"); | ||
255 | panic("%s: Unable to find host devfn\n", __func__); | 262 | panic("%s: Unable to find host devfn\n", __func__); |
256 | } | 263 | } |
257 | if (parent == rootbus_handle) | 264 | if (parent == rootbus_handle) |
@@ -259,22 +266,20 @@ get_host_devfn(acpi_handle device_handle, acpi_handle rootbus_handle) | |||
259 | child = parent; | 266 | child = parent; |
260 | } | 267 | } |
261 | if (!child) { | 268 | if (!child) { |
262 | printk(KERN_ERR "%s: Unable to find root bus for: ", | 269 | printk(KERN_ERR "%s: Unable to find root bus for: %s\n", |
263 | __func__); | 270 | __func__, (char *)name_buffer.pointer); |
264 | acpi_ns_print_node_pathname(device_handle, NULL); | ||
265 | printk("\n"); | ||
266 | BUG(); | 271 | BUG(); |
267 | } | 272 | } |
268 | 273 | ||
269 | status = acpi_evaluate_integer(child, METHOD_NAME__ADR, NULL, &adr); | 274 | status = acpi_evaluate_integer(child, METHOD_NAME__ADR, NULL, &adr); |
270 | if (ACPI_FAILURE(status)) { | 275 | if (ACPI_FAILURE(status)) { |
271 | printk(KERN_ERR "%s: Unable to get _ADR (0x%x) for: ", | 276 | printk(KERN_ERR "%s: Unable to get _ADR (0x%x) for: %s\n", |
272 | __func__, status); | 277 | __func__, status, (char *)name_buffer.pointer); |
273 | acpi_ns_print_node_pathname(child, NULL); | ||
274 | printk("\n"); | ||
275 | panic("%s: Unable to find host devfn\n", __func__); | 278 | panic("%s: Unable to find host devfn\n", __func__); |
276 | } | 279 | } |
277 | 280 | ||
281 | kfree(name_buffer.pointer); | ||
282 | |||
278 | slot = (adr >> 16) & 0xffff; | 283 | slot = (adr >> 16) & 0xffff; |
279 | function = adr & 0xffff; | 284 | function = adr & 0xffff; |
280 | devfn = PCI_DEVFN(slot, function); | 285 | devfn = PCI_DEVFN(slot, function); |
@@ -300,27 +305,28 @@ find_matching_device(acpi_handle handle, u32 lvl, void *context, void **rv) | |||
300 | int function; | 305 | int function; |
301 | int slot; | 306 | int slot; |
302 | struct sn_pcidev_match *info = context; | 307 | struct sn_pcidev_match *info = context; |
308 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
303 | 309 | ||
304 | status = acpi_evaluate_integer(handle, METHOD_NAME__ADR, NULL, | 310 | status = acpi_evaluate_integer(handle, METHOD_NAME__ADR, NULL, |
305 | &adr); | 311 | &adr); |
306 | if (ACPI_SUCCESS(status)) { | 312 | if (ACPI_SUCCESS(status)) { |
307 | status = acpi_get_parent(handle, &parent); | 313 | status = acpi_get_parent(handle, &parent); |
308 | if (ACPI_FAILURE(status)) { | 314 | if (ACPI_FAILURE(status)) { |
315 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
309 | printk(KERN_ERR | 316 | printk(KERN_ERR |
310 | "%s: acpi_get_parent() failed (0x%x) for: ", | 317 | "%s: acpi_get_parent() failed (0x%x) for: %s\n", |
311 | __func__, status); | 318 | __func__, status, (char *)name_buffer.pointer); |
312 | acpi_ns_print_node_pathname(handle, NULL); | 319 | kfree(name_buffer.pointer); |
313 | printk("\n"); | ||
314 | return AE_OK; | 320 | return AE_OK; |
315 | } | 321 | } |
316 | status = acpi_evaluate_integer(parent, METHOD_NAME__BBN, | 322 | status = acpi_evaluate_integer(parent, METHOD_NAME__BBN, |
317 | NULL, &bbn); | 323 | NULL, &bbn); |
318 | if (ACPI_FAILURE(status)) { | 324 | if (ACPI_FAILURE(status)) { |
325 | acpi_get_name(handle, ACPI_FULL_PATHNAME, &name_buffer); | ||
319 | printk(KERN_ERR | 326 | printk(KERN_ERR |
320 | "%s: Failed to find _BBN in parent of: ", | 327 | "%s: Failed to find _BBN in parent of: %s\n", |
321 | __func__); | 328 | __func__, (char *)name_buffer.pointer); |
322 | acpi_ns_print_node_pathname(handle, NULL); | 329 | kfree(name_buffer.pointer); |
323 | printk("\n"); | ||
324 | return AE_OK; | 330 | return AE_OK; |
325 | } | 331 | } |
326 | 332 | ||
@@ -350,24 +356,27 @@ sn_acpi_get_pcidev_info(struct pci_dev *dev, struct pcidev_info **pcidev_info, | |||
350 | acpi_handle rootbus_handle; | 356 | acpi_handle rootbus_handle; |
351 | unsigned long long segment; | 357 | unsigned long long segment; |
352 | acpi_status status; | 358 | acpi_status status; |
359 | struct acpi_buffer name_buffer = { ACPI_ALLOCATE_BUFFER, NULL }; | ||
353 | 360 | ||
354 | rootbus_handle = PCI_CONTROLLER(dev)->acpi_handle; | 361 | rootbus_handle = PCI_CONTROLLER(dev)->acpi_handle; |
355 | status = acpi_evaluate_integer(rootbus_handle, METHOD_NAME__SEG, NULL, | 362 | status = acpi_evaluate_integer(rootbus_handle, METHOD_NAME__SEG, NULL, |
356 | &segment); | 363 | &segment); |
357 | if (ACPI_SUCCESS(status)) { | 364 | if (ACPI_SUCCESS(status)) { |
358 | if (segment != pci_domain_nr(dev)) { | 365 | if (segment != pci_domain_nr(dev)) { |
366 | acpi_get_name(rootbus_handle, ACPI_FULL_PATHNAME, | ||
367 | &name_buffer); | ||
359 | printk(KERN_ERR | 368 | printk(KERN_ERR |
360 | "%s: Segment number mismatch, 0x%llx vs 0x%x for: ", | 369 | "%s: Segment number mismatch, 0x%llx vs 0x%x for: %s\n", |
361 | __func__, segment, pci_domain_nr(dev)); | 370 | __func__, segment, pci_domain_nr(dev), |
362 | acpi_ns_print_node_pathname(rootbus_handle, NULL); | 371 | (char *)name_buffer.pointer); |
363 | printk("\n"); | 372 | kfree(name_buffer.pointer); |
364 | return 1; | 373 | return 1; |
365 | } | 374 | } |
366 | } else { | 375 | } else { |
367 | printk(KERN_ERR "%s: Unable to get __SEG from: ", | 376 | acpi_get_name(rootbus_handle, ACPI_FULL_PATHNAME, &name_buffer); |
368 | __func__); | 377 | printk(KERN_ERR "%s: Unable to get __SEG from: %s\n", |
369 | acpi_ns_print_node_pathname(rootbus_handle, NULL); | 378 | __func__, (char *)name_buffer.pointer); |
370 | printk("\n"); | 379 | kfree(name_buffer.pointer); |
371 | return 1; | 380 | return 1; |
372 | } | 381 | } |
373 | 382 | ||
diff --git a/arch/ia64/sn/kernel/io_common.c b/arch/ia64/sn/kernel/io_common.c index 8a924a5661dd..0d4ffa4da1da 100644 --- a/arch/ia64/sn/kernel/io_common.c +++ b/arch/ia64/sn/kernel/io_common.c | |||
@@ -26,7 +26,6 @@ | |||
26 | #include <linux/acpi.h> | 26 | #include <linux/acpi.h> |
27 | #include <asm/sn/sn2/sn_hwperf.h> | 27 | #include <asm/sn/sn2/sn_hwperf.h> |
28 | #include <asm/sn/acpi.h> | 28 | #include <asm/sn/acpi.h> |
29 | #include "acpi/acglobal.h" | ||
30 | 29 | ||
31 | extern void sn_init_cpei_timer(void); | 30 | extern void sn_init_cpei_timer(void); |
32 | extern void register_sn_procfs(void); | 31 | extern void register_sn_procfs(void); |
@@ -473,7 +472,7 @@ sn_io_early_init(void) | |||
473 | { | 472 | { |
474 | struct acpi_table_header *header = NULL; | 473 | struct acpi_table_header *header = NULL; |
475 | 474 | ||
476 | acpi_get_table_by_index(ACPI_TABLE_INDEX_DSDT, &header); | 475 | acpi_get_table(ACPI_SIG_DSDT, 1, &header); |
477 | BUG_ON(header == NULL); | 476 | BUG_ON(header == NULL); |
478 | sn_acpi_rev = header->oem_revision; | 477 | sn_acpi_rev = header->oem_revision; |
479 | } | 478 | } |
@@ -505,7 +504,7 @@ sn_io_early_init(void) | |||
505 | 504 | ||
506 | { | 505 | { |
507 | struct acpi_table_header *header; | 506 | struct acpi_table_header *header; |
508 | (void)acpi_get_table_by_index(ACPI_TABLE_INDEX_DSDT, &header); | 507 | (void)acpi_get_table(ACPI_SIG_DSDT, 1, &header); |
509 | printk(KERN_INFO "ACPI DSDT OEM Rev 0x%x\n", | 508 | printk(KERN_INFO "ACPI DSDT OEM Rev 0x%x\n", |
510 | header->oem_revision); | 509 | header->oem_revision); |
511 | } | 510 | } |
diff --git a/arch/ia64/sn/kernel/tiocx.c b/arch/ia64/sn/kernel/tiocx.c index a88eba3314d7..3f864238566d 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 | ||