summaryrefslogtreecommitdiffstats
path: root/drivers/net/s2io.h
diff options
context:
space:
mode:
authorAndi Kleen <andi@firstfloor.org>2008-06-18 13:58:36 +0200
committerJeff Garzik <jgarzik@redhat.com>2008-06-27 01:31:22 -0400
commit64c42f697661e27c9688a32c1ba61d0228e81d84 (patch)
tree57d86c9f63a2afba3bc6b5d9b9db11763740282b /drivers/net/s2io.h
parent581abbc26a7adb693fb8b913f1be18d1c349c1ab (diff)
downloadop-kernel-dev-64c42f697661e27c9688a32c1ba61d0228e81d84.zip
op-kernel-dev-64c42f697661e27c9688a32c1ba61d0228e81d84.tar.gz
[netdrvr] Fix IOMMU overflow checking in s2io.c
s2io has IOMMU overflow checking, but unfortunately it is wrong. It didn't use the standard macros, which meant that it only worked on POWER and SPARC because only those define DMA_ERROR_CODE. Convert it to use the standard macros instead. I also commented two more bugs in the IOMMU handling. It assumes that 0 DMA addresses cannot happen, but that's not true in all IOMMU setups. The information if a buffer has been already mapped needs to be stored elsewhere. Didn't fix those because it needs careful checking of the buffer handling by the maintainers. Cc: ram.vepa@neterion.com Cc: santosh.rastapur@neterion.com Cc: sivakumar.subramani@neterion.com Cc: sreenivasa.honnur@neterion.com Signed-off-by: Andi Kleen <ak@linux.intel.com> Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/net/s2io.h')
-rw-r--r--drivers/net/s2io.h4
1 files changed, 0 insertions, 4 deletions
diff --git a/drivers/net/s2io.h b/drivers/net/s2io.h
index 4706f7f..1827b66 100644
--- a/drivers/net/s2io.h
+++ b/drivers/net/s2io.h
@@ -75,10 +75,6 @@ static int debug_level = ERR_DBG;
/* DEBUG message print. */
#define DBG_PRINT(dbg_level, args...) if(!(debug_level<dbg_level)) printk(args)
-#ifndef DMA_ERROR_CODE
-#define DMA_ERROR_CODE (~(dma_addr_t)0x0)
-#endif
-
/* Protocol assist features of the NIC */
#define L3_CKSUM_OK 0xFFFF
#define L4_CKSUM_OK 0xFFFF
OpenPOWER on IntegriCloud