move i2c init and get_hw_rev before clocks_init because the clock init code needs...
authormatt <matt@221aa14e-8319-0410-a670-987f0aec2ac5>
Mon, 25 May 2009 19:32:23 +0000 (19:32 +0000)
committermatt <matt@221aa14e-8319-0410-a670-987f0aec2ac5>
Mon, 25 May 2009 19:32:23 +0000 (19:32 +0000)
git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@11122 221aa14e-8319-0410-a670-987f0aec2ac5

usrp2/firmware/lib/u2_init.c

index 713b2c3218695ac7000f28c02373edb10aef9c95..9a1eb16512cb9ec9e2ab41b8a28b18795ee19ff4 100644 (file)
@@ -65,6 +65,10 @@ u2_init(void)
   // init spi, so that we can switch over to the high-speed clock
   spi_init();
 
+  // init i2c so we can read our rev
+  i2c_init();
+  get_hw_rev();
+
   // set up the default clocks
   clocks_init();
 
@@ -97,13 +101,10 @@ u2_init(void)
 
   pic_init();  // progammable interrupt controller
   bp_init();   // buffer pool
-  i2c_init();
   lsadc_init();            // low-speed ADCs
   lsdac_init();            // low-speed DACs
   db_init();       // daughterboard init
   
-  get_hw_rev();
-
   hal_enable_ints();
 
   // flash all leds to let us know board is alive