From a0ba279ac6b6b83b48dee609d7a34fc29b520ebc Mon Sep 17 00:00:00 2001 From: Masahiro Yamada Date: Mon, 27 May 2013 00:37:30 +0000 Subject: generic_board: reduce the redundancy of gd_t struct members This commit refactors common/board_f.c and common/board_r.c in order to delete the dest_addr and dest_addr_sp from gd_t struct. As mentioned as follows in include/asm-generic/global_data.h, /* TODO: is this the same as relocaddr, or something else? */ unsigned long dest_addr; /* Post-relocation address of U-Boot */ dest_addr is the same as relocaddr. Likewise, dest_addr_sp is the same as start_addr_sp. It seemed dest_addr/dest_addr_sp was used only as a scratch variable to calculate relocaddr/start_addr_sp, respectively. With a little refactoring, we can delete dest_addr and dest_addr_sp. Signed-off-by: Masahiro Yamada Cc: Simon Glass --- include/asm-generic/global_data.h | 3 --- 1 file changed, 3 deletions(-) (limited to 'include/asm-generic') diff --git a/include/asm-generic/global_data.h b/include/asm-generic/global_data.h index 5416f468b0..3e9ca1182d 100644 --- a/include/asm-generic/global_data.h +++ b/include/asm-generic/global_data.h @@ -68,9 +68,6 @@ typedef struct global_data { unsigned long env_addr; /* Address of Environment struct */ unsigned long env_valid; /* Checksum of Environment valid? */ - /* TODO: is this the same as relocaddr, or something else? */ - unsigned long dest_addr; /* Post-relocation address of U-Boot */ - unsigned long dest_addr_sp; unsigned long ram_top; /* Top address of RAM used by U-Boot */ unsigned long relocaddr; /* Start address of U-Boot in RAM */ -- cgit v1.2.1