From: Gilad Ben-Yossef Date: Tue, 27 Jun 2017 07:27:15 +0000 (+0300) Subject: staging: ccree: fix else placement X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=8683e6272de45e9e2df9da811e9eac7c63644072;p=openwrt%2Fstaging%2Fblogic.git staging: ccree: fix else placement Fix cases where the else clause was not located correctly after the if brace. Signed-off-by: Gilad Ben-Yossef Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/ccree/ssi_buffer_mgr.c b/drivers/staging/ccree/ssi_buffer_mgr.c index 5c46145a2955..3c74ae3228e1 100644 --- a/drivers/staging/ccree/ssi_buffer_mgr.c +++ b/drivers/staging/ccree/ssi_buffer_mgr.c @@ -852,8 +852,7 @@ static inline int ssi_buffer_mgr_aead_chain_assoc( sg_index = current_sg->length; if (sg_index > size_of_assoc) { //the first entry in the scatter list contains all the associated data mapped_nents++; - } - else{ + } else { while (sg_index <= size_of_assoc) { current_sg = sg_next(current_sg); //if have reached the end of the sgl, then this is unexpected diff --git a/drivers/staging/ccree/ssi_pm.c b/drivers/staging/ccree/ssi_pm.c index c8c58754a792..ae1f7f0bb715 100644 --- a/drivers/staging/ccree/ssi_pm.c +++ b/drivers/staging/ccree/ssi_pm.c @@ -110,8 +110,7 @@ int ssi_power_mgr_runtime_put_suspend(struct device *dev) (struct ssi_drvdata *)dev_get_drvdata(dev))) { pm_runtime_mark_last_busy(dev); rc = pm_runtime_put_autosuspend(dev); - } - else { + } else { /* Something wrong happens*/ BUG(); }