mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-01-09 14:50:19 +00:00
crypto: img-hash - Fix null pointer exception
Sporadic null pointer exceptions came from here. Fix them. Signed-off-by: Will Thomas <will.thomas@imgtec.com> Reviewed-by: James Hartley <james.hartley@imgtec.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
This commit is contained in:
parent
0fae0c1e1d
commit
10badea259
@ -361,7 +361,7 @@ static void img_hash_dma_task(unsigned long d)
|
||||
size_t nbytes, bleft, wsend, len, tbc;
|
||||
struct scatterlist tsg;
|
||||
|
||||
if (!ctx->sg)
|
||||
if (!hdev->req || !ctx->sg)
|
||||
return;
|
||||
|
||||
addr = sg_virt(ctx->sg);
|
||||
|
Loading…
x
Reference in New Issue
Block a user