u-boot 相關問題與知識

來源:互聯網
上載者:User

1、用arm-linux-gcc 4.3.2 編譯 u-boot-1.1.6 出現 In function `__aeabi_ldiv0':
(.text+0x8): undefined reference to `raise'...

  編譯u-boot-1.1.6 使用
arm-linux-gcc 3.4.5即可。

   其他相關閱讀

   1) http://www.arm9home.net/simple/index.php?t1960.html

   2) http://kongweile.iteye.com/blog/1576113 (ABI與EABI)

 

2、#define DECLARE_GLOBAL_DATA_PTR     register volatile gd_t *gd asm ("r8")

     
這個聲明告訴編譯器使用寄存器r8來儲存gd_t類型的指標gd,即這個定義聲明了一個指標,並且指明了它的儲存位置。
       register表示變數放在機器的寄存器
       volatile用於指定變數的值可以由外部過程非同步修改

      並且這個指標在start_armboot()(board.c)中被初始化:
              /* Pointer is writable since we allocated a register for it */
              gd = (gd_t*)(_armboot_start - CFG_MALLOC_LEN - sizeof(gd_t));

       這樣,gd就指向的一個可用的記憶體位址了。

       原文:http://hi.baidu.com/rwen2012/item/783c47cf40d23427e80f2e51


3、__asm__ __volatile__("": : :"memory");

     這是GCC內嵌彙編,詳見:http://topic.csdn.net/u/20090521/11/35609357-57b9-4c7c-af6a-04a76eef49a3.html


       

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.