Staging: et131x: Fix the add_10bit macro
authorAlan Cox <alan@linux.intel.com>
Mon, 12 Oct 2009 14:38:26 +0000 (15:38 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 14 Oct 2009 21:14:39 +0000 (14:14 -0700)
Duh.. we need to preserve the wrap bit when adding.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/et131x/et1310_address_map.h

index 6294d3814e72c8ef7c406881b8dbb931f47df712..2c3d65a622a7897caea27f11a34d3ce42202b78f 100644 (file)
@@ -223,7 +223,7 @@ typedef union _TXDMA_PR_NUM_DES_t {
 
 extern inline void add_10bit(u32 *v, int n)
 {
-       *v = INDEX10(*v + n);
+       *v = INDEX10(*v + n) | (*v & ET_DMA10_WRAP);
 }
 
 /*