diff options
author | Ben Hutchings <ben@decadent.org.uk> | 2010-12-28 23:26:17 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-31 15:33:17 -0500 |
commit | f4d5900a99dbc354ef1ba384d445ff80ae4d77b4 (patch) | |
tree | 776a1733dcd37a812d4108a568dfef8689236e46 /drivers | |
parent | 824f5f38d3005c346a043dedcfe8b048b699b81a (diff) |
starfire: Fix dma_addr_t size test for MIPS
Commit 56543af "starfire: use BUILD_BUG_ON for netdrv_addr_t" revealed
that the preprocessor condition used to find the size of dma_addr_t
yielded the wrong result for some architectures and configurations.
This was kluged for 64-bit PowerPC in commit 3e502e6 by adding yet
another case to the condition. However, 64-bit MIPS configurations
are not detected reliably either.
This should be fixed by using CONFIG_ARCH_DMA_ADDR_T_64BIT, but that
isn't yet defined everywhere it should be.
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/starfire.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/starfire.c b/drivers/net/starfire.c index 4adf12422787..a4f2bd52e546 100644 --- a/drivers/net/starfire.c +++ b/drivers/net/starfire.c | |||
@@ -148,7 +148,7 @@ static int full_duplex[MAX_UNITS] = {0, }; | |||
148 | * This SUCKS. | 148 | * This SUCKS. |
149 | * We need a much better method to determine if dma_addr_t is 64-bit. | 149 | * We need a much better method to determine if dma_addr_t is 64-bit. |
150 | */ | 150 | */ |
151 | #if (defined(__i386__) && defined(CONFIG_HIGHMEM64G)) || defined(__x86_64__) || defined (__ia64__) || defined(__alpha__) || defined(__mips64__) || (defined(__mips__) && defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) || (defined(__powerpc64__) || defined(CONFIG_PHYS_64BIT)) | 151 | #if (defined(__i386__) && defined(CONFIG_HIGHMEM64G)) || defined(__x86_64__) || defined (__ia64__) || defined(__alpha__) || (defined(CONFIG_MIPS) && ((defined(CONFIG_HIGHMEM) && defined(CONFIG_64BIT_PHYS_ADDR)) || defined(CONFIG_64BIT))) || (defined(__powerpc64__) || defined(CONFIG_PHYS_64BIT)) |
152 | /* 64-bit dma_addr_t */ | 152 | /* 64-bit dma_addr_t */ |
153 | #define ADDR_64BITS /* This chip uses 64 bit addresses. */ | 153 | #define ADDR_64BITS /* This chip uses 64 bit addresses. */ |
154 | #define netdrv_addr_t __le64 | 154 | #define netdrv_addr_t __le64 |