]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
drivers/crypto/fsl: correct error checking in run_descriptor
authorAneesh Bansal <aneesh.bansal@nxp.com>
Thu, 11 Feb 2016 09:06:51 +0000 (14:36 +0530)
committerYork Sun <york.sun@nxp.com>
Mon, 21 Mar 2016 19:42:11 +0000 (12:42 -0700)
When CAAM runs a descriptor and an error occurs, a non-zero
value is set in Output Status Register. The if condition should
check the status for a non-zero value.

Signed-off-by: Aneesh Bansal <aneesh.bansal@nxp.com>
Reviewed-by: York Sun <york.sun@nxp.com>
drivers/crypto/fsl/jr.c

index b766470ce224cf40fef613e97500af08f9baefd2..93c24712d1ef824396841a6913d75c2fe0c61feb 100644 (file)
@@ -360,7 +360,7 @@ int run_descriptor_jr(uint32_t *desc)
                }
        }
 
-       if (!op.status) {
+       if (op.status) {
                debug("Error %x\n", op.status);
                ret = op.status;
        }