Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75893
b: refs/heads/master
c: 1f4e477
h: refs/heads/master
i:
  75891: f62e115
v: v3
  • Loading branch information
Sebastian Siewior authored and Herbert Xu committed Jan 10, 2008
1 parent 0c516d4 commit 011980c
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2d506d4fa1df18aa9505820722f834426edc907f
refs/heads/master: 1f4e4773761d0aa622411469b54d6570005a66b1
9 changes: 6 additions & 3 deletions trunk/drivers/crypto/geode-aes.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,9 +88,10 @@ do_crypt(void *src, void *dst, int len, u32 flags)
/* Start the operation */
iowrite32(AES_CTRL_START | flags, _iobase + AES_CTRLA_REG);

do
do {
status = ioread32(_iobase + AES_INTR_REG);
while(!(status & AES_INTRA_PENDING) && --counter);
cpu_relax();
} while(!(status & AES_INTRA_PENDING) && --counter);

/* Clear the event */
iowrite32((status & 0xFF) | AES_INTRA_PENDING, _iobase + AES_INTR_REG);
Expand All @@ -102,6 +103,7 @@ geode_aes_crypt(struct geode_aes_op *op)
{
u32 flags = 0;
unsigned long iflags;
int ret;

if (op->len == 0)
return 0;
Expand Down Expand Up @@ -130,7 +132,8 @@ geode_aes_crypt(struct geode_aes_op *op)
_writefield(AES_WRITEKEY0_REG, op->key);
}

do_crypt(op->src, op->dst, op->len, flags);
ret = do_crypt(op->src, op->dst, op->len, flags);
BUG_ON(ret);

if (op->mode == AES_MODE_CBC)
_readfield(AES_WRITEIV0_REG, op->iv);
Expand Down

0 comments on commit 011980c

Please sign in to comment.