diff options
author | Richard Weinberger <richard@nod.at> | 2011-10-10 06:55:41 -0400 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2011-10-21 08:28:57 -0400 |
commit | 75b766258eb2b8255c628a994663bd5298f216e6 (patch) | |
tree | db755f2fbe3aeccb8b00e6eba238999221da0eca /drivers/crypto | |
parent | 906b2c9f2d9f395f5ca01b855b7c74b126517816 (diff) |
crypto: Make hifn_795x build depend on !ARCH_DMA_ADDR_T_64BIT
hifn_795x works only on 32 bit, remove the detection while loading
the module and catch non-32 bit systems at build time.
Signed-off-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto')
-rw-r--r-- | drivers/crypto/Kconfig | 1 | ||||
-rw-r--r-- | drivers/crypto/hifn_795x.c | 6 |
2 files changed, 3 insertions, 4 deletions
diff --git a/drivers/crypto/Kconfig b/drivers/crypto/Kconfig index 4ac6d4d2bd14..6d16b4b0d7a0 100644 --- a/drivers/crypto/Kconfig +++ b/drivers/crypto/Kconfig | |||
@@ -200,6 +200,7 @@ config CRYPTO_DEV_HIFN_795X | |||
200 | select CRYPTO_BLKCIPHER | 200 | select CRYPTO_BLKCIPHER |
201 | select HW_RANDOM if CRYPTO_DEV_HIFN_795X_RNG | 201 | select HW_RANDOM if CRYPTO_DEV_HIFN_795X_RNG |
202 | depends on PCI | 202 | depends on PCI |
203 | depends on !ARCH_DMA_ADDR_T_64BIT | ||
203 | help | 204 | help |
204 | This option allows you to have support for HIFN 795x crypto adapters. | 205 | This option allows you to have support for HIFN 795x crypto adapters. |
205 | 206 | ||
diff --git a/drivers/crypto/hifn_795x.c b/drivers/crypto/hifn_795x.c index a84250a5dd51..fe765f49de58 100644 --- a/drivers/crypto/hifn_795x.c +++ b/drivers/crypto/hifn_795x.c | |||
@@ -2744,10 +2744,8 @@ static int __init hifn_init(void) | |||
2744 | unsigned int freq; | 2744 | unsigned int freq; |
2745 | int err; | 2745 | int err; |
2746 | 2746 | ||
2747 | if (sizeof(dma_addr_t) > 4) { | 2747 | /* HIFN supports only 32-bit addresses */ |
2748 | printk(KERN_INFO "HIFN supports only 32-bit addresses.\n"); | 2748 | BUILD_BUG_ON(sizeof(dma_addr_t) != 4); |
2749 | return -EINVAL; | ||
2750 | } | ||
2751 | 2749 | ||
2752 | if (strncmp(hifn_pll_ref, "ext", 3) && | 2750 | if (strncmp(hifn_pll_ref, "ext", 3) && |
2753 | strncmp(hifn_pll_ref, "pci", 3)) { | 2751 | strncmp(hifn_pll_ref, "pci", 3)) { |