[coreboot-gerrit] Change in coreboot[master]: soc/amd/stoneyridge: Remove "else" after a return

Richard Spiegel (Code Review) gerrit at coreboot.org
Tue Oct 23 23:53:43 CEST 2018


Richard Spiegel has uploaded this change for review. ( https://review.coreboot.org/29247


Change subject: soc/amd/stoneyridge: Remove "else" after a return
......................................................................

soc/amd/stoneyridge: Remove "else" after a return

File ramtop.c has one instance of if()/else where the if tests for top mem
in lower 4GiB, and returns just before the "else" statement. These "else"
statements are not needed.

BUG=b:117648025
TEST=Build and boot grunt.

Change-Id: Iba16a416e78dae75a95a11d38179161c5a11b2ad
Signed-off-by: Richard Spiegel <richard.spiegel at silverbackltd.com>
---
M src/soc/amd/stoneyridge/ramtop.c
1 file changed, 4 insertions(+), 5 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/47/29247/1

diff --git a/src/soc/amd/stoneyridge/ramtop.c b/src/soc/amd/stoneyridge/ramtop.c
index 72db8ec..0dca034 100644
--- a/src/soc/amd/stoneyridge/ramtop.c
+++ b/src/soc/amd/stoneyridge/ramtop.c
@@ -63,11 +63,10 @@
 
 	if (!tom.lo)
 		return 0;
-	else
-		/* 8MB alignment to keep MTRR usage low */
-		return (void *)ALIGN_DOWN(restore_top_of_low_cacheable()
-				- CONFIG_SMM_TSEG_SIZE
-				- BERT_REGION_MAX_SIZE, 8*MiB);
+	/* 8MB alignment to keep MTRR usage low */
+	return (void *)ALIGN_DOWN(restore_top_of_low_cacheable()
+			- CONFIG_SMM_TSEG_SIZE
+			- BERT_REGION_MAX_SIZE, 8*MiB);
 }
 
 static uintptr_t smm_region_start(void)

-- 
To view, visit https://review.coreboot.org/29247
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iba16a416e78dae75a95a11d38179161c5a11b2ad
Gerrit-Change-Number: 29247
Gerrit-PatchSet: 1
Gerrit-Owner: Richard Spiegel <richard.spiegel at silverbackltd.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.coreboot.org/pipermail/coreboot-gerrit/attachments/20181023/0a71f32e/attachment.html>


More information about the coreboot-gerrit mailing list