From: Corentin Labbe Date: Fri, 18 Sep 2020 07:23:15 +0000 (+0000) Subject: crypto: sun8i-ss - fix comparison of integer expressions of different signedness X-Git-Tag: v5.15~2545^2~53 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=fcf5d2dcadde06f2c82eef460198e2f2f4b642f8;p=platform%2Fkernel%2Flinux-starfive.git crypto: sun8i-ss - fix comparison of integer expressions of different signedness This patch fixes the warning: warning: comparison of integer expressions of different signedness: 'int' and 'long unsigned int' [-Wsign-compare] Signed-off-by: Corentin Labbe Signed-off-by: Herbert Xu --- diff --git a/drivers/crypto/allwinner/sun8i-ss/sun8i-ss-core.c b/drivers/crypto/allwinner/sun8i-ss/sun8i-ss-core.c index 44a6a5d..e0ddc68 100644 --- a/drivers/crypto/allwinner/sun8i-ss/sun8i-ss-core.c +++ b/drivers/crypto/allwinner/sun8i-ss/sun8i-ss-core.c @@ -414,7 +414,7 @@ static struct sun8i_ss_alg_template ss_algs[] = { static int sun8i_ss_debugfs_show(struct seq_file *seq, void *v) { struct sun8i_ss_dev *ss = seq->private; - int i; + unsigned int i; for (i = 0; i < MAXFLOW; i++) seq_printf(seq, "Channel %d: nreq %lu\n", i, ss->flows[i].stat_req); @@ -560,7 +560,8 @@ static void sun8i_ss_pm_exit(struct sun8i_ss_dev *ss) static int sun8i_ss_register_algs(struct sun8i_ss_dev *ss) { - int ss_method, err, id, i; + int ss_method, err, id; + unsigned int i; for (i = 0; i < ARRAY_SIZE(ss_algs); i++) { ss_algs[i].ss = ss; @@ -631,7 +632,7 @@ static int sun8i_ss_register_algs(struct sun8i_ss_dev *ss) static void sun8i_ss_unregister_algs(struct sun8i_ss_dev *ss) { - int i; + unsigned int i; for (i = 0; i < ARRAY_SIZE(ss_algs); i++) { if (!ss_algs[i].ss)