瀏覽代碼

Staging: et131x: Fix the add_10bit macro

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>
Alan Cox 15 年之前
父節點
當前提交
317c68c04d
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/staging/et131x/et1310_address_map.h

+ 1 - 1
drivers/staging/et131x/et1310_address_map.h

@@ -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);
 }
 
 /*