Patrick Georgi (pgeorgi@google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/16008
-gerrit
commit c5ff2ddf62a6fb277f5bc9823caacc9e5002162a Author: Patrick Georgi pgeorgi@chromium.org Date: Mon Aug 1 13:30:02 2016 +0200
amd/amdfam10: eliminate dead code
if (gart) { foo = gart?a:b; } never evaluates to foo=b.
Change-Id: Ibc7376687374065585b125a670dea5fe46bda97a Signed-off-by: Patrick Georgi pgeorgi@chromium.org Found-by: Coverity Scan #1347365 --- src/northbridge/amd/amdfam10/misc_control.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/northbridge/amd/amdfam10/misc_control.c b/src/northbridge/amd/amdfam10/misc_control.c index 775af66..7cd9bff 100644 --- a/src/northbridge/amd/amdfam10/misc_control.c +++ b/src/northbridge/amd/amdfam10/misc_control.c @@ -67,7 +67,7 @@ static void mcf3_read_resources(device_t dev) if (gart) { /* Add a Gart apeture resource */ resource = new_resource(dev, 0x94); - resource->size = gart?CONFIG_AGP_APERTURE_SIZE:1; + resource->size = CONFIG_AGP_APERTURE_SIZE; resource->align = log2(resource->size); resource->gran = log2(resource->size); resource->limit = 0xffffffff; /* 4G */