Intel® Quark™ Soc X1000 Software Developer's Manual for Linux*
Total Page:16
File Type:pdf, Size:1020Kb
Intel® Quark™ SoC X1000 Software Developer’s Manual for Linux* May 2014 Order Number: 330235-002US INFORMATIONLegal Lines and Disclaimers IN THIS DOCUMENT IS PROVIDED IN CONNECTION WITH INTEL PRODUCTS. NO LICENSE, EXPRESS OR IMPLIED, BY ESTOPPEL OR OTHERWISE, TO ANY INTELLECTUAL PROPERTY RIGHTS IS GRANTED BY THIS DOCUMENT. EXCEPT AS PROVIDED IN INTEL'S TERMS AND CONDITIONS OF SALE FOR SUCH PRODUCTS, INTEL ASSUMES NO LIABILITY WHATSOEVER AND INTEL DISCLAIMS ANY EXPRESS OR IMPLIED WARRANTY, RELATING TO SALE AND/OR USE OF INTEL PRODUCTS INCLUDING LIABILITY OR WARRANTIES RELATING TO FITNESS FOR A PARTICULAR PURPOSE, MERCHANTABILITY, OR INFRINGEMENT OF ANY PATENT, COPYRIGHT OR OTHER INTELLECTUAL PROPERTY RIGHT. A "Mission Critical Application" is any application in which failure of the Intel Product could result, directly or indirectly, in personal injury or death. SHOULD YOU PURCHASE OR USE INTEL'S PRODUCTS FOR ANY SUCH MISSION CRITICAL APPLICATION, YOU SHALL INDEMNIFY AND HOLD INTEL AND ITS SUBSIDIARIES, SUBCONTRACTORS AND AFFILIATES, AND THE DIRECTORS, OFFICERS, AND EMPLOYEES OF EACH, HARMLESS AGAINST ALL CLAIMS COSTS, DAMAGES, AND EXPENSES AND REASONABLE ATTORNEYS' FEES ARISING OUT OF, DIRECTLY OR INDIRECTLY, ANY CLAIM OF PRODUCT LIABILITY, PERSONAL INJURY, OR DEATH ARISING IN ANY WAY OUT OF SUCH MISSION CRITICAL APPLICATION, WHETHER OR NOT INTEL OR ITS SUBCONTRACTOR WAS NEGLIGENT IN THE DESIGN, MANUFACTURE, OR WARNING OF THE INTEL PRODUCT OR ANY OF ITS PARTS. Intel may make changes to specifications and product descriptions at any time, without notice. Designers must not rely on the absence or characteristics of any features or instructions marked "reserved" or "undefined". Intel reserves these for future definition and shall have no responsibility whatsoever for conflicts or incompatibilities arising from future changes to them. The information here is subject to change without notice. Do not finalize a design with this information. The products described in this document may contain design defects or errors known as errata which may cause the product to deviate from published specifications. Current characterized errata are available on request. Contact your local Intel sales office or your distributor to obtain the latest specifications and before placing your product order. Copies of documents which have an order number and are referenced in this document, or other Intel literature, may be obtained by calling 1-800-548- 4725, or go to: http://www.intel.com/design/literature.htm Any software source code reprinted in this document is furnished for informational purposes only and may only be used or copied and no license, express or implied, by estoppel or otherwise, to any of the reprinted source code is granted by this document. Intel processor numbers are not a measure of performance. Processor numbers differentiate features within each processor family, not across different processor families. Go to: http://www.intel.com/products/processor_number/ Code Names are only for use by Intel to identify products, platforms, programs, services, etc. (“products”) in development by Intel that have not been made commercially available to the public, i.e., announced, launched or shipped. They are never to be used as “commercial” names for products. Also, they are not intended to function as trademarks. Intel, the Intel logo, and Quark are trademarks of Intel Corporation in the U.S. and/or other countries. *Other names and brands may be claimed as the property of others. Copyright © 2014, Intel Corporation. All rights reserved. Intel® Quark™ SoC X1000 Software Developer’s Manual for Linux* May 2014 2 Order Number: 330235-002US Revision History—Intel® Quark™ SoC X1000 Revision History Date Revision Description Updates for software release 1.0.1 including: • Modified Section 4.6 to change driver name from “RS232+DMA” to “UART+DMA” to be May 2014 002 more clear. See changebars for details. • Updated with trademarked term: Intel® Quark™ SoC. March 2014 001 First public release of document. Intel® Quark™ SoC X1000 May 2014 Software Developer’s Manual for Linux* Order Number: 330235-002US 3 Intel® Quark™ SoC X1000—Contents Contents 1.0 Introduction ............................................................................................................. 7 1.1 About this Manual ............................................................................................... 7 1.2 Introduction....................................................................................................... 7 1.3 Related Documentation ....................................................................................... 7 1.4 Terminology....................................................................................................... 8 1.5 Conventions....................................................................................................... 8 2.0 Platform Overview .................................................................................................... 9 2.1 Platform Synopsis ............................................................................................... 9 2.2 SoC Features ....................................................................................................10 3.0 Software Overview ..................................................................................................11 3.1 High-Level Software Architecture Overview ...........................................................11 3.2 Linux* Support..................................................................................................12 3.2.1 Standard OS Drivers ...............................................................................12 3.2.2 Host Bridge OS Drivers............................................................................12 3.2.3 Bootloader Host Bridge Drivers .................................................................12 3.3 User-Space Software Dependencies......................................................................12 4.0 Intel® Quark™ SoC X1000 Drivers............................................................................13 4.1 Overview ..........................................................................................................13 4.2 USB OHCI Controller Interface Driver ...................................................................13 4.3 USB 2.0 EHCI Controller Interface Driver ..............................................................14 4.4 USB Device Interface Driver ................................................................................14 4.5 SD/MMC Controller Interface Driver......................................................................14 4.6 UART + DMA Interface Driver ..............................................................................15 4.7 SPI Interface Driver ...........................................................................................15 4.8 I2C* Interface Driver..........................................................................................16 4.9 GPIO Interface Driver.........................................................................................17 4.10 Ethernet Interface Driver (STMMAC).....................................................................17 4.10.1 VLAN ....................................................................................................18 5.0 Intel® Quark™ SoC X1000 Host Bridge Drivers.........................................................19 5.1 eSRAM Configuration Driver ................................................................................19 5.1.1 Example showing eSRAM stat usage..........................................................20 5.1.2 Example of mapping printk into eSRAM from user-space ..............................20 5.1.3 Kernel API Reference...............................................................................20 5.1.3.1 intel_qrk_esram_map_range ......................................................20 5.1.3.2 intel_qrk_esram_unmap_range...................................................21 5.1.3.3 intel_qrk_esram_map_symbol ....................................................21 5.1.3.4 intel_qrk_esram_unmap_symbol .................................................21 5.2 Isolated Memory Region Driver............................................................................21 5.2.1 IMR run-time kernel protection .................................................................22 5.3 Thermal Driver ..................................................................................................22 6.0 Legacy Block Driver .................................................................................................23 6.1 Legacy GPIO .....................................................................................................23 7.0 Expansion Drivers ....................................................................................................24 7.1 AD7298 Driver ..................................................................................................24 7.2 Bluetooth* Driver ..............................................................................................25 7.2.1 Device discovery.....................................................................................26 7.2.2 Service discovery....................................................................................26 7.2.3 Establish connection................................................................................26 Intel®