commit a758ad3aa6d56e982c0e5979e0df030ccb4d8221
Author: Mike Marciniszyn <[email protected]>
Date:   Mon Mar 14 16:52:05 2011 -0400

    Fix SLES10 SP3 backport

    The following syntax error was occuring on SLES10 SP3 with qib configured:

    qib/qib_dma.c:56: error: implicit declaration of function 
valid_dma_direction.

    The fix to dma-mapping.h just before this fix removed the
   valid_dma_direction() routine to allow for the compilation on XEN kernels.

    This fix adds valid_dma_direction() back in conditioning the "removal" on
    CONFIG_XEN to allow both qib and XEN compiles to work.

    Signed-off-by: Mike Marciniszyn <[email protected]>

diff --git 
a/kernel_addons/backport/2.6.16_sles10_sp3/include/linux/dma-mapping.h 
b/kernel_addons/backport/2.6.16_sles10_sp3/include/linux/dma-mapp
index 9cd18ad..4ac9edd 100644
--- a/kernel_addons/backport/2.6.16_sles10_sp3/include/linux/dma-mapping.h
+++ b/kernel_addons/backport/2.6.16_sles10_sp3/include/linux/dma-mapping.h
@@ -3,6 +3,15 @@

#include_next <linux/dma-mapping.h>

+#ifndef CONFIG_XEN
+static inline int valid_dma_direction(int dma_direction)
+{
+       return ((dma_direction == DMA_BIDIRECTIONAL) ||
+               (dma_direction == DMA_TO_DEVICE) ||
+               (dma_direction == DMA_FROM_DEVICE));
+}
+#endif
+
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))

#ifndef CONFIG_HAVE_DMA_ATTRS

________________________________
This message and any attached documents contain information from QLogic 
Corporation or its wholly-owned subsidiaries that may be confidential. If you 
are not the intended recipient, you may not read, copy, distribute, or use this 
information. If you have received this transmission in error, please notify the 
sender immediately by reply e-mail and then delete this message.
_______________________________________________
ewg mailing list
[email protected]
http://lists.openfabrics.org/cgi-bin/mailman/listinfo/ewg

Reply via email to