
Dear Mike Frysinger,
In message 1326670329-18644-1-git-send-email-vapier@gentoo.org you wrote:
All arches init these variables the same way, so move the logic into the core net code to avoid duplicating it everywhere else.
This is the wrong approach.
There are many more ieces of code in arch/*/lib/board.c which are duplicated across some or all architectures. Instread of ripping these apart and fixing a bit here and a bit thre we should combine efforts and merge all arch/*/lib/board.c into a common file.
Additionally, your patch potentially breaks a number of boards.
index 3d78274..2c4276b 100644 --- a/arch/arm/lib/board.c +++ b/arch/arm/lib/board.c @@ -536,9 +536,6 @@ void board_init_r(gd_t *id, ulong dest_addr) arm_pci_init(); #endif
- /* IP Address */
- gd->bd->bi_ip_addr = getenv_IPaddr("ipaddr");
The code which you remove here does NOT depend on CONFIG_CMD_NET; note that this is intentional.
When moving this into net/eth.c, it will be missing for all oards that do not have CONFIG_CMD_NET defined.
So NAK.
Best regards,
Wolfgang Denk