diff options
author | Myles Watson <mylesgw@gmail.com> | 2009-11-11 23:32:36 +0000 |
---|---|---|
committer | Myles Watson <mylesgw@gmail.com> | 2009-11-11 23:32:36 +0000 |
commit | 8f848137755934d1ec91fb188500881796694d28 (patch) | |
tree | 1dccc6f31b3bcf5877310d9bf1b6b2dbb40a68e8 /src/arch | |
parent | 6056b97fce79d3534363dcf508ab7b4a18a459d6 (diff) | |
download | coreboot-8f848137755934d1ec91fb188500881796694d28.tar.xz |
Silence an ugly-looking warning. Two casts were not enough, so just don't cast
it. Trust the option_table generator to get the length correct.
Signed-off-by: Myles Watson <mylesgw@gmail.com>
Acked-by: Peter Stuge <peter@stuge.se>
git-svn-id: svn://svn.coreboot.org/coreboot/trunk@4935 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
Diffstat (limited to 'src/arch')
-rw-r--r-- | src/arch/i386/boot/coreboot_table.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/arch/i386/boot/coreboot_table.c b/src/arch/i386/boot/coreboot_table.c index 9eb13b73f1..afe70d6ff6 100644 --- a/src/arch/i386/boot/coreboot_table.c +++ b/src/arch/i386/boot/coreboot_table.c @@ -485,11 +485,10 @@ unsigned long write_coreboot_table( #if (CONFIG_HAVE_OPTION_TABLE == 1) { - struct lb_record *rec_dest, *rec_src; - /* Write the option config table... */ + struct lb_record *rec_dest; + /* Copy the option config table, it's already a lb_record... */ rec_dest = lb_new_record(head); - rec_src = (struct lb_record *)(void *)&option_table; - memcpy(rec_dest, rec_src, rec_src->size); + memcpy(rec_dest, &option_table, sizeof(option_table)); /* Create cmos checksum entry in coreboot table */ lb_cmos_checksum(head); } |