diff options
author | Kim Phillips <kim.phillips@freescale.com> | 2011-11-21 03:13:27 -0500 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2011-11-21 03:21:51 -0500 |
commit | c3e337f88a5b3784cb3c806ffd650d06adff1ea5 (patch) | |
tree | 12ca78132c4ccc74257bf2ad634e1c06a062d2bd /drivers/crypto/talitos.h | |
parent | ad42d5fc85383278663ecb58a24f6547ad0ba735 (diff) |
crypto: talitos - support for channel remap and 2nd IRQ
Some later SEC v3.x are equipped with a second IRQ line.
By correctly assigning IRQ affinity, this feature can be
used to increase performance on dual core parts, like the
MPC8572E and P2020E.
The existence of the 2nd IRQ is determined from the device
node's interrupt property. If present, the driver remaps
two of four channels, which in turn makes those channels
trigger their interrupts on the 2nd line instead of the first.
To handle single- and dual-IRQ combinations efficiently,
talitos gets two new interrupt handlers and back-half workers.
[includes a fix to MCR_LO's address.]
Signed-off-by: Kim Phillips <kim.phillips@freescale.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/talitos.h')
-rw-r--r-- | drivers/crypto/talitos.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/drivers/crypto/talitos.h b/drivers/crypto/talitos.h index 3ed319da853c..3c173954ef29 100644 --- a/drivers/crypto/talitos.h +++ b/drivers/crypto/talitos.h | |||
@@ -34,16 +34,24 @@ | |||
34 | 34 | ||
35 | /* global register offset addresses */ | 35 | /* global register offset addresses */ |
36 | #define TALITOS_MCR 0x1030 /* master control register */ | 36 | #define TALITOS_MCR 0x1030 /* master control register */ |
37 | #define TALITOS_MCR_LO 0x1038 | 37 | #define TALITOS_MCR_RCA0 (1 << 15) /* remap channel 0 */ |
38 | #define TALITOS_MCR_RCA1 (1 << 14) /* remap channel 1 */ | ||
39 | #define TALITOS_MCR_RCA2 (1 << 13) /* remap channel 2 */ | ||
40 | #define TALITOS_MCR_RCA3 (1 << 12) /* remap channel 3 */ | ||
38 | #define TALITOS_MCR_SWR 0x1 /* s/w reset */ | 41 | #define TALITOS_MCR_SWR 0x1 /* s/w reset */ |
42 | #define TALITOS_MCR_LO 0x1034 | ||
39 | #define TALITOS_IMR 0x1008 /* interrupt mask register */ | 43 | #define TALITOS_IMR 0x1008 /* interrupt mask register */ |
40 | #define TALITOS_IMR_INIT 0x100ff /* enable channel IRQs */ | 44 | #define TALITOS_IMR_INIT 0x100ff /* enable channel IRQs */ |
41 | #define TALITOS_IMR_DONE 0x00055 /* done IRQs */ | 45 | #define TALITOS_IMR_DONE 0x00055 /* done IRQs */ |
42 | #define TALITOS_IMR_LO 0x100C | 46 | #define TALITOS_IMR_LO 0x100C |
43 | #define TALITOS_IMR_LO_INIT 0x20000 /* allow RNGU error IRQs */ | 47 | #define TALITOS_IMR_LO_INIT 0x20000 /* allow RNGU error IRQs */ |
44 | #define TALITOS_ISR 0x1010 /* interrupt status register */ | 48 | #define TALITOS_ISR 0x1010 /* interrupt status register */ |
45 | #define TALITOS_ISR_CHERR 0xaa /* channel errors mask */ | 49 | #define TALITOS_ISR_4CHERR 0xaa /* 4 channel errors mask */ |
46 | #define TALITOS_ISR_CHDONE 0x55 /* channel done mask */ | 50 | #define TALITOS_ISR_4CHDONE 0x55 /* 4 channel done mask */ |
51 | #define TALITOS_ISR_CH_0_2_ERR 0x22 /* channels 0, 2 errors mask */ | ||
52 | #define TALITOS_ISR_CH_0_2_DONE 0x11 /* channels 0, 2 done mask */ | ||
53 | #define TALITOS_ISR_CH_1_3_ERR 0x88 /* channels 1, 3 errors mask */ | ||
54 | #define TALITOS_ISR_CH_1_3_DONE 0x44 /* channels 1, 3 done mask */ | ||
47 | #define TALITOS_ISR_LO 0x1014 | 55 | #define TALITOS_ISR_LO 0x1014 |
48 | #define TALITOS_ICR 0x1018 /* interrupt clear register */ | 56 | #define TALITOS_ICR 0x1018 /* interrupt clear register */ |
49 | #define TALITOS_ICR_LO 0x101C | 57 | #define TALITOS_ICR_LO 0x101C |