Hello all, To start teh day, a small patch for an invalid local variable... In C, local variable must be declared before any statment, and not, like in C++ in the middle of the function.
Make good use of it.
Regards,
Stephan.
Signed-off-by: Stephan Guilloux <[email protected]>
diff -rc flashrom-623/physmap.c flashrom-623.new/physmap.c
*** flashrom-623/physmap.c Tue Jun 23 07:28:15 2009
--- flashrom-623.new/physmap.c Tue Jun 23 09:46:01 2009
***************
*** 80,85 ****
--- 80,87 ----
void *physmap(const char *descr, unsigned long phys_addr, size_t len)
{
+ void *virt_addr;
+
if (len == 0) {
printf_debug("Not mapping %s, zero size at 0x%08lx.\n",
descr, phys_addr);
***************
*** 96,102 ****
descr, (unsigned long)len, phys_addr);
}
! void *virt_addr = sys_physmap(phys_addr, len);
if (NULL == virt_addr) {
if (NULL == descr)
--- 98,104 ----
descr, (unsigned long)len, phys_addr);
}
! virt_addr = sys_physmap(phys_addr, len);
if (NULL == virt_addr) {
if (NULL == descr)
flashrom-623.patch
Description: Binary data
-- coreboot mailing list: [email protected] http://www.coreboot.org/mailman/listinfo/coreboot

