aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorYang Hongyang <yanghy@cn.fujitsu.com>2009-04-06 22:01:15 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-04-07 11:31:11 -0400
commit284901a90a9e0b812ca3f5f852cbbfb60d10249d (patch)
tree06c1b5a0f83c90cfb662f756e7781977ce739ce8 /arch
parent6afd142fd0dfba497246d0fab236c20a7b4bf778 (diff)
dma-mapping: replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32)
Replace all DMA_32BIT_MASK macro with DMA_BIT_MASK(32) Signed-off-by: Yang Hongyang<yanghy@cn.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/mach-davinci/board-evm.c4
-rw-r--r--arch/arm/mach-davinci/usb.c4
-rw-r--r--arch/arm/mach-kirkwood/common.c2
-rw-r--r--arch/arm/mach-orion5x/common.c2
-rw-r--r--arch/arm/plat-iop/adma.c2
-rw-r--r--arch/avr32/boards/hammerhead/flash.c4
-rw-r--r--arch/avr32/mach-at32ap/at32ap700x.c8
-rw-r--r--arch/ia64/kernel/pci-dma.c2
-rw-r--r--arch/mips/alchemy/common/platform.c30
-rw-r--r--arch/mips/alchemy/devboards/pb1200/platform.c4
-rw-r--r--arch/mips/nxp/pnx833x/common/platform.c12
-rw-r--r--arch/mips/nxp/pnx8550/common/platform.c8
-rw-r--r--arch/mips/pmc-sierra/msp71xx/msp_usb.c8
-rw-r--r--arch/powerpc/kernel/dma.c2
-rw-r--r--arch/powerpc/kernel/of_platform.c2
-rw-r--r--arch/powerpc/platforms/iseries/iommu.c4
-rw-r--r--arch/powerpc/platforms/ps3/system-bus.c2
-rw-r--r--arch/x86/include/asm/dma-mapping.h4
-rw-r--r--arch/x86/kernel/pci-dma.c4
-rw-r--r--arch/x86/kernel/pci-nommu.c2
20 files changed, 55 insertions, 55 deletions
diff --git a/arch/arm/mach-davinci/board-evm.c b/arch/arm/mach-davinci/board-evm.c
index 38b6a9ce2a93..0b97a528902b 100644
--- a/arch/arm/mach-davinci/board-evm.c
+++ b/arch/arm/mach-davinci/board-evm.c
@@ -118,7 +118,7 @@ static struct resource ide_resources[] = {
118 }, 118 },
119}; 119};
120 120
121static u64 ide_dma_mask = DMA_32BIT_MASK; 121static u64 ide_dma_mask = DMA_BIT_MASK(32);
122 122
123static struct platform_device ide_dev = { 123static struct platform_device ide_dev = {
124 .name = "palm_bk3710", 124 .name = "palm_bk3710",
@@ -127,7 +127,7 @@ static struct platform_device ide_dev = {
127 .num_resources = ARRAY_SIZE(ide_resources), 127 .num_resources = ARRAY_SIZE(ide_resources),
128 .dev = { 128 .dev = {
129 .dma_mask = &ide_dma_mask, 129 .dma_mask = &ide_dma_mask,
130 .coherent_dma_mask = DMA_32BIT_MASK, 130 .coherent_dma_mask = DMA_BIT_MASK(32),
131 }, 131 },
132}; 132};
133 133
diff --git a/arch/arm/mach-davinci/usb.c b/arch/arm/mach-davinci/usb.c
index 69680784448a..2429b79f6da2 100644
--- a/arch/arm/mach-davinci/usb.c
+++ b/arch/arm/mach-davinci/usb.c
@@ -64,7 +64,7 @@ static struct resource usb_resources[] = {
64 }, 64 },
65}; 65};
66 66
67static u64 usb_dmamask = DMA_32BIT_MASK; 67static u64 usb_dmamask = DMA_BIT_MASK(32);
68 68
69static struct platform_device usb_dev = { 69static struct platform_device usb_dev = {
70 .name = "musb_hdrc", 70 .name = "musb_hdrc",
@@ -72,7 +72,7 @@ static struct platform_device usb_dev = {
72 .dev = { 72 .dev = {
73 .platform_data = &usb_data, 73 .platform_data = &usb_data,
74 .dma_mask = &usb_dmamask, 74 .dma_mask = &usb_dmamask,
75 .coherent_dma_mask = DMA_32BIT_MASK, 75 .coherent_dma_mask = DMA_BIT_MASK(32),
76 }, 76 },
77 .resource = usb_resources, 77 .resource = usb_resources,
78 .num_resources = ARRAY_SIZE(usb_resources), 78 .num_resources = ARRAY_SIZE(usb_resources),
diff --git a/arch/arm/mach-kirkwood/common.c b/arch/arm/mach-kirkwood/common.c
index c691848714d9..16dc9ea08393 100644
--- a/arch/arm/mach-kirkwood/common.c
+++ b/arch/arm/mach-kirkwood/common.c
@@ -508,7 +508,7 @@ static struct mv_xor_platform_shared_data kirkwood_xor_shared_data = {
508 .dram = &kirkwood_mbus_dram_info, 508 .dram = &kirkwood_mbus_dram_info,
509}; 509};
510 510
511static u64 kirkwood_xor_dmamask = DMA_32BIT_MASK; 511static u64 kirkwood_xor_dmamask = DMA_BIT_MASK(32);
512 512
513 513
514/***************************************************************************** 514/*****************************************************************************
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c
index e8d42e8cb465..6af99ddabdfb 100644
--- a/arch/arm/mach-orion5x/common.c
+++ b/arch/arm/mach-orion5x/common.c
@@ -463,7 +463,7 @@ static struct platform_device orion5x_xor_shared = {
463 .resource = orion5x_xor_shared_resources, 463 .resource = orion5x_xor_shared_resources,
464}; 464};
465 465
466static u64 orion5x_xor_dmamask = DMA_32BIT_MASK; 466static u64 orion5x_xor_dmamask = DMA_BIT_MASK(32);
467 467
468static struct resource orion5x_xor0_resources[] = { 468static struct resource orion5x_xor0_resources[] = {
469 [0] = { 469 [0] = {
diff --git a/arch/arm/plat-iop/adma.c b/arch/arm/plat-iop/adma.c
index a2a94f6d2e7c..3c127aabe214 100644
--- a/arch/arm/plat-iop/adma.c
+++ b/arch/arm/plat-iop/adma.c
@@ -119,7 +119,7 @@ static struct resource iop3xx_aau_resources[] = {
119 } 119 }
120}; 120};
121 121
122static u64 iop3xx_adma_dmamask = DMA_32BIT_MASK; 122static u64 iop3xx_adma_dmamask = DMA_BIT_MASK(32);
123 123
124static struct iop_adma_platform_data iop3xx_dma_0_data = { 124static struct iop_adma_platform_data iop3xx_dma_0_data = {
125 .hw_id = DMA0_ID, 125 .hw_id = DMA0_ID,
diff --git a/arch/avr32/boards/hammerhead/flash.c b/arch/avr32/boards/hammerhead/flash.c
index 559bbcb03f9b..776c3cb9b6e4 100644
--- a/arch/avr32/boards/hammerhead/flash.c
+++ b/arch/avr32/boards/hammerhead/flash.c
@@ -280,13 +280,13 @@ static struct resource hh_fpga0_resource[] = {
280 }, 280 },
281}; 281};
282 282
283static u64 hh_fpga0_dma_mask = DMA_32BIT_MASK; 283static u64 hh_fpga0_dma_mask = DMA_BIT_MASK(32);
284static struct platform_device hh_fpga0_device = { 284static struct platform_device hh_fpga0_device = {
285 .name = "hh_fpga", 285 .name = "hh_fpga",
286 .id = 0, 286 .id = 0,
287 .dev = { 287 .dev = {
288 .dma_mask = &hh_fpga0_dma_mask, 288 .dma_mask = &hh_fpga0_dma_mask,
289 .coherent_dma_mask = DMA_32BIT_MASK, 289 .coherent_dma_mask = DMA_BIT_MASK(32),
290 }, 290 },
291 .resource = hh_fpga0_resource, 291 .resource = hh_fpga0_resource,
292 .num_resources = ARRAY_SIZE(hh_fpga0_resource), 292 .num_resources = ARRAY_SIZE(hh_fpga0_resource),
diff --git a/arch/avr32/mach-at32ap/at32ap700x.c b/arch/avr32/mach-at32ap/at32ap700x.c
index 7cc653798327..eb9d4dc2e86d 100644
--- a/arch/avr32/mach-at32ap/at32ap700x.c
+++ b/arch/avr32/mach-at32ap/at32ap700x.c
@@ -60,26 +60,26 @@
60 * don't ... tc, smc, pio, rtc, watchdog, pwm, ps2, and more. 60 * don't ... tc, smc, pio, rtc, watchdog, pwm, ps2, and more.
61 */ 61 */
62#define DEFINE_DEV(_name, _id) \ 62#define DEFINE_DEV(_name, _id) \
63static u64 _name##_id##_dma_mask = DMA_32BIT_MASK; \ 63static u64 _name##_id##_dma_mask = DMA_BIT_MASK(32); \
64static struct platform_device _name##_id##_device = { \ 64static struct platform_device _name##_id##_device = { \
65 .name = #_name, \ 65 .name = #_name, \
66 .id = _id, \ 66 .id = _id, \
67 .dev = { \ 67 .dev = { \
68 .dma_mask = &_name##_id##_dma_mask, \ 68 .dma_mask = &_name##_id##_dma_mask, \
69 .coherent_dma_mask = DMA_32BIT_MASK, \ 69 .coherent_dma_mask = DMA_BIT_MASK(32), \
70 }, \ 70 }, \
71 .resource = _name##_id##_resource, \ 71 .resource = _name##_id##_resource, \
72 .num_resources = ARRAY_SIZE(_name##_id##_resource), \ 72 .num_resources = ARRAY_SIZE(_name##_id##_resource), \
73} 73}
74#define DEFINE_DEV_DATA(_name, _id) \ 74#define DEFINE_DEV_DATA(_name, _id) \
75static u64 _name##_id##_dma_mask = DMA_32BIT_MASK; \ 75static u64 _name##_id##_dma_mask = DMA_BIT_MASK(32); \
76static struct platform_device _name##_id##_device = { \ 76static struct platform_device _name##_id##_device = { \
77 .name = #_name, \ 77 .name = #_name, \
78 .id = _id, \ 78 .id = _id, \
79 .dev = { \ 79 .dev = { \
80 .dma_mask = &_name##_id##_dma_mask, \ 80 .dma_mask = &_name##_id##_dma_mask, \
81 .platform_data = &_name##_id##_data, \ 81 .platform_data = &_name##_id##_data, \
82 .coherent_dma_mask = DMA_32BIT_MASK, \ 82 .coherent_dma_mask = DMA_BIT_MASK(32), \
83 }, \ 83 }, \
84 .resource = _name##_id##_resource, \ 84 .resource = _name##_id##_resource, \
85 .num_resources = ARRAY_SIZE(_name##_id##_resource), \ 85 .num_resources = ARRAY_SIZE(_name##_id##_resource), \
diff --git a/arch/ia64/kernel/pci-dma.c b/arch/ia64/kernel/pci-dma.c
index 8f34f3ddb83b..f82b0ee6bb1f 100644
--- a/arch/ia64/kernel/pci-dma.c
+++ b/arch/ia64/kernel/pci-dma.c
@@ -37,7 +37,7 @@ int force_iommu __read_mostly;
37 to i386. */ 37 to i386. */
38struct device fallback_dev = { 38struct device fallback_dev = {
39 .init_name = "fallback device", 39 .init_name = "fallback device",
40 .coherent_dma_mask = DMA_32BIT_MASK, 40 .coherent_dma_mask = DMA_BIT_MASK(32),
41 .dma_mask = &fallback_dev.coherent_dma_mask, 41 .dma_mask = &fallback_dev.coherent_dma_mask,
42}; 42};
43 43
diff --git a/arch/mips/alchemy/common/platform.c b/arch/mips/alchemy/common/platform.c
index 5c76c6448e04..117f99f70649 100644
--- a/arch/mips/alchemy/common/platform.c
+++ b/arch/mips/alchemy/common/platform.c
@@ -80,14 +80,14 @@ static struct resource au1xxx_usb_ohci_resources[] = {
80}; 80};
81 81
82/* The dmamask must be set for OHCI to work */ 82/* The dmamask must be set for OHCI to work */
83static u64 ohci_dmamask = DMA_32BIT_MASK; 83static u64 ohci_dmamask = DMA_BIT_MASK(32);
84 84
85static struct platform_device au1xxx_usb_ohci_device = { 85static struct platform_device au1xxx_usb_ohci_device = {
86 .name = "au1xxx-ohci", 86 .name = "au1xxx-ohci",
87 .id = 0, 87 .id = 0,
88 .dev = { 88 .dev = {
89 .dma_mask = &ohci_dmamask, 89 .dma_mask = &ohci_dmamask,
90 .coherent_dma_mask = DMA_32BIT_MASK, 90 .coherent_dma_mask = DMA_BIT_MASK(32),
91 }, 91 },
92 .num_resources = ARRAY_SIZE(au1xxx_usb_ohci_resources), 92 .num_resources = ARRAY_SIZE(au1xxx_usb_ohci_resources),
93 .resource = au1xxx_usb_ohci_resources, 93 .resource = au1xxx_usb_ohci_resources,
@@ -109,14 +109,14 @@ static struct resource au1100_lcd_resources[] = {
109 } 109 }
110}; 110};
111 111
112static u64 au1100_lcd_dmamask = DMA_32BIT_MASK; 112static u64 au1100_lcd_dmamask = DMA_BIT_MASK(32);
113 113
114static struct platform_device au1100_lcd_device = { 114static struct platform_device au1100_lcd_device = {
115 .name = "au1100-lcd", 115 .name = "au1100-lcd",
116 .id = 0, 116 .id = 0,
117 .dev = { 117 .dev = {
118 .dma_mask = &au1100_lcd_dmamask, 118 .dma_mask = &au1100_lcd_dmamask,
119 .coherent_dma_mask = DMA_32BIT_MASK, 119 .coherent_dma_mask = DMA_BIT_MASK(32),
120 }, 120 },
121 .num_resources = ARRAY_SIZE(au1100_lcd_resources), 121 .num_resources = ARRAY_SIZE(au1100_lcd_resources),
122 .resource = au1100_lcd_resources, 122 .resource = au1100_lcd_resources,
@@ -138,14 +138,14 @@ static struct resource au1xxx_usb_ehci_resources[] = {
138 }, 138 },
139}; 139};
140 140
141static u64 ehci_dmamask = DMA_32BIT_MASK; 141static u64 ehci_dmamask = DMA_BIT_MASK(32);
142 142
143static struct platform_device au1xxx_usb_ehci_device = { 143static struct platform_device au1xxx_usb_ehci_device = {
144 .name = "au1xxx-ehci", 144 .name = "au1xxx-ehci",
145 .id = 0, 145 .id = 0,
146 .dev = { 146 .dev = {
147 .dma_mask = &ehci_dmamask, 147 .dma_mask = &ehci_dmamask,
148 .coherent_dma_mask = DMA_32BIT_MASK, 148 .coherent_dma_mask = DMA_BIT_MASK(32),
149 }, 149 },
150 .num_resources = ARRAY_SIZE(au1xxx_usb_ehci_resources), 150 .num_resources = ARRAY_SIZE(au1xxx_usb_ehci_resources),
151 .resource = au1xxx_usb_ehci_resources, 151 .resource = au1xxx_usb_ehci_resources,
@@ -165,14 +165,14 @@ static struct resource au1xxx_usb_gdt_resources[] = {
165 }, 165 },
166}; 166};
167 167
168static u64 udc_dmamask = DMA_32BIT_MASK; 168static u64 udc_dmamask = DMA_BIT_MASK(32);
169 169
170static struct platform_device au1xxx_usb_gdt_device = { 170static struct platform_device au1xxx_usb_gdt_device = {
171 .name = "au1xxx-udc", 171 .name = "au1xxx-udc",
172 .id = 0, 172 .id = 0,
173 .dev = { 173 .dev = {
174 .dma_mask = &udc_dmamask, 174 .dma_mask = &udc_dmamask,
175 .coherent_dma_mask = DMA_32BIT_MASK, 175 .coherent_dma_mask = DMA_BIT_MASK(32),
176 }, 176 },
177 .num_resources = ARRAY_SIZE(au1xxx_usb_gdt_resources), 177 .num_resources = ARRAY_SIZE(au1xxx_usb_gdt_resources),
178 .resource = au1xxx_usb_gdt_resources, 178 .resource = au1xxx_usb_gdt_resources,
@@ -192,14 +192,14 @@ static struct resource au1xxx_usb_otg_resources[] = {
192 }, 192 },
193}; 193};
194 194
195static u64 uoc_dmamask = DMA_32BIT_MASK; 195static u64 uoc_dmamask = DMA_BIT_MASK(32);
196 196
197static struct platform_device au1xxx_usb_otg_device = { 197static struct platform_device au1xxx_usb_otg_device = {
198 .name = "au1xxx-uoc", 198 .name = "au1xxx-uoc",
199 .id = 0, 199 .id = 0,
200 .dev = { 200 .dev = {
201 .dma_mask = &uoc_dmamask, 201 .dma_mask = &uoc_dmamask,
202 .coherent_dma_mask = DMA_32BIT_MASK, 202 .coherent_dma_mask = DMA_BIT_MASK(32),
203 }, 203 },
204 .num_resources = ARRAY_SIZE(au1xxx_usb_otg_resources), 204 .num_resources = ARRAY_SIZE(au1xxx_usb_otg_resources),
205 .resource = au1xxx_usb_otg_resources, 205 .resource = au1xxx_usb_otg_resources,
@@ -218,20 +218,20 @@ static struct resource au1200_lcd_resources[] = {
218 } 218 }
219}; 219};
220 220
221static u64 au1200_lcd_dmamask = DMA_32BIT_MASK; 221static u64 au1200_lcd_dmamask = DMA_BIT_MASK(32);
222 222
223static struct platform_device au1200_lcd_device = { 223static struct platform_device au1200_lcd_device = {
224 .name = "au1200-lcd", 224 .name = "au1200-lcd",
225 .id = 0, 225 .id = 0,
226 .dev = { 226 .dev = {
227 .dma_mask = &au1200_lcd_dmamask, 227 .dma_mask = &au1200_lcd_dmamask,
228 .coherent_dma_mask = DMA_32BIT_MASK, 228 .coherent_dma_mask = DMA_BIT_MASK(32),
229 }, 229 },
230 .num_resources = ARRAY_SIZE(au1200_lcd_resources), 230 .num_resources = ARRAY_SIZE(au1200_lcd_resources),
231 .resource = au1200_lcd_resources, 231 .resource = au1200_lcd_resources,
232}; 232};
233 233
234static u64 au1xxx_mmc_dmamask = DMA_32BIT_MASK; 234static u64 au1xxx_mmc_dmamask = DMA_BIT_MASK(32);
235 235
236extern struct au1xmmc_platform_data au1xmmc_platdata[2]; 236extern struct au1xmmc_platform_data au1xmmc_platdata[2];
237 237
@@ -263,7 +263,7 @@ static struct platform_device au1200_mmc0_device = {
263 .id = 0, 263 .id = 0,
264 .dev = { 264 .dev = {
265 .dma_mask = &au1xxx_mmc_dmamask, 265 .dma_mask = &au1xxx_mmc_dmamask,
266 .coherent_dma_mask = DMA_32BIT_MASK, 266 .coherent_dma_mask = DMA_BIT_MASK(32),
267 .platform_data = &au1xmmc_platdata[0], 267 .platform_data = &au1xmmc_platdata[0],
268 }, 268 },
269 .num_resources = ARRAY_SIZE(au1200_mmc0_resources), 269 .num_resources = ARRAY_SIZE(au1200_mmc0_resources),
@@ -299,7 +299,7 @@ static struct platform_device au1200_mmc1_device = {
299 .id = 1, 299 .id = 1,
300 .dev = { 300 .dev = {
301 .dma_mask = &au1xxx_mmc_dmamask, 301 .dma_mask = &au1xxx_mmc_dmamask,
302 .coherent_dma_mask = DMA_32BIT_MASK, 302 .coherent_dma_mask = DMA_BIT_MASK(32),
303 .platform_data = &au1xmmc_platdata[1], 303 .platform_data = &au1xmmc_platdata[1],
304 }, 304 },
305 .num_resources = ARRAY_SIZE(au1200_mmc1_resources), 305 .num_resources = ARRAY_SIZE(au1200_mmc1_resources),
diff --git a/arch/mips/alchemy/devboards/pb1200/platform.c b/arch/mips/alchemy/devboards/pb1200/platform.c
index 0d68e1985ffd..b93dff4a6789 100644
--- a/arch/mips/alchemy/devboards/pb1200/platform.c
+++ b/arch/mips/alchemy/devboards/pb1200/platform.c
@@ -119,14 +119,14 @@ static struct resource ide_resources[] = {
119 } 119 }
120}; 120};
121 121
122static u64 ide_dmamask = DMA_32BIT_MASK; 122static u64 ide_dmamask = DMA_BIT_MASK(32);
123 123
124static struct platform_device ide_device = { 124static struct platform_device ide_device = {
125 .name = "au1200-ide", 125 .name = "au1200-ide",
126 .id = 0, 126 .id = 0,
127 .dev = { 127 .dev = {
128 .dma_mask = &ide_dmamask, 128 .dma_mask = &ide_dmamask,
129 .coherent_dma_mask = DMA_32BIT_MASK, 129 .coherent_dma_mask = DMA_BIT_MASK(32),
130 }, 130 },
131 .num_resources = ARRAY_SIZE(ide_resources), 131 .num_resources = ARRAY_SIZE(ide_resources),
132 .resource = ide_resources 132 .resource = ide_resources
diff --git a/arch/mips/nxp/pnx833x/common/platform.c b/arch/mips/nxp/pnx833x/common/platform.c
index b1ccbcc18f78..01f8345a2069 100644
--- a/arch/mips/nxp/pnx833x/common/platform.c
+++ b/arch/mips/nxp/pnx833x/common/platform.c
@@ -42,7 +42,7 @@
42#include <irq-mapping.h> 42#include <irq-mapping.h>
43#include <pnx833x.h> 43#include <pnx833x.h>
44 44
45static u64 uart_dmamask = DMA_32BIT_MASK; 45static u64 uart_dmamask = DMA_BIT_MASK(32);
46 46
47static struct resource pnx833x_uart_resources[] = { 47static struct resource pnx833x_uart_resources[] = {
48 [0] = { 48 [0] = {
@@ -101,14 +101,14 @@ static struct platform_device pnx833x_uart_device = {
101 .id = -1, 101 .id = -1,
102 .dev = { 102 .dev = {
103 .dma_mask = &uart_dmamask, 103 .dma_mask = &uart_dmamask,
104 .coherent_dma_mask = DMA_32BIT_MASK, 104 .coherent_dma_mask = DMA_BIT_MASK(32),
105 .platform_data = pnx8xxx_ports, 105 .platform_data = pnx8xxx_ports,
106 }, 106 },
107 .num_resources = ARRAY_SIZE(pnx833x_uart_resources), 107 .num_resources = ARRAY_SIZE(pnx833x_uart_resources),
108 .resource = pnx833x_uart_resources, 108 .resource = pnx833x_uart_resources,
109}; 109};
110 110
111static u64 ehci_dmamask = DMA_32BIT_MASK; 111static u64 ehci_dmamask = DMA_BIT_MASK(32);
112 112
113static struct resource pnx833x_usb_ehci_resources[] = { 113static struct resource pnx833x_usb_ehci_resources[] = {
114 [0] = { 114 [0] = {
@@ -128,7 +128,7 @@ static struct platform_device pnx833x_usb_ehci_device = {
128 .id = -1, 128 .id = -1,
129 .dev = { 129 .dev = {
130 .dma_mask = &ehci_dmamask, 130 .dma_mask = &ehci_dmamask,
131 .coherent_dma_mask = DMA_32BIT_MASK, 131 .coherent_dma_mask = DMA_BIT_MASK(32),
132 }, 132 },
133 .num_resources = ARRAY_SIZE(pnx833x_usb_ehci_resources), 133 .num_resources = ARRAY_SIZE(pnx833x_usb_ehci_resources),
134 .resource = pnx833x_usb_ehci_resources, 134 .resource = pnx833x_usb_ehci_resources,
@@ -198,7 +198,7 @@ static struct platform_device pnx833x_i2c1_device = {
198}; 198};
199#endif 199#endif
200 200
201static u64 ethernet_dmamask = DMA_32BIT_MASK; 201static u64 ethernet_dmamask = DMA_BIT_MASK(32);
202 202
203static struct resource pnx833x_ethernet_resources[] = { 203static struct resource pnx833x_ethernet_resources[] = {
204 [0] = { 204 [0] = {
@@ -218,7 +218,7 @@ static struct platform_device pnx833x_ethernet_device = {
218 .id = -1, 218 .id = -1,
219 .dev = { 219 .dev = {
220 .dma_mask = &ethernet_dmamask, 220 .dma_mask = &ethernet_dmamask,
221 .coherent_dma_mask = DMA_32BIT_MASK, 221 .coherent_dma_mask = DMA_BIT_MASK(32),
222 }, 222 },
223 .num_resources = ARRAY_SIZE(pnx833x_ethernet_resources), 223 .num_resources = ARRAY_SIZE(pnx833x_ethernet_resources),
224 .resource = pnx833x_ethernet_resources, 224 .resource = pnx833x_ethernet_resources,
diff --git a/arch/mips/nxp/pnx8550/common/platform.c b/arch/mips/nxp/pnx8550/common/platform.c
index 21d2955359b3..5264cc09a27b 100644
--- a/arch/mips/nxp/pnx8550/common/platform.c
+++ b/arch/mips/nxp/pnx8550/common/platform.c
@@ -92,16 +92,16 @@ struct pnx8xxx_port pnx8xxx_ports[] = {
92}; 92};
93 93
94/* The dmamask must be set for OHCI to work */ 94/* The dmamask must be set for OHCI to work */
95static u64 ohci_dmamask = DMA_32BIT_MASK; 95static u64 ohci_dmamask = DMA_BIT_MASK(32);
96 96
97static u64 uart_dmamask = DMA_32BIT_MASK; 97static u64 uart_dmamask = DMA_BIT_MASK(32);
98 98
99static struct platform_device pnx8550_usb_ohci_device = { 99static struct platform_device pnx8550_usb_ohci_device = {
100 .name = "pnx8550-ohci", 100 .name = "pnx8550-ohci",
101 .id = -1, 101 .id = -1,
102 .dev = { 102 .dev = {
103 .dma_mask = &ohci_dmamask, 103 .dma_mask = &ohci_dmamask,
104 .coherent_dma_mask = DMA_32BIT_MASK, 104 .coherent_dma_mask = DMA_BIT_MASK(32),
105 }, 105 },
106 .num_resources = ARRAY_SIZE(pnx8550_usb_ohci_resources), 106 .num_resources = ARRAY_SIZE(pnx8550_usb_ohci_resources),
107 .resource = pnx8550_usb_ohci_resources, 107 .resource = pnx8550_usb_ohci_resources,
@@ -112,7 +112,7 @@ static struct platform_device pnx8550_uart_device = {
112 .id = -1, 112 .id = -1,
113 .dev = { 113 .dev = {
114 .dma_mask = &uart_dmamask, 114 .dma_mask = &uart_dmamask,
115 .coherent_dma_mask = DMA_32BIT_MASK, 115 .coherent_dma_mask = DMA_BIT_MASK(32),
116 .platform_data = pnx8xxx_ports, 116 .platform_data = pnx8xxx_ports,
117 }, 117 },
118 .num_resources = ARRAY_SIZE(pnx8550_uart_resources), 118 .num_resources = ARRAY_SIZE(pnx8550_uart_resources),
diff --git a/arch/mips/pmc-sierra/msp71xx/msp_usb.c b/arch/mips/pmc-sierra/msp71xx/msp_usb.c
index f7ca4f582331..0ee01e359dd8 100644
--- a/arch/mips/pmc-sierra/msp71xx/msp_usb.c
+++ b/arch/mips/pmc-sierra/msp71xx/msp_usb.c
@@ -49,14 +49,14 @@ static struct resource msp_usbhost_resources [] = {
49 }, 49 },
50}; 50};
51 51
52static u64 msp_usbhost_dma_mask = DMA_32BIT_MASK; 52static u64 msp_usbhost_dma_mask = DMA_BIT_MASK(32);
53 53
54static struct platform_device msp_usbhost_device = { 54static struct platform_device msp_usbhost_device = {
55 .name = "pmcmsp-ehci", 55 .name = "pmcmsp-ehci",
56 .id = 0, 56 .id = 0,
57 .dev = { 57 .dev = {
58 .dma_mask = &msp_usbhost_dma_mask, 58 .dma_mask = &msp_usbhost_dma_mask,
59 .coherent_dma_mask = DMA_32BIT_MASK, 59 .coherent_dma_mask = DMA_BIT_MASK(32),
60 }, 60 },
61 .num_resources = ARRAY_SIZE(msp_usbhost_resources), 61 .num_resources = ARRAY_SIZE(msp_usbhost_resources),
62 .resource = msp_usbhost_resources, 62 .resource = msp_usbhost_resources,
@@ -77,14 +77,14 @@ static struct resource msp_usbdev_resources [] = {
77 }, 77 },
78}; 78};
79 79
80static u64 msp_usbdev_dma_mask = DMA_32BIT_MASK; 80static u64 msp_usbdev_dma_mask = DMA_BIT_MASK(32);
81 81
82static struct platform_device msp_usbdev_device = { 82static struct platform_device msp_usbdev_device = {
83 .name = "msp71xx_udc", 83 .name = "msp71xx_udc",
84 .id = 0, 84 .id = 0,
85 .dev = { 85 .dev = {
86 .dma_mask = &msp_usbdev_dma_mask, 86 .dma_mask = &msp_usbdev_dma_mask,
87 .coherent_dma_mask = DMA_32BIT_MASK, 87 .coherent_dma_mask = DMA_BIT_MASK(32),
88 }, 88 },
89 .num_resources = ARRAY_SIZE(msp_usbdev_resources), 89 .num_resources = ARRAY_SIZE(msp_usbdev_resources),
90 .resource = msp_usbdev_resources, 90 .resource = msp_usbdev_resources,
diff --git a/arch/powerpc/kernel/dma.c b/arch/powerpc/kernel/dma.c
index 1c5c8a6fc129..53c7788cba78 100644
--- a/arch/powerpc/kernel/dma.c
+++ b/arch/powerpc/kernel/dma.c
@@ -94,7 +94,7 @@ static int dma_direct_dma_supported(struct device *dev, u64 mask)
94 * done via some global so platforms can set the limit in case 94 * done via some global so platforms can set the limit in case
95 * they have limited DMA windows 95 * they have limited DMA windows
96 */ 96 */
97 return mask >= DMA_32BIT_MASK; 97 return mask >= DMA_BIT_MASK(32);
98#else 98#else
99 return 1; 99 return 1;
100#endif 100#endif
diff --git a/arch/powerpc/kernel/of_platform.c b/arch/powerpc/kernel/of_platform.c
index 3f37a6e62771..87df428e3588 100644
--- a/arch/powerpc/kernel/of_platform.c
+++ b/arch/powerpc/kernel/of_platform.c
@@ -76,7 +76,7 @@ struct of_device* of_platform_device_create(struct device_node *np,
76 return NULL; 76 return NULL;
77 77
78 dev->dma_mask = 0xffffffffUL; 78 dev->dma_mask = 0xffffffffUL;
79 dev->dev.coherent_dma_mask = DMA_32BIT_MASK; 79 dev->dev.coherent_dma_mask = DMA_BIT_MASK(32);
80 80
81 dev->dev.bus = &of_platform_bus_type; 81 dev->dev.bus = &of_platform_bus_type;
82 82
diff --git a/arch/powerpc/platforms/iseries/iommu.c b/arch/powerpc/platforms/iseries/iommu.c
index 6ed75bffc8ab..ff43f1fd8343 100644
--- a/arch/powerpc/platforms/iseries/iommu.c
+++ b/arch/powerpc/platforms/iseries/iommu.c
@@ -202,7 +202,7 @@ static struct iommu_table vio_iommu_table;
202void *iseries_hv_alloc(size_t size, dma_addr_t *dma_handle, gfp_t flag) 202void *iseries_hv_alloc(size_t size, dma_addr_t *dma_handle, gfp_t flag)
203{ 203{
204 return iommu_alloc_coherent(NULL, &vio_iommu_table, size, dma_handle, 204 return iommu_alloc_coherent(NULL, &vio_iommu_table, size, dma_handle,
205 DMA_32BIT_MASK, flag, -1); 205 DMA_BIT_MASK(32), flag, -1);
206} 206}
207EXPORT_SYMBOL_GPL(iseries_hv_alloc); 207EXPORT_SYMBOL_GPL(iseries_hv_alloc);
208 208
@@ -217,7 +217,7 @@ dma_addr_t iseries_hv_map(void *vaddr, size_t size,
217{ 217{
218 return iommu_map_page(NULL, &vio_iommu_table, virt_to_page(vaddr), 218 return iommu_map_page(NULL, &vio_iommu_table, virt_to_page(vaddr),
219 (unsigned long)vaddr % PAGE_SIZE, size, 219 (unsigned long)vaddr % PAGE_SIZE, size,
220 DMA_32BIT_MASK, direction, NULL); 220 DMA_BIT_MASK(32), direction, NULL);
221} 221}
222 222
223void iseries_hv_unmap(dma_addr_t dma_handle, size_t size, 223void iseries_hv_unmap(dma_addr_t dma_handle, size_t size,
diff --git a/arch/powerpc/platforms/ps3/system-bus.c b/arch/powerpc/platforms/ps3/system-bus.c
index a705fffbb498..9a73d0238639 100644
--- a/arch/powerpc/platforms/ps3/system-bus.c
+++ b/arch/powerpc/platforms/ps3/system-bus.c
@@ -689,7 +689,7 @@ static void ps3_ioc0_unmap_sg(struct device *_dev, struct scatterlist *sg,
689 689
690static int ps3_dma_supported(struct device *_dev, u64 mask) 690static int ps3_dma_supported(struct device *_dev, u64 mask)
691{ 691{
692 return mask >= DMA_32BIT_MASK; 692 return mask >= DMA_BIT_MASK(32);
693} 693}
694 694
695static struct dma_mapping_ops ps3_sb_dma_ops = { 695static struct dma_mapping_ops ps3_sb_dma_ops = {
diff --git a/arch/x86/include/asm/dma-mapping.h b/arch/x86/include/asm/dma-mapping.h
index cea7b74963e9..10a6be94eb77 100644
--- a/arch/x86/include/asm/dma-mapping.h
+++ b/arch/x86/include/asm/dma-mapping.h
@@ -238,7 +238,7 @@ static inline unsigned long dma_alloc_coherent_mask(struct device *dev,
238 238
239 dma_mask = dev->coherent_dma_mask; 239 dma_mask = dev->coherent_dma_mask;
240 if (!dma_mask) 240 if (!dma_mask)
241 dma_mask = (gfp & GFP_DMA) ? DMA_24BIT_MASK : DMA_32BIT_MASK; 241 dma_mask = (gfp & GFP_DMA) ? DMA_24BIT_MASK : DMA_BIT_MASK(32);
242 242
243 return dma_mask; 243 return dma_mask;
244} 244}
@@ -250,7 +250,7 @@ static inline gfp_t dma_alloc_coherent_gfp_flags(struct device *dev, gfp_t gfp)
250 if (dma_mask <= DMA_24BIT_MASK) 250 if (dma_mask <= DMA_24BIT_MASK)
251 gfp |= GFP_DMA; 251 gfp |= GFP_DMA;
252#ifdef CONFIG_X86_64 252#ifdef CONFIG_X86_64
253 if (dma_mask <= DMA_32BIT_MASK && !(gfp & GFP_DMA)) 253 if (dma_mask <= DMA_BIT_MASK(32) && !(gfp & GFP_DMA))
254 gfp |= GFP_DMA32; 254 gfp |= GFP_DMA32;
255#endif 255#endif
256 return gfp; 256 return gfp;
diff --git a/arch/x86/kernel/pci-dma.c b/arch/x86/kernel/pci-dma.c
index 0cf2d900422b..136a01d52db0 100644
--- a/arch/x86/kernel/pci-dma.c
+++ b/arch/x86/kernel/pci-dma.c
@@ -40,7 +40,7 @@ EXPORT_SYMBOL(bad_dma_address);
40 to older i386. */ 40 to older i386. */
41struct device x86_dma_fallback_dev = { 41struct device x86_dma_fallback_dev = {
42 .init_name = "fallback device", 42 .init_name = "fallback device",
43 .coherent_dma_mask = DMA_32BIT_MASK, 43 .coherent_dma_mask = DMA_BIT_MASK(32),
44 .dma_mask = &x86_dma_fallback_dev.coherent_dma_mask, 44 .dma_mask = &x86_dma_fallback_dev.coherent_dma_mask,
45}; 45};
46EXPORT_SYMBOL(x86_dma_fallback_dev); 46EXPORT_SYMBOL(x86_dma_fallback_dev);
@@ -148,7 +148,7 @@ again:
148 if (!is_buffer_dma_capable(dma_mask, addr, size)) { 148 if (!is_buffer_dma_capable(dma_mask, addr, size)) {
149 __free_pages(page, get_order(size)); 149 __free_pages(page, get_order(size));
150 150
151 if (dma_mask < DMA_32BIT_MASK && !(flag & GFP_DMA)) { 151 if (dma_mask < DMA_BIT_MASK(32) && !(flag & GFP_DMA)) {
152 flag = (flag & ~GFP_DMA32) | GFP_DMA; 152 flag = (flag & ~GFP_DMA32) | GFP_DMA;
153 goto again; 153 goto again;
154 } 154 }
diff --git a/arch/x86/kernel/pci-nommu.c b/arch/x86/kernel/pci-nommu.c
index c6d703b39326..71d412a09f30 100644
--- a/arch/x86/kernel/pci-nommu.c
+++ b/arch/x86/kernel/pci-nommu.c
@@ -15,7 +15,7 @@ static int
15check_addr(char *name, struct device *hwdev, dma_addr_t bus, size_t size) 15check_addr(char *name, struct device *hwdev, dma_addr_t bus, size_t size)
16{ 16{
17 if (hwdev && !is_buffer_dma_capable(*hwdev->dma_mask, bus, size)) { 17 if (hwdev && !is_buffer_dma_capable(*hwdev->dma_mask, bus, size)) {
18 if (*hwdev->dma_mask >= DMA_32BIT_MASK) 18 if (*hwdev->dma_mask >= DMA_BIT_MASK(32))
19 printk(KERN_ERR 19 printk(KERN_ERR
20 "nommu_%s: overflow %Lx+%zu of device mask %Lx\n", 20 "nommu_%s: overflow %Lx+%zu of device mask %Lx\n",
21 name, (long long)bus, size, 21 name, (long long)bus, size,