crypto: mediatek - fix uninitialized value of gctx->textlen
authorRyder Lee <ryder.lee@mediatek.com>
Wed, 28 Aug 2019 06:37:13 +0000 (14:37 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 5 Sep 2019 04:36:54 +0000 (14:36 +1000)
commite049ff5af04b18bfb4105787be198d58c841fc99
tree0c97f96a3cd633b8d92600e514edaabbc0d01862
parent4797f6cab5096aa4e97cee2d0044dcf8e6bcd7b8
crypto: mediatek - fix uninitialized value of gctx->textlen

Add a pre-computed text length to avoid uninitialized value in the check.

Fixes: e47270665b5f ("crypto: mediatek - Add empty messages check in GCM mode")
Signed-off-by: Ryder Lee <ryder.lee@mediatek.com>
Signed-off-by: Vic Wu <vic.wu@mediatek.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/mediatek/mtk-aes.c