diff options
Diffstat (limited to 'include/asm-arm/arch-iop13xx/adma.h')
-rw-r--r-- | include/asm-arm/arch-iop13xx/adma.h | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/include/asm-arm/arch-iop13xx/adma.h b/include/asm-arm/arch-iop13xx/adma.h index 04006c1c5fd7..efd9a5eb1008 100644 --- a/include/asm-arm/arch-iop13xx/adma.h +++ b/include/asm-arm/arch-iop13xx/adma.h | |||
@@ -247,7 +247,7 @@ static inline u32 iop_desc_get_src_count(struct iop_adma_desc_slot *desc, | |||
247 | } | 247 | } |
248 | 248 | ||
249 | static inline void | 249 | static inline void |
250 | iop_desc_init_memcpy(struct iop_adma_desc_slot *desc, int int_en) | 250 | iop_desc_init_memcpy(struct iop_adma_desc_slot *desc, unsigned long flags) |
251 | { | 251 | { |
252 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; | 252 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; |
253 | union { | 253 | union { |
@@ -257,13 +257,13 @@ iop_desc_init_memcpy(struct iop_adma_desc_slot *desc, int int_en) | |||
257 | 257 | ||
258 | u_desc_ctrl.value = 0; | 258 | u_desc_ctrl.value = 0; |
259 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ | 259 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ |
260 | u_desc_ctrl.field.int_en = int_en; | 260 | u_desc_ctrl.field.int_en = flags & DMA_PREP_INTERRUPT; |
261 | hw_desc->desc_ctrl = u_desc_ctrl.value; | 261 | hw_desc->desc_ctrl = u_desc_ctrl.value; |
262 | hw_desc->crc_addr = 0; | 262 | hw_desc->crc_addr = 0; |
263 | } | 263 | } |
264 | 264 | ||
265 | static inline void | 265 | static inline void |
266 | iop_desc_init_memset(struct iop_adma_desc_slot *desc, int int_en) | 266 | iop_desc_init_memset(struct iop_adma_desc_slot *desc, unsigned long flags) |
267 | { | 267 | { |
268 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; | 268 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; |
269 | union { | 269 | union { |
@@ -274,14 +274,15 @@ iop_desc_init_memset(struct iop_adma_desc_slot *desc, int int_en) | |||
274 | u_desc_ctrl.value = 0; | 274 | u_desc_ctrl.value = 0; |
275 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ | 275 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ |
276 | u_desc_ctrl.field.block_fill_en = 1; | 276 | u_desc_ctrl.field.block_fill_en = 1; |
277 | u_desc_ctrl.field.int_en = int_en; | 277 | u_desc_ctrl.field.int_en = flags & DMA_PREP_INTERRUPT; |
278 | hw_desc->desc_ctrl = u_desc_ctrl.value; | 278 | hw_desc->desc_ctrl = u_desc_ctrl.value; |
279 | hw_desc->crc_addr = 0; | 279 | hw_desc->crc_addr = 0; |
280 | } | 280 | } |
281 | 281 | ||
282 | /* to do: support buffers larger than ADMA_MAX_BYTE_COUNT */ | 282 | /* to do: support buffers larger than ADMA_MAX_BYTE_COUNT */ |
283 | static inline void | 283 | static inline void |
284 | iop_desc_init_xor(struct iop_adma_desc_slot *desc, int src_cnt, int int_en) | 284 | iop_desc_init_xor(struct iop_adma_desc_slot *desc, int src_cnt, |
285 | unsigned long flags) | ||
285 | { | 286 | { |
286 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; | 287 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; |
287 | union { | 288 | union { |
@@ -292,7 +293,7 @@ iop_desc_init_xor(struct iop_adma_desc_slot *desc, int src_cnt, int int_en) | |||
292 | u_desc_ctrl.value = 0; | 293 | u_desc_ctrl.value = 0; |
293 | u_desc_ctrl.field.src_select = src_cnt - 1; | 294 | u_desc_ctrl.field.src_select = src_cnt - 1; |
294 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ | 295 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ |
295 | u_desc_ctrl.field.int_en = int_en; | 296 | u_desc_ctrl.field.int_en = flags & DMA_PREP_INTERRUPT; |
296 | hw_desc->desc_ctrl = u_desc_ctrl.value; | 297 | hw_desc->desc_ctrl = u_desc_ctrl.value; |
297 | hw_desc->crc_addr = 0; | 298 | hw_desc->crc_addr = 0; |
298 | 299 | ||
@@ -301,7 +302,8 @@ iop_desc_init_xor(struct iop_adma_desc_slot *desc, int src_cnt, int int_en) | |||
301 | 302 | ||
302 | /* to do: support buffers larger than ADMA_MAX_BYTE_COUNT */ | 303 | /* to do: support buffers larger than ADMA_MAX_BYTE_COUNT */ |
303 | static inline int | 304 | static inline int |
304 | iop_desc_init_zero_sum(struct iop_adma_desc_slot *desc, int src_cnt, int int_en) | 305 | iop_desc_init_zero_sum(struct iop_adma_desc_slot *desc, int src_cnt, |
306 | unsigned long flags) | ||
305 | { | 307 | { |
306 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; | 308 | struct iop13xx_adma_desc_hw *hw_desc = desc->hw_desc; |
307 | union { | 309 | union { |
@@ -314,7 +316,7 @@ iop_desc_init_zero_sum(struct iop_adma_desc_slot *desc, int src_cnt, int int_en) | |||
314 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ | 316 | u_desc_ctrl.field.xfer_dir = 3; /* local to internal bus */ |
315 | u_desc_ctrl.field.zero_result = 1; | 317 | u_desc_ctrl.field.zero_result = 1; |
316 | u_desc_ctrl.field.status_write_back_en = 1; | 318 | u_desc_ctrl.field.status_write_back_en = 1; |
317 | u_desc_ctrl.field.int_en = int_en; | 319 | u_desc_ctrl.field.int_en = flags & DMA_PREP_INTERRUPT; |
318 | hw_desc->desc_ctrl = u_desc_ctrl.value; | 320 | hw_desc->desc_ctrl = u_desc_ctrl.value; |
319 | hw_desc->crc_addr = 0; | 321 | hw_desc->crc_addr = 0; |
320 | 322 | ||