summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorJamie Iles <jamie@jamieiles.com>2011-08-02 11:29:06 +0100
committerHerbert Xu <herbert@gondor.apana.org.au>2011-08-10 19:00:27 +0800
commitb64dc04beba30947dc80745dcb95ae3c04fd18cf (patch)
tree754ab3746c524f42d045491be7df01cde3c0f1fe /drivers
parent30343ef1de348cd21cd7d0cebde3c0175b730e0b (diff)
crypto: picoxcell - fix possible invalid pointer dereference
The completion callback will free the request so we must remove it from the completion list before calling the callback. Cc: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: Jamie Iles <jamie@jamieiles.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/crypto/picoxcell_crypto.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/crypto/picoxcell_crypto.c b/drivers/crypto/picoxcell_crypto.c
index 017340c3b71..a2b553eabbd 100644
--- a/drivers/crypto/picoxcell_crypto.c
+++ b/drivers/crypto/picoxcell_crypto.c
@@ -1242,8 +1242,8 @@ static void spacc_spacc_complete(unsigned long data)
spin_unlock_irqrestore(&engine->hw_lock, flags);
list_for_each_entry_safe(req, tmp, &completed, list) {
- req->complete(req);
list_del(&req->list);
+ req->complete(req);
}
}