Merge branch 'u-boot-ti/master' into 'u-boot-arm/master'
[platform/kernel/u-boot.git] / board / Marvell / db64460 / db64460.c
index 14e6355..ddb7ed5 100644 (file)
@@ -34,6 +34,7 @@
 #include "../include/mv_gen_reg.h"
 #include <net.h>
 #include <netdev.h>
+#include <linux/compiler.h>
 
 #include "eth.h"
 #include "mpsc.h"
@@ -410,7 +411,7 @@ int checkboard (void)
 void debug_led (int led, int mode)
 {
        volatile int *addr = 0;
-       int dummy;
+       __maybe_unused int dummy;
 
        if (mode == 1) {
                switch (led) {
@@ -833,15 +834,11 @@ int mem_test_walk (void)
 /*********************************************************************/
 int testdram (void)
 {
-       char *s;
        int rundata, runaddress, runwalk;
 
-       s = getenv ("testdramdata");
-       rundata = (s && (*s == 'y')) ? 1 : 0;
-       s = getenv ("testdramaddress");
-       runaddress = (s && (*s == 'y')) ? 1 : 0;
-       s = getenv ("testdramwalk");
-       runwalk = (s && (*s == 'y')) ? 1 : 0;
+       rundata = getenv_yesno("testdramdata") == 1;
+       runaddress = getenv_yesno("testdramaddress") == 1;
+       runwalk = getenv_yesno("testdramwalk") == 1;
 
 /*    rundata = 1; */
 /*    runaddress = 0; */
@@ -933,5 +930,9 @@ void board_prebootm_init ()
 
 int board_eth_init(bd_t *bis)
 {
-       return pci_eth_init(bis);
+       int ret;
+       ret = pci_eth_init(bis);
+       if (!ret)
+               ret = mv6446x_eth_initialize(bis);
+       return ret;
 }