簡易檢索 / 詳目顯示

研究生: 黃若鵬
Wong, Ro-Pun
論文名稱: 運用虛擬機器(QEMU)設計之電子系統層級系統模擬平台
A QEMU-Based Electronic System Level System Simulation Platform
指導教授: 陳中和
Chen, Chung-Ho
學位類別: 碩士
Master
系所名稱: 電機資訊學院 - 電腦與通信工程研究所
Institute of Computer & Communication Engineering
論文出版年: 2008
畢業學年度: 96
語文別: 英文
論文頁數: 81
中文關鍵詞: 系統模擬平台電子系統層級網路卸載軟硬體整合設計
外文關鍵詞: electronic system level, full system simulation platform, software-hardware co-design, network offload
相關次數: 點閱:115下載:2
分享至:
查詢本校圖書館目錄 查詢臺灣博碩士論文知識加值系統 勘誤回報
  • 本篇論文提出一套能進行軟硬體協同設計的系統模擬平台。此平台結合虛擬機器與電子系統層級的開發軟體,使設計人員能夠以電子系統層級的方式來開發嵌入式ARM系統,與桌上型系統的PCI介面硬體,並且執行Linux作業系統。設計人員也能夠在硬體開發的初期,開發硬體的驅動程式與應用程式,並進一步評估系統的效能。

    我們利用此平台實現兩種不同型式的系統。第一種系統是實現一個卸載複雜運算的嵌入式ARM環境,以MD5為範例進行。第二種系統是在桌上型環境中,將網路協定卸載於硬體以建構高速網路的環境。設計有效率的網路卸載環境是相當複雜的議題,其牽涉到硬體架構設計,以及硬體、驅動程式與作業系統之間的溝通機制。因此我們先對網路傳輸與接收的流程進行完整的分析,並提出以及實作一套與作業系統的溝通機制。接著整合網路卸載引擎與驅動程式,並將系統連結到真實的網路環境。最後建立一個網路的應用,以SCTP的協定執行一套FTP軟體。

    A full system simulation platform is proposed in this thesis. The platform is designed by combining a virtual machine and an electronic system level integrated development environment. Through this platform, we can design a hardware system in an ARM environment or a PCI card in an x86 environment at the electronic system level, boot and run a Linux operating system, and design device drivers and applications as soon as a prototype in hardware is designed. We can also analyze the system performance at a relatively early stage.

    We have made two case studies with this platform. First, we have offloaded the design of MD5, which is a complex and computational intensive operation in IPsec, in hardware, and designed a device driver, as well as an application to use this hardware. Second, we have developed a network offload environment with this platform. Since developing an efficient network offload environment is a relatively complicated issue, which is related to both the hardware architecture and the kernel communication mechanism between the device driver and the hardware, a complete analysis on the network flow is made, and a communication mechanism is proposed and implemented. We integrated the network offload engine and the device driver, and developed a network example that connects the real world network to our platform, running an FTP application using SCTP protocol.

    Chapter 1 Introduction 1 1.1 Motivation & Contribution 1 1.2 Organization of Thesis 2 Chapter 2 Background and Related Work 3 2.1 Full System Simulation Platform 3 2.1.1 Simics: A Full System Simulation Platform 4 2.1.2 The M5 Simulator: Modeling Networked System 5 2.2 Electronic System Level Design 6 2.2.1 Transaction Level Modeling & Event Driven Modeling 6 2.2.2 SystemC 7 2.2.3 CoWare Platform Architect & ARM SoC Designer 7 2.3 QEMU & QEMU-SystemC 8 2.3.1 QEMU 8 2.3.2 QEMU-systemC 9 2.4 Linux Device Driver 9 2.4.1 Read/write I/O registers & I/O memories 10 2.4.2 Interrupt handling & polling 11 2.4.3 Kernel support to Direct Memory Access (DMA). 11 2.4.4 PCI bus interface 12 2.5 Related Work 12 2.5.1 Studying Network Protocol Offload with Emulation 13 2.5.2 Analyzing the Benefit of Protocol Offload by Full-system Simulation 15 2.5.3 Discussion on these Researches 15 Chapter 3 Proposed System Simulation Platform 17 3.1 Architecture of the Simulation Platform 17 3.2 The Simulation Environment Analysis 17 3.3 The Simulation Environment Scenarios 18 3.3.1 Embedded ARM Environment Booting Linux 18 3.3.2 Embedded Multi-core ARM Environment Booting Linux 19 3.3.3 x86 Computer System With PCI Card 20 3.4 Fundamental Building Blocks for this Platform 21 3.4.1 Interrupt Mechanism 21 3.4.2 AHB Interface & AHB Master (ARM Only) 22 3.4.3 PCI Interface & PCI-AHB Bridge (x86 Only) 23 Chapter 4 A Network Offload Environment 31 4.1 Socket Programming 32 4.2 Linux Kernel Network Internals 34 4.3 A Typical Network Flow 35 4.3.1 Frame Send Flow 36 4.3.2 Frame Receive Flow 37 4.3.3 Communication Mechanism for Offload Engine & Kernel 37 4.4 The Possible Architectures for our Network Offload Engine 38 Chapter 5 A Network Offload Simulation Platform 41 5.1 The Network Offload Simulation Platform 41 5.2 The Emulated Network Layer & Device Driver 42 5.2.1 The Design Architecture for the Emulated Network Layer 43 5.2.2 The Device Driver Design 43 5.3 PCI Virtual Interface in QEMU 44 5.3.1 PCI Configuration 44 5.3.2 Interrupt service 44 5.3.3 DMA service 45 5.4 Network Offload Engine 45 5.4.1 Stream Control Transmission Protocol (SCTP) Offload 45 5.4.2 IP & MAC Module 47 5.5 Network Offload Engine Transfer Flow 54 5.5.1 Client Connect Flow 55 5.5.2 Server Connection Flow 56 5.5.3 Send Flow 58 5.5.4 Receive Flow 59 5.5.5 End Connection Flow 60 Chapter 6 Implementation Issues 61 6.1 QEMU & CoWare 61 6.2 CoWare & the Real World Network 62 Chapter 7 Platform Demonstration 65 7.1 MD5 Calculation Offload in an Embedded System 65 7.2 MD5 Calculation Offload in a Desktop System 68 7.3 The Network Offload Scenario 70 7.3.1 The Environment of our Network Offload Scenario 70 7.3.2 The Network Offload Flow 71 Chapter 8 Conclusions and Future Work 75 8.1 Conclusion 75 8.2 Future Work 75

    [1] S. Gill, ”The Diagnosis of Mistakes in Programmes on the EDSAC,” Proceeding of Royal Society Series A, Mathematical and Physical Sciences, Cambridge Univ. Press, Cambridge, UK, vol. 206, pp. 538-554, 1951.
    [2] P. S. Magnusson, M. Christensson, J. Eskilson, D. Forsgren, G. Hallberg, J. Hogberg, F. Larsson, A. Moestedt and B. Werner, “Simics: A Full System Simulation Platform,” IEEE Computer, vol. 35, Iss. 2, pp. 50-58, Feb. 2002.
    [3] N. L. Binkert, R. G. Dreslinski, L. R. Hsu, K. T. Lim, A. G. Saidi and S. K. Reinhardt, “The M5 Simulator: Modeling Networked Systems,” IEEE Micro, vol. 26, Iss. 4, pp. 52-60, Jul.-Aug. 2006.
    [4] D. Gajski and L. Cai, ”Transaction Level Modeling: An Overview,” HW/SW Co-Design Conference (CODES), pp.19-24, Oct. 2003.
    [5] D. C. Black and J. Donovan, “SystemC: From the Ground Up,” Ekletic Ally, Inc., 2004.
    [6] CoWare, ConvergenSC Training Manual rev: 1Mar06, CoWare, Inc., 2006.
    [7] B. Fabrice, “QEMU, a Fast and Portable Dynamic Translator,” Proceeding of USENIX Annual Technical Conference, pp. 41-46, 2005.
    [8] QEMU-SystemC, GreenSocs, http://www.greensocs.com/projects/QEMUSystemC.
    [9] J. Corbet, A. Rubini and G. Kroah-Hartman, “Linux Device Driver,” 3rd edition, O’reilly, Feb. 2005.
    [10] J. Mogul and K.K. Ramakrishnan, “Eliminating Receive Livelock in an Interrupt-driven Kernel,” ACM Transaction on Computer Systems, vol. 15, Iss. 3, pp. 217-252, Aug. 1997.
    [11] B. Moore, T. Slabach and L. Schaelicke, “Profiling Interrupt Handler Performance through Kernel Instrumentation,” Proceeding of the 21st International Conference on Computer Design, pp. 156-163, Oct. 2003.
    [12] J. H. Salim, R. Olsson and A. Kuznetsov, “Beyond Softnet,” Proceeding of the 5th Annual Linux Showcase & Conference, pp. 165-172, 2001.
    [13] G. Regnier, S. Makineni, R. Illikkal, R. Iyer, D. Minturn, R. Huggahalli, D. Newell, L. Cline and A. Foong, “TCP Onload for Data Center Servers,” IEEE Computer, pp. 48-58, Nov. 2004.
    [14] R. Westrelin, N. Fugier, E. Nordmark, K. Kunze and E. Lemoine, “Studying Network Protocol Offload With Emulation: Approach And Preliminary Results,” Proceeding of the 12th Annual IEEE Symposium on High Performance Interconnects, pp. 84-90, 2004.
    [15] Sun Fire v480 Server, http://www.sun.com/servers/midrange/v480/.
    [16] Altera PCI compiler, http://www.altera.com/products/ip/iup/pci/m-alt-pci_mt32.html.
    [17] A. Ortiz, J. Ortega, A. F. Diaz and A. Prieto, “Analyzing The Benefits of Protocol Offload by Full-system Simulation,” the 15th EUROMICRO International Conference on Parallel, Distributed and Network-Based Processing, pp. 229-237, 2007.
    [18] Y. Murayama, “The analysis of TCP/IP,” 2nd edition, New Wun Ching Developmental Publishing, 2007.
    [19] S. Oh and S. Kim, “An Efficient Linux Kernel Module supporting TCP/IP Offload Engine on Grid,” Proceeding of the 5th International Conference on Grid and Cooperative Computing, pp. 228-235, Oct. 2006.
    [20] D. Kang, C. Kim, K. Kim and S. Jung, “Design and Implementation of Kernel S/W for TCP/IP Offload Engine(TOE),” The 7th International Conference on Advanced Communication Technology, vol. 1, pp. 706-709, 2005.
    [21] A 10 Gigabit Programmable Network Interface Card – How NICs Work, http://www.ece.rice.edu/~willmann/teng_nics_hownicswork.html#ev_model.
    [22] P. Chan, “An iWARP-Based TCP/IP Offload Engine,” Master’s Thesis, Dept. of Computer and Communication Engineering, National Cheng Kung University, 2006.
    [23] S. Chung, C. Li, H. Lee, J. Li, Y. Tsai and C. Chen, “Design and Implementation of the High Speed TCP/IP Offload Engine,” International Symposium on communications and Information Technologies, pp. 574-579, Oct. 2007.
    [24] W. Wang, J. Wang and J. Li, “Study on Enhanced Strategies for TCP/IP Offload Engine,” Proceedings of the 11th International Conference on Parallel and Distributed Systems, vol. 1, pp. 398-404, Jul. 2005.
    [25] W. J. Chen, ”A Scalable Architecture for Stream Control Transmission Protocol (SCTP) Offload”, Master’s Thesis, Dept. of Computer and Communication Engineering, National Cheng Kung University, 2008.
    [26] B. A. Forouzan and S. C. Fegan, “TCP/IP Protocol Suite,” 3rd edition, McGraw-Hill Publishing, 2005.
    [27] B. A. Forouzan, “Local Area Networks,” 1st edition, McGraw-Hill Publishing, 2003.
    [28] On-line CRC calculation and free library, http://www.lammertbies.nl/comm/info/crc-calculation.html.
    [29] A brief programming tutorial in C for raw sockets, http://mixter.void.ru/rawip.html.

    下載圖示 校內:2010-08-19公開
    校外:2010-08-19公開
    QR CODE