diff options
author | Dan Douglass <dan.douglass@freescale.com> | 2016-03-11 17:17:40 -0600 |
---|---|---|
committer | Dan Douglass <dan.douglass@freescale.com> | 2016-03-11 18:26:02 -0600 |
commit | 02eeea4cc9c8cb6819bc00a869bac9e0026be347 (patch) | |
tree | 9515cccd28dc4437545b2ec0dac82eea5ad54d58 | |
parent | c9028d9e934d3073009654f64d1b494a0f21e71c (diff) |
MLK-12475 CAAM: sg pointer updated instead of local copy
Correct error in CAAM driver port. dma_map_sg_chained() had a patch
applied to traverse the sg list using a local copy to prevent
changing the value of the passed in sg list pointer.
Signed-off-by: Dan Douglass <dan.douglass@nxp.com>
-rw-r--r-- | drivers/crypto/caam/sg_sw_sec4.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/crypto/caam/sg_sw_sec4.h b/drivers/crypto/caam/sg_sw_sec4.h index 70af42dc531a..d0f7ecbfdca3 100644 --- a/drivers/crypto/caam/sg_sw_sec4.h +++ b/drivers/crypto/caam/sg_sw_sec4.h @@ -1,7 +1,7 @@ /* * CAAM/SEC 4.x functions for using scatterlists in caam driver * - * Copyright 2008-2015 Freescale Semiconductor, Inc. + * Copyright 2008-2016 Freescale Semiconductor, Inc. * */ @@ -91,14 +91,14 @@ static int dma_map_sg_chained(struct device *dev, struct scatterlist *sg, { if (unlikely(chained)) { int i; - struct scatterlist *tsg = sg; + struct scatterlist *tsg = sg; /* We use a local copy of the sg pointer to avoid moving the * head of the list pointed to by sg as we wall the list. */ for (i = 0; i < nents; i++) { dma_map_sg(dev, tsg, 1, dir); - sg = sg_next(tsg); + tsg = sg_next(tsg); } } else { dma_map_sg(dev, sg, nents, dir); |