Commit 9a17007b authored by Tudor Ambarus's avatar Tudor Ambarus Committed by Herbert Xu

crypto: atmel-{sha,tdes} - Remove unused 'err' member of driver data

'err' member was initialized to 0 but its value never changed.
Signed-off-by: default avatarTudor Ambarus <tudor.ambarus@microchip.com>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 371731ec
...@@ -136,7 +136,6 @@ struct atmel_sha_dev { ...@@ -136,7 +136,6 @@ struct atmel_sha_dev {
void __iomem *io_base; void __iomem *io_base;
spinlock_t lock; spinlock_t lock;
int err;
struct tasklet_struct done_task; struct tasklet_struct done_task;
struct tasklet_struct queue_task; struct tasklet_struct queue_task;
...@@ -1027,7 +1026,6 @@ static int atmel_sha_hw_init(struct atmel_sha_dev *dd) ...@@ -1027,7 +1026,6 @@ static int atmel_sha_hw_init(struct atmel_sha_dev *dd)
if (!(SHA_FLAGS_INIT & dd->flags)) { if (!(SHA_FLAGS_INIT & dd->flags)) {
atmel_sha_write(dd, SHA_CR, SHA_CR_SWRST); atmel_sha_write(dd, SHA_CR, SHA_CR_SWRST);
dd->flags |= SHA_FLAGS_INIT; dd->flags |= SHA_FLAGS_INIT;
dd->err = 0;
} }
return 0; return 0;
...@@ -1403,10 +1401,6 @@ static int atmel_sha_done(struct atmel_sha_dev *dd) ...@@ -1403,10 +1401,6 @@ static int atmel_sha_done(struct atmel_sha_dev *dd)
if (SHA_FLAGS_DMA_ACTIVE & dd->flags) { if (SHA_FLAGS_DMA_ACTIVE & dd->flags) {
dd->flags &= ~SHA_FLAGS_DMA_ACTIVE; dd->flags &= ~SHA_FLAGS_DMA_ACTIVE;
atmel_sha_update_dma_stop(dd); atmel_sha_update_dma_stop(dd);
if (dd->err) {
err = dd->err;
goto finish;
}
} }
if (SHA_FLAGS_OUTPUT_READY & dd->flags) { if (SHA_FLAGS_OUTPUT_READY & dd->flags) {
/* hash or semi-hash ready */ /* hash or semi-hash ready */
......
...@@ -102,7 +102,6 @@ struct atmel_tdes_dev { ...@@ -102,7 +102,6 @@ struct atmel_tdes_dev {
int irq; int irq;
unsigned long flags; unsigned long flags;
int err;
spinlock_t lock; spinlock_t lock;
struct crypto_queue queue; struct crypto_queue queue;
...@@ -228,7 +227,6 @@ static int atmel_tdes_hw_init(struct atmel_tdes_dev *dd) ...@@ -228,7 +227,6 @@ static int atmel_tdes_hw_init(struct atmel_tdes_dev *dd)
if (!(dd->flags & TDES_FLAGS_INIT)) { if (!(dd->flags & TDES_FLAGS_INIT)) {
atmel_tdes_write(dd, TDES_CR, TDES_CR_SWRST); atmel_tdes_write(dd, TDES_CR, TDES_CR_SWRST);
dd->flags |= TDES_FLAGS_INIT; dd->flags |= TDES_FLAGS_INIT;
dd->err = 0;
} }
return 0; return 0;
...@@ -1112,8 +1110,6 @@ static void atmel_tdes_done_task(unsigned long data) ...@@ -1112,8 +1110,6 @@ static void atmel_tdes_done_task(unsigned long data)
else else
err = atmel_tdes_crypt_dma_stop(dd); err = atmel_tdes_crypt_dma_stop(dd);
err = dd->err ? : err;
if (dd->total && !err) { if (dd->total && !err) {
if (dd->flags & TDES_FLAGS_FAST) { if (dd->flags & TDES_FLAGS_FAST) {
dd->in_sg = sg_next(dd->in_sg); dd->in_sg = sg_next(dd->in_sg);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment