drivers/intel/fsp2_0: Remove braces for single statements

Fix the following warning detected by checkpatch.pl:

WARNING: braces {} are not necessary for single statement blocks

TEST=Build and run on Galileo Gen2

Change-Id: Ibd351703e60acebbacd6ae5b1a2fa1cb34fd3ff9
Signed-off-by: Lee Leahy <leroy.p.leahy@intel.com>
Reviewed-on: https://review.coreboot.org/18745
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
Lee Leahy 2017-03-10 08:45:30 -08:00
parent b2b97a5db2
commit e686ee8bf7
2 changed files with 5 additions and 10 deletions

View File

@ -293,9 +293,8 @@ static void do_fsp_memory_init(struct fsp_header *hdr, bool s3wake,
upd = (FSPM_UPD *)(hdr->cfg_region_offset + hdr->image_base); upd = (FSPM_UPD *)(hdr->cfg_region_offset + hdr->image_base);
if (upd->FspUpdHeader.Signature != FSPM_UPD_SIGNATURE) { if (upd->FspUpdHeader.Signature != FSPM_UPD_SIGNATURE)
die("Invalid FSPM signature!\n"); die("Invalid FSPM signature!\n");
}
/* Copy the default values from the UPD area */ /* Copy the default values from the UPD area */
memcpy(&fspm_upd, upd, sizeof(fspm_upd)); memcpy(&fspm_upd, upd, sizeof(fspm_upd));
@ -417,9 +416,8 @@ void fsp_memory_init(bool s3wake)
else else
status = load_fspm_xip(&hdr, &file_data); status = load_fspm_xip(&hdr, &file_data);
if (status != CB_SUCCESS) { if (status != CB_SUCCESS)
die("Loading FSPM failed!\n"); die("Loading FSPM failed!\n");
}
/* Signal that FSP component has been loaded. */ /* Signal that FSP component has been loaded. */
prog_segment_loaded(hdr.image_base, hdr.image_size, SEG_FINAL); prog_segment_loaded(hdr.image_base, hdr.image_size, SEG_FINAL);

View File

@ -32,9 +32,8 @@ static void do_silicon_init(struct fsp_header *hdr)
supd = (FSPS_UPD *) (hdr->cfg_region_offset + hdr->image_base); supd = (FSPS_UPD *) (hdr->cfg_region_offset + hdr->image_base);
if (supd->FspUpdHeader.Signature != FSPS_UPD_SIGNATURE) { if (supd->FspUpdHeader.Signature != FSPS_UPD_SIGNATURE)
die("Invalid FSPS signature\n"); die("Invalid FSPS signature\n");
}
memcpy(&upd, supd, sizeof(upd)); memcpy(&upd, supd, sizeof(upd));
@ -96,16 +95,14 @@ void fsps_load(bool s3wake)
size = region_device_sz(&rdev); size = region_device_sz(&rdev);
dest = cbmem_add(CBMEM_ID_REFCODE, size); dest = cbmem_add(CBMEM_ID_REFCODE, size);
if (dest == NULL) { if (dest == NULL)
die("Could not add FSPS to CBMEM!\n"); die("Could not add FSPS to CBMEM!\n");
}
if (rdev_readat(&rdev, dest, 0, size) < 0) if (rdev_readat(&rdev, dest, 0, size) < 0)
die("Failed to read FSPS!\n"); die("Failed to read FSPS!\n");
if (fsp_component_relocate((uintptr_t)dest, dest, size) < 0) { if (fsp_component_relocate((uintptr_t)dest, dest, size) < 0)
die("Unable to relocate FSPS!\n"); die("Unable to relocate FSPS!\n");
}
/* Create new region device in memory after relocation. */ /* Create new region device in memory after relocation. */
rdev_chain(&rdev, &addrspace_32bit.rdev, (uintptr_t)dest, size); rdev_chain(&rdev, &addrspace_32bit.rdev, (uintptr_t)dest, size);