I.MX Linux® Reference Manual

Total Page:16

File Type:pdf, Size:1020Kb

I.MX Linux® Reference Manual i.MX Linux® Reference Manual Document Number: IMXLXRM Rev. 0, 10/2016 i.MX Linux® Reference Manual, Rev. 0, 10/2016 2 NXP Semiconductors Contents Section number Title Page Chapter 1 About this Book 1.1 Audience....................................................................................................................................................................... 29 1.1.1 Conventions................................................................................................................................................... 29 1.1.2 Definitions, Acronyms, and Abbreviations....................................................................................................29 Chapter 2 Introduction 2.1 Overview.......................................................................................................................................................................33 2.1.1 Software Base................................................................................................................................................ 34 2.1.2 Features.......................................................................................................................................................... 34 Chapter 3 Machine-Specific Layer (MSL) 3.1 Introduction...................................................................................................................................................................39 3.2 Interrupts (Operation)................................................................................................................................................... 40 3.2.1 Interrupt Hardware Operation........................................................................................................................40 3.2.2 Interrupt Software Operation......................................................................................................................... 40 3.2.3 Interrupt Features........................................................................................................................................... 41 3.2.4 Interrupt Source Code Structure.................................................................................................................... 41 3.2.5 Interrupt Programming Interface................................................................................................................... 42 3.3 Interrupts.......................................................................................................................................................................42 3.3.1 Interrupt Hardware Operation 3780,MX28................................................................................................... 42 3.3.2 Interrupt Software Operation 3780, MX28....................................................................................................43 3.3.3 Interrupt Requirements.................................................................................................................................. 43 3.3.4 Interrupt Source Code Structure Implementation.......................................................................................... 43 3.3.5 Interrupt Programming Interface, 3780, MX28............................................................................................. 44 3.3.6 Interrupt Unit Test..........................................................................................................................................44 3.4 Timer.............................................................................................................................................................................44 3.4.1 Timer Hardware Operation............................................................................................................................ 45 i.MX Linux® Reference Manual, Rev. 0, 10/2016 NXP Semiconductors 3 Section number Title Page 3.4.2 Timer Hardware Operation 3780, MX28.......................................................................................................45 3.4.3 Timer Software Operation............................................................................................................................. 46 3.4.4 Timer Features............................................................................................................................................... 46 3.4.5 Timer Source Code Structure.........................................................................................................................46 3.4.6 Timer Programming Interface 3780...............................................................................................................46 3.4.7 Timer Programming Interface........................................................................................................................46 3.4.8 Timer Programming Interface........................................................................................................................47 3.4.9 Timer Unit Test..............................................................................................................................................47 3.5 Memory Map................................................................................................................................................................ 47 3.5.1 Memory Map Hardware Operation................................................................................................................47 3.5.2 Memory Map Software Operation................................................................................................................. 47 3.5.3 Memory Map Features................................................................................................................................... 48 3.5.4 Memory Map Source Code Structure............................................................................................................ 48 3.6 IOMUX.........................................................................................................................................................................49 3.6.1 IOMUX Hardware Operation........................................................................................................................ 49 3.6.2 IOMUX Software Operation..........................................................................................................................50 3.6.3 IOMUX Features............................................................................................................................................50 3.6.4 IOMUX Source Code Structure.....................................................................................................................50 3.6.5 IOMUX Programming Interface....................................................................................................................51 3.6.6 IOMUX Control Through GPIO Module...................................................................................................... 51 3.6.6.1 GPIO Hardware Operation...........................................................................................................51 3.6.6.1.1 Muxing Control...........................................................................................................51 3.6.6.1.2 PULLUP Control........................................................................................................ 52 3.6.6.2 GPIO Software Operation (general)............................................................................................ 52 3.6.6.3 GPIO Implementation.................................................................................................................. 52 3.7 General Purpose Input/Output(GPIO).......................................................................................................................... 52 3.7.1 GPIO Software Operation..............................................................................................................................52 3.7.1.1 API for GPIO............................................................................................................................... 53 3.7.2 GPIO Features................................................................................................................................................53 i.MX Linux® Reference Manual, Rev. 0, 10/2016 4 NXP Semiconductors Section number Title Page 3.7.3 GPIO Module Source Code Structure............................................................................................................53 3.7.4 GPIO Programming Interface 2..................................................................................................................... 54 Chapter 4 Smart Direct Memory Access (SDMA) API 4.1 Overview.......................................................................................................................................................................55 4.1.1 Hardware Operation.......................................................................................................................................55 4.1.2 Software Operation........................................................................................................................................ 55 4.1.3 Source Code Structure................................................................................................................................... 56 4.1.4 Programming Interface.................................................................................................................................
Recommended publications
  • The Linux Kernel Module Programming Guide
    The Linux Kernel Module Programming Guide Peter Jay Salzman Michael Burian Ori Pomerantz Copyright © 2001 Peter Jay Salzman 2007−05−18 ver 2.6.4 The Linux Kernel Module Programming Guide is a free book; you may reproduce and/or modify it under the terms of the Open Software License, version 1.1. You can obtain a copy of this license at http://opensource.org/licenses/osl.php. This book is distributed in the hope it will be useful, but without any warranty, without even the implied warranty of merchantability or fitness for a particular purpose. The author encourages wide distribution of this book for personal or commercial use, provided the above copyright notice remains intact and the method adheres to the provisions of the Open Software License. In summary, you may copy and distribute this book free of charge or for a profit. No explicit permission is required from the author for reproduction of this book in any medium, physical or electronic. Derivative works and translations of this document must be placed under the Open Software License, and the original copyright notice must remain intact. If you have contributed new material to this book, you must make the material and source code available for your revisions. Please make revisions and updates available directly to the document maintainer, Peter Jay Salzman <[email protected]>. This will allow for the merging of updates and provide consistent revisions to the Linux community. If you publish or distribute this book commercially, donations, royalties, and/or printed copies are greatly appreciated by the author and the Linux Documentation Project (LDP).
    [Show full text]
  • Version 7.8-Systemd
    Linux From Scratch Version 7.8-systemd Created by Gerard Beekmans Edited by Douglas R. Reno Linux From Scratch: Version 7.8-systemd by Created by Gerard Beekmans and Edited by Douglas R. Reno Copyright © 1999-2015 Gerard Beekmans Copyright © 1999-2015, Gerard Beekmans All rights reserved. This book is licensed under a Creative Commons License. Computer instructions may be extracted from the book under the MIT License. Linux® is a registered trademark of Linus Torvalds. Linux From Scratch - Version 7.8-systemd Table of Contents Preface .......................................................................................................................................................................... vii i. Foreword ............................................................................................................................................................. vii ii. Audience ............................................................................................................................................................ vii iii. LFS Target Architectures ................................................................................................................................ viii iv. LFS and Standards ............................................................................................................................................ ix v. Rationale for Packages in the Book .................................................................................................................... x vi. Prerequisites
    [Show full text]
  • Linux for Zseries: Device Drivers and Installation Commands (March 4, 2002) Summary of Changes
    Linux for zSeries Device Drivers and Installation Commands (March 4, 2002) Linux Kernel 2.4 LNUX-1103-07 Linux for zSeries Device Drivers and Installation Commands (March 4, 2002) Linux Kernel 2.4 LNUX-1103-07 Note Before using this document, be sure to read the information in “Notices” on page 207. Eighth Edition – (March 2002) This edition applies to the Linux for zSeries kernel 2.4 patch (made in September 2001) and to all subsequent releases and modifications until otherwise indicated in new editions. © Copyright International Business Machines Corporation 2000, 2002. All rights reserved. US Government Users Restricted Rights – Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. Contents Summary of changes .........v Chapter 5. Linux for zSeries Console || Edition 8 changes.............v device drivers............27 Edition 7 changes.............v Console features .............28 Edition 6 changes ............vi Console kernel parameter syntax .......28 Edition 5 changes ............vi Console kernel examples ..........28 Edition 4 changes ............vi Usingtheconsole............28 Edition 3 changes ............vii Console – Use of VInput ..........30 Edition 2 changes ............vii Console limitations ............31 About this book ...........ix Chapter 6. Channel attached tape How this book is organized .........ix device driver ............33 Who should read this book .........ix Tapedriverfeatures...........33 Assumptions..............ix Tape character device front-end........34 Tape block
    [Show full text]
  • Copyright Disclaimer Federal Communications Commission (FCC
    Copyright © Copyright 2004. All rights reserved. No part of this publication may be reproduced, transmitted, transcribed, stored in a retrieval system, or translated into any language or computer language, in any form or by any means, electronic, mechanical, magnetic, optical, chemical, manual or otherwise, without the prior written permission of our company. All brand and product names are trademarks and/or registered trademarks of their respective holders. Disclaimer We make no representations or warranties, either expressed or implied, with respect to the contents hereof and specifically disclaims any warranties, merchantability or fitness for any particular purpose. Any software described in this manual is sold or licensed “as is”. Should the programs prove defective following their purchase, the buyer (and not our company., its distributor, or its dealer) assumes the entire cost of all necessary servicing, repair, and any incidental or consequential damages resulting from any defect in the software. Further, we reserve the right to revise this publication and to make changes from time to time in the contents hereof without obligation to notify any person of such revision or changes. Federal Communications Commission (FCC) Statement This equipment has been tested and found to comply with the limits for a class B device, pursuant to part 15 of the FCC rules. These limits are designed to provide reasonable protection against harmful interference in residential installation. This equipment generates, uses, and can radiate radio frequency energy and, if not installed and used in accordance with the instructions may cause harmful interference to radio communications. However, there is no guarantee that interference will not occur in a particular installation.
    [Show full text]
  • Linux Kernel and Driver Development Training Slides
    Linux Kernel and Driver Development Training Linux Kernel and Driver Development Training © Copyright 2004-2021, Bootlin. Creative Commons BY-SA 3.0 license. Latest update: October 9, 2021. Document updates and sources: https://bootlin.com/doc/training/linux-kernel Corrections, suggestions, contributions and translations are welcome! embedded Linux and kernel engineering Send them to [email protected] - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 1/470 Rights to copy © Copyright 2004-2021, Bootlin License: Creative Commons Attribution - Share Alike 3.0 https://creativecommons.org/licenses/by-sa/3.0/legalcode You are free: I to copy, distribute, display, and perform the work I to make derivative works I to make commercial use of the work Under the following conditions: I Attribution. You must give the original author credit. I Share Alike. If you alter, transform, or build upon this work, you may distribute the resulting work only under a license identical to this one. I For any reuse or distribution, you must make clear to others the license terms of this work. I Any of these conditions can be waived if you get permission from the copyright holder. Your fair use and other rights are in no way affected by the above. Document sources: https://github.com/bootlin/training-materials/ - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 2/470 Hyperlinks in the document There are many hyperlinks in the document I Regular hyperlinks: https://kernel.org/ I Kernel documentation links: dev-tools/kasan I Links to kernel source files and directories: drivers/input/ include/linux/fb.h I Links to the declarations, definitions and instances of kernel symbols (functions, types, data, structures): platform_get_irq() GFP_KERNEL struct file_operations - Kernel, drivers and embedded Linux - Development, consulting, training and support - https://bootlin.com 3/470 Company at a glance I Engineering company created in 2004, named ”Free Electrons” until Feb.
    [Show full text]
  • El Núcleo Linux
    El núcleo Linux Josep Jorba Esteve PID_00174426 GNUFDL • PID_00174426 El núcleo Linux Índice Introducción ................................................... ....... 5 Objetivos ................................................... ............ 6 1. El núcleo del sistema GNU/Linux .............................. 7 2. Personalización o actualización del núcleo................... 15 3. Proceso de configuración y compilación ...................... 18 3.1. Compilación antigua de la rama 2.4.x del núcleo . 20 3.2. Migración de 2.4 a la rama 2.6.x del núcleo. 25 3.3. Compilación de la rama 2.6.x del núcleo . 27 3.4. Compilación del núcleo en Debian (Debian Way)............. 30 4. Aplicación de parches al núcleo ................................ 35 5. Módulos del núcleo ............................................... 38 5.1. DKMS: módulos recompilados dinámicamente . 41 6. Virtualización en el núcleo ..................................... 44 6.1. KVM ............................................ .............. 46 7. Futuro del núcleo y alternativas ............................... 53 8. Taller de configuración del núcleo a las necesidades del usuario................................................... ...... 58 8.1. Configuración del núcleo en Debian . 58 8.2. Configuración del núcleo en Fedora/Red Hat . 61 8.3. Configuración de un núcleo genérico . 63 Resumen ................................................... ............ 66 Actividades ................................................... ......... 67 Bibliografía ..................................................
    [Show full text]
  • Enabling Hardware Accelerated Video Decode on Intel® Atom™ Processor D2000 and N2000 Series Under Fedora 16
    Enabling Hardware Accelerated Video Decode on Intel® Atom™ Processor D2000 and N2000 Series under Fedora 16 Application Note October 2012 Order Number: 509577-003US 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”.
    [Show full text]
  • Practical Practical
    PRACTICAL PRACTICAL GPLCOMPLIANCE GPLCOMPLIANCE A GUIDE FOR STARTUPS, SMALL ABUSINESSES GUIDE FOR STARTUPS, AND ENGINEERS SMALL BUSINESSES AND ENGINEERS ARMIJN HEMEL, MSC AND SHANE COUGHLAN ARMIJN HEMEL, MSC AND SHANE COUGHLAN Copyright © 2017 Linux Foundation All rights reserved. This book or any portion thereof may not be reproduced or used in any manner whatsoever without the express written permission of the publisher except for the use of brief quotations in a book review and certain other noncommercial uses permitted by copyright law. Printed in the United States of America First Edition, 2017 ISBN: 978-0-9989078-0-2 1 Letterman Drive Building D Suite D4700 San Francisco CA 94129 Phone/Fax: +1 415 723 9709 https://linuxfoundation.org About the Authors Shane Coughlan Shane Coughlan is an expert in communi- cation, security, and business development. His professional accomplishments include spearheading the licensing team that elevated Open Invention Network into the largest patent non-aggression community in history, establishing the leading professional network of open source legal experts, and aligning stakeholders to launch both the first law journal and the first law book dedicated to open source. He currently leads the OpenChain community as Program Manager. Shane has extensive knowledge of open source governance, internal process development, supply chain management, and community building. His experience includes engagement with the enterprise, embedded, mobile, and automotive industries. Armijn Hemel Armijn Hemel is the owner of Tjaldur Software Governance Solutions. He is an active re- searcher of and internationally recognized expert in open source license compliance and supply chain management. He studied computer science at Utrecht University in The Netherlands, where he pioneered reproducible builds with NixOS.
    [Show full text]
  • Compiling Your Own Kernel Getting the Kernel Configuring the Kernel
    Williams College Meeting 4 Compiling Your Own Kernel In this meeting, we will use several tools to: • download the latest stable kernel • customize the kernel config file • compile the kernel and kernel modules • set the default system kernel to be a kernel of your choosing • explore the kernel source code using the LXR Cross Referencer Getting the Kernel The kernel source code is available at kernel.org. On the main page, there is a big yellow box that says Latest Stable Kernel. It may be tempting to press that button. Resist the urge: clicking that link will download the latest stable kernel as a compressed “tarball”. A tarball is good for today, but we don’t want to live in the present. The kernel source is actively developed by a heterogeneous community of developers, with updates and changes managed using git. We want to get the Linux source using git so that we can access the history of old kernel versions, as well as access new releases when they are published. Step one for today’s meeting is to find the “mainline” Linux source’s git repository. • Where is mainline kernel’s git repository? What are the meanings of the following terms (in relationship to the Linux development process), and how are they represented in the Linux git repository? • mainline • longterm • stable • prepatch (Hint: Use git to clone this repository to a directory called linux-stable-src/, and explore the git repository using git-log, git-branch, and git-tag.) • Now execute the command: $ uname -r What is the output? • What is a “distribution” kernel? • Is your system using a mainline or distribution kernel? Configuring the Kernel There are many good online guides for building your kernel.
    [Show full text]
  • Working with Kernel Modules Lab
    Working with Kernel Modules Lab © 2013 Wind River Systems, Inc Working with Kernel Modules Lab Objective In this lab, you will learn how to manage kernel modules in your projects, as well as how to develop new modules. NOTE: This lab should take approximately 60 minutes. Lab Overview Loadable kernel modules are the equivalent of shared libraries in user-space. They provide additional functionality to the kernel when required, without having to pay the penalty in terms of memory (and boot-time) when the module is not in use. They are particularly useful for implementing device drivers and file systems, where compiling support for every type of file system or device statically into the kernel would be prohibitive. In this lab, you will learn how to do the following: configure the kernel build to add/remove modules load/unload modules on the target develop new modules Before You Begin This lab modifies the kernel source of an existing platform project. Use the pre-built project provided with your lab environment. Refer to the Getting Started lab to identify where to find this project in your lab environment. The location of this project will be referenced as $TARGET_BASE throughout this lab. This lab uses a command-line environment. Take the time now to open a command-line terminal and navigate to this directory. Managing Modules in the Kernel Build In this section, you will modify your kernel configuration to include a new feature which was previously disabled. This feature will be enabled as a module. The feature chosen for this exercise is the NILFS2 file system, which would enable your target to mount a file system formatted using NILFS2.
    [Show full text]
  • We've Got Bugs, P
    Billix | Rails | Gumstix | Zenoss | Wiimote | BUG | Quantum GIS LINUX JOURNAL ™ REVIEWED: Neuros OSD and COOL PROJECTS Cradlepoint PHS300 Since 1994: The Original Magazine of the Linux Community AUGUST 2008 | ISSUE 172 WE’VE GOT Billix | Rails Gumstix Zenoss Wiimote BUG Quantum GIS MythTV BUGs AND OTHER COOL PROJECTS TOO E-Ink + Gumstix Perfect Billix Match? Kiss Install CDs Goodbye AUGUST How To: 16 Terabytes in One Case www.linuxjournal.com 2008 $5.99US $5.99CAN 08 ISSUE Learn to Fake a Wiimote Linux 172 + UFO Landing Video Interface HOW-TO 0 09281 03102 4 AUGUST 2008 CONTENTS Issue 172 FEATURES 48 THE BUG: A LINUX-BASED HARDWARE MASHUP With the BUG, you get a GPS, camera, motion detector and accelerometer all in one hand-sized unit, and it’s completely programmable. Mike Diehl 52 BILLIX: A SYSADMIN’S SWISS ARMY KNIFE Build a toolbox in your pocket by installing Billix on that spare USB key. Bill Childers 56 FUN WITH E-INK, X AND GUMSTIX Find out how to make standard X11 apps run on an E-Ink display using a Gumstix embedded device. Jaya Kumar 62 ONE BOX. SIXTEEN TRILLION BYTES. Build your own 16 Terabyte file server with hardware RAID. Eric Pearce ON THE COVER • Neuros OSD, p. 44 • Cradlepoint PHS300, p. 42 • We've got BUGs, p. 48 • E-Ink + Gumstix—Perfect Match?, p. 56 • How To: 16 Terabytes in One Case, p. 62 • Billix—Kiss Install CDs Goodbye, p. 52 • Learn to Fake a UFO Landing Video, p. 80 • Wiimote Linux Interface How-To, p. 32 2 | august 2008 www.linuxjournal.com lj026:lj018.qxd 5/14/2008 4:00 PM Page 1 The Straight Talk People
    [Show full text]
  • How to Use This Manual Page I
    How to Use Pages.qxd 3/12/03 4:31 PM Page 1 LaCie Pocket CDRW User’s Manual How to Use This Manual page i How to Use This Manual In the toolbar: Previous Page / Next Page Go to Previous View / Go to Next View Go to Contents Page / Go to Precautions Page On the page: Click on the text within the Contents page to jump to information on that topic. Click on any red text to automatically jump to more information about that topic. Printing: While optimized for onscreen viewing, the pages of this manual are formatted for printing on 8 1/2” x 11” and A4 sized paper, giving you the option to print the entire manual or just a specific page or section. To Exit: From the Menu bar at the top of your screen, select: File > Quit. UG_pocketCDRW_FW030210.qxd 3/12/03 3:34 PM Page 1 LaCie Pocket CDRW User’s Manual Foreword page 1 Copyrights Copyright © 2003 LaCie. All rights reserved. No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, electronic, mechanical, photocopying, recording or otherwise, without the prior written consent of LaCie. Trademarks Apple, Mac, Macintosh and FireWire are registered trademarks of Apple Computer, Inc. Sony and iLink are registered trade- marks of Sony Electronics. Microsoft, Windows, Windows 98 SE, Windows Millennium Edition, Windows 2000 and Windows XP are registered trademarks of Microsoft Corporation. All trademarks mentioned in this manual are the property of their respective owners. Changes The material in this document is for information only and is subject to change without notice.
    [Show full text]