Difference between revisions of "CL-SOM-AM57x: Linux: Kernel"

From Compulab Mediawiki
Jump to: navigation, search
(See also)
(Wifi support)
Line 12: Line 12:
  
 
==== Snapshot download ====
 
==== Snapshot download ====
===== Mainline kernel v4.4 =====
+
===== Mainline kernel v4.4.21 =====
* Download [https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.4.tar.gz v4.4] snapshot with a web browser.
+
* Download [https://www.kernel.org/pub/linux/kernel/v4.x/linux-4.4.21.tar.gz v4.4.21] snapshot with a web browser.
 
* Extract the downloaded archive {{filename|linux-4.4.tar.gz}}
 
* Extract the downloaded archive {{filename|linux-4.4.tar.gz}}
 
<pre>
 
<pre>
 
cd /home/development/cl-som-am57x/kernel
 
cd /home/development/cl-som-am57x/kernel
tar xvf /path/to/downloaded/linux-4.4.tar.gz
+
tar xvf /path/to/downloaded/linux-4.4.21.tar.gz
mv linux-4.4 linux-cl-som-am57x
+
mv linux-4.4.21 linux-cl-som-am57x
 
</pre>
 
</pre>
 
: This will create {{filename|/home/development/cl-som-am57x/kernel/linux-cl-som-am57x}} directory containing linux kernel tree.
 
: This will create {{filename|/home/development/cl-som-am57x/kernel/linux-cl-som-am57x}} directory containing linux kernel tree.
Line 24: Line 24:
 
<pre>
 
<pre>
 
cd /home/development/cl-som-am57x/kernel/cl-som-am57x
 
cd /home/development/cl-som-am57x/kernel/cl-som-am57x
patch -p1 < /path/to/cl-som-am57x/kernel/linux-4.4-cl-som-am57x-3.0.patch
+
patch -p1 < /path/to/cl-som-am57x/kernel/kernel-v4.4/linux-4.4.21-cl-som-am57x-3.2.patch
 
</pre>
 
</pre>
 
===== TI SDK kernel v4.1.13 =====
 
===== TI SDK kernel v4.1.13 =====
Line 37: Line 37:
 
<pre>
 
<pre>
 
cd /home/development/cl-som-am57x/kernel/cl-som-am57x-ti
 
cd /home/development/cl-som-am57x/kernel/cl-som-am57x-ti
patch -p1 < /path/to/cl-som-am57x/kernel/ti-sdk-4.1.13/linux-4.1.13-cl-som-am57x-3.0.patch
+
patch -p1 < /path/to/cl-som-am57x/kernel/ti-sdk-4.1.13/linux-4.1.13-cl-som-am57x-ti-3.2.patch
 
</pre>
 
</pre>
 
==== Git clone ====
 
==== Git clone ====
 
* Install [http://git-scm.com/ git] version control system.
 
* Install [http://git-scm.com/ git] version control system.
===== Mainline kernel v4.4 =====
+
===== Mainline kernel v4.4.21 =====
 
* Create a clone of linux kernel tree
 
* Create a clone of linux kernel tree
 
<pre>
 
<pre>
 
cd /home/development/cl-som-am57x/kernel
 
cd /home/development/cl-som-am57x/kernel
git clone git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git linux-cl-som-am57x
+
git clone git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-cl-som-am57x
 
</pre>
 
</pre>
* Create a branch for CL-SOM-AM57x development. The CL-SOM-AM57x patches are generated vs. v4.4 tag (b5be40b90dbaa6bd337f3b77de361bfc0723468b commit) in the Linux tree. It is recommended to use exactly the same baseline to avoid merge conflicts.
+
* Create a branch for CL-SOM-AM57x development. The CL-SOM-AM57x patches are generated vs. v4.4.21 tag (1d074db69c46d62ce82b331c2080e2fcb710bf4a commit) in the Linux stable tree. It is recommended to use exactly the same baseline to avoid merge conflicts.
 
<pre>
 
<pre>
 
cd /home/development/cl-som-am57x/kernel/linux-cl-som-am57x
 
cd /home/development/cl-som-am57x/kernel/linux-cl-som-am57x
git checkout -b cl-som-am57x-dev v4.4
+
git checkout -b cl-som-am57x-dev v4.4.21
 
</pre>
 
</pre>
 
* Apply the CL-SOM-AM57x patch
 
* Apply the CL-SOM-AM57x patch
 
<pre>
 
<pre>
git apply /path/to/cl-som-am57x-linux/kernel/linux-4.4-cl-som-am57x-3.0.patch
+
git am /path/to/cl-som-am57x-linux/kernel/kernel-v4.4/patches/*.patch
 
</pre>
 
</pre>
  
Line 72: Line 72:
 
* Apply the CL-SOM-AM57x patch
 
* Apply the CL-SOM-AM57x patch
 
<pre>
 
<pre>
git apply /path/to/cl-som-am57x-linux/kernel/ti-sdk-4.1.13/linux-4.1.13-cl-som-am57x-3.0.patch
+
git am /path/to/cl-som-am57x-linux/kernel/ti-sdk-4.1.13/kernel/patches/*.patch
 
</pre>
 
</pre>
  
Line 92: Line 92:
  
 
When the CL-SOM-AM57x is booted with the kernel image and Device Tree binary created as described above and with networked root filesystem at {{filename|/home/development/cl-som-am57x/rootfs/}}, the system will be able to load the kernel modules properly, thus avoiding module version problems.
 
When the CL-SOM-AM57x is booted with the kernel image and Device Tree binary created as described above and with networked root filesystem at {{filename|/home/development/cl-som-am57x/rootfs/}}, the system will be able to load the kernel modules properly, thus avoiding module version problems.
 +
 +
=== Device Tree ===
 +
Device Tree (DT), is a data structure and language for describing hardware. More specifically, it is a description of hardware that is readable by an operating system so that the operating system doesn't need to hard code details of the machine.
 +
 +
A device tree file, named *.dts, is a text file that describes the hardware platform. It is compiled into a device tree blob, *.dtb, which is loaded into memory before the Linux kernel is started. The Linux kernel then uses that device tree blob to initialize itself at runtime.
 +
 +
==== CL-SOM-AM57x device tree organization ====
 +
The SBC-AM57x product is built from 3 major components:
 +
<pre>
 +
┌───────────────────────────────┐
 +
│ SB-SOM baseboard            │
 +
│                    │
 +
│  ┌─────────────────────┐  │
 +
│  │ CL-SOM-AM57x SoM   │    │
 +
│  │          │ │
 +
│  │  ┌──────────────┐  │ │
 +
│  │ │ TI AM57x SoC │  │ │
 +
│  │ └──────────────┘  │ │
 +
│  └─────────────────────┘ │
 +
└───────────────────────────────┘
 +
</pre>
 +
SBC-AM57x Device tree hierarchy reflects the hardware hierarchy:
 +
<pre>
 +
      dra74x.dtsi
 +
  ∧
 +
  │
 +
am57xx-cl-som-am57x.dts       compulab-sb-som.dtsi
 +
  ∧         ∧
 +
  └────────┐       ┌────────┘
 +
    │       │
 +
am57xx-sbc-am57x.dts
 +
</pre>
 +
 +
* {{filename | dra74x.dtsi}} is the SoC vendor device tree describing the dra74x SoC family.
 +
* {{filename | am57xx-cl-som-am57x.dts}} is the SoM vendor device tree describing the CL-SOM-AM57x SoM.
 +
* {{filename | compulab-sb-som.dtsi}} describes the SB-SOM baseboard. Only hardware properties that remain constant regardless of which SoM is installed on the baseboard are described here.
 +
* {{filename | am57xx-sbc-am57x.dts}} describes the integration between CL-SOM-AM57x SoM and the SB-SOM baseboard. Everything that is related to the SB-SOM baseboard and would change if we were to swap the CL-SOM-AM57x module with another SoM is described here. For example: SB-SOM contains TFP410, an RGB-to-DVI encoder. The encoder is located on an I2C bus, but depending on the installed SoC it might be i2c1, i2c2, or i2c3. Therefore, it is not described in the generic {{filename | compulab-sb-som.dtsi}} device tree, but in the device tree describing the SB-SOM/CL-SOM-AM57x combination. On the other hand, in order to describe the DVI connector on SB-SOM, there is no need to reference any SoM specific information, and therefore it is described in the generic {{filename | compulab-sb-som.dtsi}} file.
 +
 +
For more details visit official [http://devicetree.org/Device_Tree_Usage Device Tree WiKi] pages and make an overview of a [http://events.linuxfoundation.org/sites/events/files/slides/petazzoni-device-tree-dummies.pdf  Device Tree tutorial]
 +
 +
=== Kernel configuration ===
 +
 +
==== USB support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> USB support''' submenu and enable:
 +
* Support for Host-side USB
 +
* Enable USB persist by default
 +
* OTG support
 +
* xHCI HCD (USB 3.0) support
 +
* EHCI HCD (USB 2.0) support
 +
* DesignWare USB3 DRD Core Support
 +
  ┌─────────────────────────────── USB support ───────────────────────────────┐
 +
  │ ┌───────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      --- USB support                                                │ │
 +
  │ │      <*>  Support for Host-side USB                                │ │
 +
  │ │      [*]    USB announce new devices                                │ │
 +
  │ │              *** Miscellaneous USB options ***                      │ │
 +
  │ │      [*]    Enable USB persist by default                          │ │
 +
  │ │      [ ]    Dynamic USB minor allocation                            │ │
 +
  │ │      [*]    OTG support                                            │ │
 +
  │ │      ...                                                            │ │
 +
  │ │      <*>    xHCI HCD (USB 3.0) support                              │ │
 +
  │ │      -*-      Generic xHCI driver for a platform device            │ │ 
 +
  │ │      <*>    EHCI HCD (USB 2.0) support                              │ │
 +
  │ │      [*]      Root Hub Transaction Translators                      │ │
 +
  │ │      [ ]      Improved Transaction Translator scheduling            │ │
 +
  │ │      ...                                                            │ │
 +
  │ │      <*>  DesignWare USB3 DRD Core Support                          │ │
 +
  │ │            DWC3 Mode Selection (Host only mode)  --->                │ │
 +
  │ │            *** Platform Glue Driver Support ***                      │ │
 +
  │ │      <*>    Texas Instruments OMAP5 and similar Platforms          │ │
 +
  │ │      <*>    PCIe-based Platforms                                    │ │
 +
  │ │      ...                                                            │ │ 
 +
  │ └───────────────────────────────────────────────────────────────────────┘ │ 
 +
  ├───────────────────────────────────────────────────────────────────────────┤ 
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >          │ 
 +
  └───────────────────────────────────────────────────────────────────────────┘
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> PHY subsystem''' submenu and enable:
 +
* OMAP USB2 PHY Driver
 +
<pre>
 +
  ┌────────────────────────────── PHY Subsystem ──────────────────────────────┐
 +
  │ ┌───────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │      ...                                                            │ │ 
 +
  │ │    -*- OMAP CONTROL PHY Driver                                        │ │ 
 +
  │ │    <*> OMAP USB2 PHY Driver                                          │ │ 
 +
  │ │      ...                                                            │ │ 
 +
  │ └───────────────────────────────────────────────────────────────────────┘ │ 
 +
  ├───────────────────────────────────────────────────────────────────────────┤ 
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >          │ 
 +
  └───────────────────────────────────────────────────────────────────────────┘ 
 +
</pre>
 +
 +
==== MMC/SDIO support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> MMC/SD/SDIO card support''' submenu and enable:
 +
* MMC block device driver
 +
* TI OMAP Multimedia Card Interface support
 +
* TI OMAP High Speed Multimedia Card Interface support
 +
<pre>
 +
  ┌───────────────────────── MMC/SD/SDIO card support ──────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M>  MMC block device driver                                    │ │
 +
  │ │      (8)    Number of minors per block device                        │ │
 +
  │ │      [*]    Use bounce buffer for simple hosts                        │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <*>  TI OMAP Multimedia Card Interface support                  │ │
 +
  │ │      <*>  TI OMAP High Speed Multimedia Card Interface support        │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== NAND support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> Memory Technology Device (MTD) support ---> NAND Device Support''' submenu and enable:
 +
* NAND Flash device on OMAP2, OMAP3 and OMAP4
 +
* Support hardware based BCH error correction
 +
<pre>
 +
  ┌──────────────────────────── NAND Device Support ────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │      ...                                                              │ │
 +
  │ │      <*>  NAND Flash device on OMAP2, OMAP3 and OMAP4                │ │
 +
  │ │      [*]    Support hardware based BCH error correction              │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== SPI support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> SPI support''' submenu and enable:
 +
* McSPI driver for OMAP
 +
* DRA7xxx QSPI controller support
 +
<pre>
 +
  ┌──────────────────────────────── SPI support ────────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │    ...                                                                  │ │
 +
  │ │    <*>  McSPI driver for OMAP                                          │ │
 +
  │ │    <*>  DRA7xxx QSPI controller support                                │ │
 +
  │ │    ...                                                                  │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
===== SPI-flash support =====
 +
In the kernel configuration menu choose '''Device Drivers ---> Memory Technology Device (MTD) support''' submenu and enable:
 +
* SPI-NOR device support
 +
<pre>
 +
  ┌────────────────── Memory Technology Device (MTD) support ───────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │      ...                                                              │ │
 +
  │ │      <*>  SPI-NOR device support  --->                                │ │ 
 +
  │ │      <*>  Enable UBI - Unsorted block images  --->                    │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Memory Technology Device (MTD) support ---> Self-contained MTD device drivers''' submenu and enable:
 +
* Support most SPI Flash chips (AT26DF, M25P, W25X, ...)
 +
<pre>
 +
  ┌───────────────────── Self-contained MTD device drivers ─────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │      < > Support for AT45xxx DataFlash                                │ │
 +
  │ │      <*> Support most SPI Flash chips (AT26DF, M25P, W25X, ...)        │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== UART support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> Character devices ---> Serial drivers''' submenu and enable:
 +
* 8250/16550 and compatible serial support
 +
* OMAP serial port support
 +
* Console on OMAP serial port
 +
<pre>
 +
  ┌────────────────────────────── Serial drivers ───────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │ 
 +
  │ │      <*> 8250/16550 and compatible serial support                      │ │
 +
  │ │      [*]  Support 8250_core.* kernel options (DEPRECATED)            │ │
 +
  │ │      [*]  Console on 8250/16550 and compatible serial port            │ │
 +
  │ │      [*]  DMA support for 16550 compatible UART controllers          │ │
 +
  │ │      <*>  8250/16550 PCI device support                              │ │
 +
  │ │      (32)  Maximum number of 8250/16550 serial ports                  │ │
 +
  │ │      (4)  Number of 8250/16550 serial ports to register at runtime    │ │
 +
  │ │      [*]  Extended 8250/16550 serial driver options                  │ │
 +
  │ │      [*]    Support more than 4 legacy serial ports                  │ │
 +
  │ │      [*]    Support for sharing serial interrupts                    │ │
 +
  │ │      [*]    Autodetect IRQ on standard ports (unsafe)                │ │
 +
  │ │      [*]    Support RSA serial ports                                  │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <*> OMAP serial port support                                      │ │
 +
  │ │      [*]  Console on OMAP serial port                                │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== Ethernet support ====
 +
CL-SOM-AM57x features an ethernet controller that can operate as a Layer-2 3-port ethernet switch. Alternatively, the ethernet controller can be setup in dualEMAC mode, which is the default on CL-SOM-AM57x. The mode of operation can be changed to ethernet switch by editing the device tree.
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Network device support ---> Ethernet driver support''' submenu and enable:
 +
* Texas Instruments (TI) devices
 +
* TI CPSW Switch Support
 +
<pre>
 +
  ┌────────────────────────── Ethernet driver support ──────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      [*]  Texas Instruments (TI) devices                              │ │
 +
  │ │      <*>    TI DaVinci EMAC Support                                  │ │
 +
  │ │      -*-    TI DaVinci MDIO Support                                  │ │
 +
  │ │      -*-    TI DaVinci CPDMA Support                                  │ │
 +
  │ │      -*-    TI CPSW Switch Phy sel Support                            │ │
 +
  │ │      -*-    TI CPSW ALE Support                                      │ │
 +
  │ │      <*>    TI CPSW Switch Support                                    │ │
 +
  │ │      [*]      TI Common Platform Time Sync (CPTS) Support            │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Network device support ---> PHY Device support and infrastructure''' submenu and enable:
 +
* Drivers for Atheros AT803X PHYs
 +
<pre>
 +
  ┌─────────────────── PHY Device support and infrastructure ───────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <*>  Drivers for Atheros AT803X PHYs                            │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== Display support ====
 +
CL-SOM-AM57 has 3 parallel RGB display interface and a single DHMI interface.
 +
Display interfaces usage:
 +
* RGB interface 1 is used for LCD and DVI display.
 +
* RGB interface 3 is used for LVDS display.
 +
* The HDMI interface is used for HDMI display.
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Graphics support''' submenu and set/enable:
 +
* MAP DRM
 +
* Number of CRTCs = 2
 +
<pre>
 +
  ┌───────────────────────────── Graphics support ──────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      [*]  OMAP DRM                                                    │ │
 +
  │ │      (2)    Number of CRTCs                                          │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Graphics support ---> Frame buffer Devices ---> OMAP2+ Display Subsystem support''' submenu and enable:
 +
* DPI support
 +
* HDMI support for OMAP5
 +
<pre>
 +
  ┌───────────────────── OMAP2+ Display Subsystem support ──────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      [*]  DPI support                                                │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      [*]  HDMI support for OMAP5                                      │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Graphics support ---> Frame buffer Devices ---> OMAP2+ Display Subsystem support --- OMAP Display Device Driver''' submenu and enable:
 +
* TFP410 DPI to DVI Encoder
 +
* DVI Connector
 +
* HDMI Connector
 +
* Generic DPI panel
 +
 +
<pre>
 +
  ┌────────────── OMAP Display Device Drivers (new device model) ───────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      < > OPA362 external analog amplifier                              │ │
 +
  │ │      <*> TFP410 DPI to DVI Encoder                                    │ │
 +
  │ │      < > TPD12S015 HDMI ESD protection and level shifter              │ │
 +
  │ │      <*> DVI Connector                                                │ │
 +
  │ │      <*> HDMI Connector                                                │ │
 +
  │ │      < > Analog TV Connector                                          │ │
 +
  │ │      <*> Generic DPI panel                                            │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== Wifi support ====
 +
The WiFi chip is connected to the SoC via SDIO interface, so make sure you have MMC support turned on. Also, make sure wireless support is turned on under '''Network support'''.
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Network device support ---> Wireless LAN''' submenu and enable:
 +
* TI Wireless LAN support
 +
<pre>
 +
  ┌──────────────────────────────── Wireless LAN ───────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      [*]  TI Wireless LAN support  --->                              │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Device Drivers ---> Network device support ---> Wireless LAN ---> TI Wireless LAN support''' submenu and enable:
 +
* TI wl18xx support
 +
* TI wlcore support
 +
<pre>
 +
  ┌────────────────────────── TI Wireless LAN support ──────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M>  TI wl18xx support                                          │ │
 +
  │ │      -M-  TI wlcore support                                          │ │
 +
  │ │      < >    TI wlcore SPI support                                    │ │
 +
  │ │      <M>    TI wlcore SDIO support                                    │ │
 +
  │ │      [ ]  TI WiLink platform data                                    │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== Bluetooth support ====
 +
The Bluetooth chip is connected to the SoC via UART interface, so make sure you have UART support turned on. Also, make sure bluetooth support is turned on under '''Network support ---> Bluetooth subsystem support'''.
 +
 +
In the kernel configuration menu choose '''Networking support ---> Bluetooth subsystem support ---> Bluetooth device drivers''' submenu and enable:
 +
* HCI UART driver
 +
* UART (H4) protocol support
 +
* HCILL protocol support
 +
<pre>
 +
  ┌───────────────────────── Bluetooth device drivers ──────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M> HCI UART driver                                              │ │
 +
  │ │      [*]  UART (H4) protocol support                                  │ │
 +
  │ │      [ ]  BCSP protocol support                                      │ │
 +
  │ │      [ ]  Atheros AR300x serial support                              │ │
 +
  │ │      [*]  HCILL protocol support                                      │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== Audio support ====
 +
In the kernel configuration menu choose '''Device Drivers ---> Sound card support ---> Advanced Linux Sound Architecture ---> ALSA for SoC audio support''' submenu and enable:
 +
* SoC Audio for Texas Instruments chips using eDMA
 +
* Multichannel Audio Serial Port (McASP) support
 +
* SoC Audio for the Texas Instruments OMAP chips
 +
* HDMI audio support for OMAP4+ based SoCs
 +
* ASoC Simple sound card support
 +
<pre>
 +
  ┌──────────────────────── ALSA for SoC audio support ─────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      --- ALSA for SoC audio support                                    │ │
 +
  │ │      < >  SoC Audio for the Atmel System-on-Chip                      │ │
 +
  │ │      <*>  SoC Audio for Texas Instruments chips using eDMA            │ │
 +
  │ │      <*>  Multichannel Audio Serial Port (McASP) support              │ │
 +
  │ │      < >  SoC Audio for the AM33XX chip based boards                  │ │
 +
  │ │      < >  Synopsys I2S Device Driver                                  │ │
 +
  │ │            SoC Audio for Freescale CPUs  --->                          │ │
 +
  │ │      <M>  SoC Audio for the Texas Instruments OMAP chips              │ │
 +
  │ │      <M>  HDMI audio support for OMAP4+ based SoCs                    │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M>  ASoC Simple sound card support                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
Under the '''CODEC drivers''' submenu of the same section enable:
 +
* HDMI stub CODEC
 +
* Wolfson Microelectronics WM8731 CODEC
 +
<pre>
 +
  ┌──────────────────────── ALSA for SoC audio support ─────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M> HDMI stub CODEC                                              │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M> Wolfson Microelectronics WM8731 CODEC                        │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
==== CAN bus support ====
 +
In the kernel configuration menu choose '''Networking support ---> CAN bus subsystem support ---> CAN Device Drivers''' submenu and enable:
 +
* Platform CAN drivers with Netlink support
 +
* Bosch C_CAN/D_CAN devices
 +
<pre>
 +
  ┌───────────────────────────── CAN Device Drivers ────────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M> Platform CAN drivers with Netlink support                    │ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M>  Bosch C_CAN/D_CAN devices  --->                            │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
 +
 +
In the kernel configuration menu choose '''Networking support ---> CAN bus subsystem support ---> CAN Device Drivers ---> Bosch C_CAN/D_CAN devices''' submenu and enable:
 +
* Generic Platform Bus based C_CAN/D_CAN driver
 +
<pre>
 +
  ┌───────────────────────── Bosch C_CAN/D_CAN devices ─────────────────────────┐
 +
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
 +
  │ │      ...                                                              │ │
 +
  │ │      <M>  Generic Platform Bus based C_CAN/D_CAN driver              │ │
 +
  │ │      ...                                                              │ │
 +
  │ └─────────────────────────────────────────────────────────────────────────┘ │
 +
  ├─────────────────────────────────────────────────────────────────────────────┤
 +
  │        <Select>    < Exit >    < Help >    < Save >    < Load >            │
 +
  └─────────────────────────────────────────────────────────────────────────────┘
 +
</pre>
  
 
== See also ==
 
== See also ==

Revision as of 08:08, 26 October 2016

Overview

Linux kernel for the CompuLab CL-SOM-AM57x System-on-Module / Computer-on-Module provides support for on-board peripherals and abstracts the functionality provided by the hardware. CompuLab provides ready-to-run binary kernel images, and source code of the modifications and additions made to the Linux kernel to work properly with CL-SOM-AM57x modules.

Building kernel for CL-SOM-AM57x

Getting kernel sources

There are various ways to get Linux kernel sources that can be used as a baseline for CL-SOM-AM57x kernel. For instance, a copy of linux-stable git tree can be created or a Linux kernel sources snapshot can be downloaded.

Assuming that the /home/development/cl-som-am57x/kernel directory structure has been created for CL-SOM-AM57x kernel development.

Snapshot download

Mainline kernel v4.4.21
  • Download v4.4.21 snapshot with a web browser.
  • Extract the downloaded archive linux-4.4.tar.gz
cd /home/development/cl-som-am57x/kernel
tar xvf /path/to/downloaded/linux-4.4.21.tar.gz
mv linux-4.4.21 linux-cl-som-am57x
This will create /home/development/cl-som-am57x/kernel/linux-cl-som-am57x directory containing linux kernel tree.
  • Apply the CL-SOM-AM57x patch
cd /home/development/cl-som-am57x/kernel/cl-som-am57x
patch -p1 < /path/to/cl-som-am57x/kernel/kernel-v4.4/linux-4.4.21-cl-som-am57x-3.2.patch
TI SDK kernel v4.1.13
  • Download v4.1.13 snapshot with a web browser.
cd /home/development/cl-som-am57x/kernel
tar xvf /path/to/downloaded/processor-sdk-processor-sdk-linux-processor-sdk-linux-02.00.01.tar.gz
mv processor-sdk-linux linux-cl-som-am57x-ti
This will create /home/development/cl-som-am57x/kernel/linux-cl-som-am57x-ti directory containing linux kernel tree.
  • Apply the CL-SOM-AM57x patch
cd /home/development/cl-som-am57x/kernel/cl-som-am57x-ti
patch -p1 < /path/to/cl-som-am57x/kernel/ti-sdk-4.1.13/linux-4.1.13-cl-som-am57x-ti-3.2.patch

Git clone

  • Install git version control system.
Mainline kernel v4.4.21
  • Create a clone of linux kernel tree
cd /home/development/cl-som-am57x/kernel
git clone git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-cl-som-am57x
  • Create a branch for CL-SOM-AM57x development. The CL-SOM-AM57x patches are generated vs. v4.4.21 tag (1d074db69c46d62ce82b331c2080e2fcb710bf4a commit) in the Linux stable tree. It is recommended to use exactly the same baseline to avoid merge conflicts.
cd /home/development/cl-som-am57x/kernel/linux-cl-som-am57x
git checkout -b cl-som-am57x-dev v4.4.21
  • Apply the CL-SOM-AM57x patch
git am /path/to/cl-som-am57x-linux/kernel/kernel-v4.4/patches/*.patch


Admolition note.png Future stable kernel versions of 4.4 can also be used by adding the Linux kernel stable repository as a remote and checking out any later tag of the v4.4.y stable kernel branch.
TI SDK kernel v4.1.13
  • Create a clone of linux kernel tree
cd /home/development/cl-som-am57x/kernel
git clone git://git.ti.com/processor-sdk/processor-sdk-linux.git linux-cl-som-am57x-ti
  • Create a branch for CL-SOM-AM57x development. The CL-SOM-AM57x patches are generated vs. processor-sdk-linux-rt-02.00.01 branch in the TI Linux tree. It is recommended to use exactly the same baseline to avoid merge conflicts.
cd /home/development/cl-som-am57x/kernel/linux-cl-som-am57x-ti
git checkout -b cl-som-am57x-dev-ti origin/processor-sdk-linux-02.00.01
Admolition note.png As an alternative, the TI SDK kernel can be added as an additional remote to the mainline kernel git repository.
  • Apply the CL-SOM-AM57x patch
git am /path/to/cl-som-am57x-linux/kernel/ti-sdk-4.1.13/kernel/patches/*.patch

Building the kernel

  • Run the following commands:
export ARCH=arm
export CROSS_COMPILE=arm-none-linux-eabi-
make cl-som-am57x_defconfig && make menuconfig
make && make zImage && make am57xx-sbc-am57x.dtb \
     INSTALL_MOD_PATH=/home/development/cl-som-am57x/rootfs make modules_install

In the example above:

  • The Linux kernel image zImage will be created in /home/development/cl-som-am57x/kernel/linux-cl-som-am57x/arch/arm/boot
  • The Device Tree binary am57xx-sbc-am57x.dtb will be created in /home/development/cl-som-am57x/kernel/linux-cl-som-am57x/arch/arm/boot/dts
  • The loadable kernel modules will be installed into the /home/development/cl-som-am57x/rootfs/lib/modules directory.

When the CL-SOM-AM57x is booted with the kernel image and Device Tree binary created as described above and with networked root filesystem at /home/development/cl-som-am57x/rootfs/, the system will be able to load the kernel modules properly, thus avoiding module version problems.

Device Tree

Device Tree (DT), is a data structure and language for describing hardware. More specifically, it is a description of hardware that is readable by an operating system so that the operating system doesn't need to hard code details of the machine.

A device tree file, named *.dts, is a text file that describes the hardware platform. It is compiled into a device tree blob, *.dtb, which is loaded into memory before the Linux kernel is started. The Linux kernel then uses that device tree blob to initialize itself at runtime.

CL-SOM-AM57x device tree organization

The SBC-AM57x product is built from 3 major components:

┌───────────────────────────────┐
│ SB-SOM baseboard    	        │
│      	       	       	   	│
│   ┌─────────────────────┐  	│
│   │ CL-SOM-AM57x SoM 	  │    	│
│   │  	       		  │	│
│   │  	┌──────────────┐  │	│
│   │ 	│ TI AM57x SoC │  │	│
│   │	└──────────────┘  │	│
│   └─────────────────────┘	│
└───────────────────────────────┘

SBC-AM57x Device tree hierarchy reflects the hardware hierarchy:

	      dra74x.dtsi
		   ∧
		   │
	am57xx-cl-som-am57x.dts	      compulab-sb-som.dtsi
		   ∧			        ∧
		   └────────┐	       ┌────────┘
			    │	       │
			am57xx-sbc-am57x.dts
  • dra74x.dtsi is the SoC vendor device tree describing the dra74x SoC family.
  • am57xx-cl-som-am57x.dts is the SoM vendor device tree describing the CL-SOM-AM57x SoM.
  • compulab-sb-som.dtsi describes the SB-SOM baseboard. Only hardware properties that remain constant regardless of which SoM is installed on the baseboard are described here.
  • am57xx-sbc-am57x.dts describes the integration between CL-SOM-AM57x SoM and the SB-SOM baseboard. Everything that is related to the SB-SOM baseboard and would change if we were to swap the CL-SOM-AM57x module with another SoM is described here. For example: SB-SOM contains TFP410, an RGB-to-DVI encoder. The encoder is located on an I2C bus, but depending on the installed SoC it might be i2c1, i2c2, or i2c3. Therefore, it is not described in the generic compulab-sb-som.dtsi device tree, but in the device tree describing the SB-SOM/CL-SOM-AM57x combination. On the other hand, in order to describe the DVI connector on SB-SOM, there is no need to reference any SoM specific information, and therefore it is described in the generic compulab-sb-som.dtsi file.

For more details visit official Device Tree WiKi pages and make an overview of a Device Tree tutorial

Kernel configuration

USB support

In the kernel configuration menu choose Device Drivers ---> USB support submenu and enable:

  • Support for Host-side USB
  • Enable USB persist by default
  • OTG support
  • xHCI HCD (USB 3.0) support
  • EHCI HCD (USB 2.0) support
  • DesignWare USB3 DRD Core Support
 ┌─────────────────────────────── USB support ───────────────────────────────┐
 │ ┌───────────────────────────────────────────────────────────────────────┐ │
 │ │       --- USB support                                                 │ │
 │ │       <*>   Support for Host-side USB                                 │ │
 │ │       [*]     USB announce new devices                                │ │
 │ │               *** Miscellaneous USB options ***                       │ │
 │ │       [*]     Enable USB persist by default                           │ │
 │ │       [ ]     Dynamic USB minor allocation                            │ │
 │ │       [*]     OTG support                                             │ │
 │ │       ...                                                             │ │
 │ │       <*>     xHCI HCD (USB 3.0) support                              │ │
 │ │       -*-       Generic xHCI driver for a platform device             │ │  
 │ │       <*>     EHCI HCD (USB 2.0) support                              │ │
 │ │       [*]       Root Hub Transaction Translators                      │ │
 │ │       [ ]       Improved Transaction Translator scheduling            │ │
 │ │       ...                                                             │ │ 
 │ │       <*>   DesignWare USB3 DRD Core Support                          │ │
 │ │             DWC3 Mode Selection (Host only mode)  --->                │ │
 │ │             *** Platform Glue Driver Support ***                      │ │
 │ │       <*>     Texas Instruments OMAP5 and similar Platforms           │ │
 │ │       <*>     PCIe-based Platforms                                    │ │
 │ │       ...                                                             │ │  
 │ └───────────────────────────────────────────────────────────────────────┘ │  
 ├───────────────────────────────────────────────────────────────────────────┤  
 │         <Select>    < Exit >    < Help >    < Save >    < Load >          │  
 └───────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> PHY subsystem submenu and enable:

  • OMAP USB2 PHY Driver
  ┌────────────────────────────── PHY Subsystem ──────────────────────────────┐
  │ ┌───────────────────────────────────────────────────────────────────────┐ │  
  │ │       ...                                                             │ │  
  │ │    -*- OMAP CONTROL PHY Driver                                        │ │  
  │ │    <*> OMAP USB2 PHY Driver                                           │ │  
  │ │       ...                                                             │ │  
  │ └───────────────────────────────────────────────────────────────────────┘ │  
  ├───────────────────────────────────────────────────────────────────────────┤  
  │         <Select>    < Exit >    < Help >    < Save >    < Load >          │  
  └───────────────────────────────────────────────────────────────────────────┘  

MMC/SDIO support

In the kernel configuration menu choose Device Drivers ---> MMC/SD/SDIO card support submenu and enable:

  • MMC block device driver
  • TI OMAP Multimedia Card Interface support
  • TI OMAP High Speed Multimedia Card Interface support
  ┌───────────────────────── MMC/SD/SDIO card support ──────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M>   MMC block device driver                                     │ │
  │ │       (8)     Number of minors per block device                         │ │
  │ │       [*]     Use bounce buffer for simple hosts                        │ │
  │ │       ...                                                               │ │
  │ │       <*>   TI OMAP Multimedia Card Interface support                   │ │
  │ │       <*>   TI OMAP High Speed Multimedia Card Interface support        │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

NAND support

In the kernel configuration menu choose Device Drivers ---> Memory Technology Device (MTD) support ---> NAND Device Support submenu and enable:

  • NAND Flash device on OMAP2, OMAP3 and OMAP4
  • Support hardware based BCH error correction
  ┌──────────────────────────── NAND Device Support ────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │  
  │ │       ...                                                               │ │
  │ │       <*>   NAND Flash device on OMAP2, OMAP3 and OMAP4                 │ │
  │ │       [*]     Support hardware based BCH error correction               │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

SPI support

In the kernel configuration menu choose Device Drivers ---> SPI support submenu and enable:

  • McSPI driver for OMAP
  • DRA7xxx QSPI controller support
  ┌──────────────────────────────── SPI support ────────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │  
  │ │    ...                                                                  │ │
  │ │    <*>   McSPI driver for OMAP                                          │ │
  │ │    <*>   DRA7xxx QSPI controller support                                │ │
  │ │    ...                                                                  │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘
SPI-flash support

In the kernel configuration menu choose Device Drivers ---> Memory Technology Device (MTD) support submenu and enable:

  • SPI-NOR device support
  ┌────────────────── Memory Technology Device (MTD) support ───────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │  
  │ │       ...                                                               │ │
  │ │       <*>   SPI-NOR device support  --->                                │ │  
  │ │       <*>   Enable UBI - Unsorted block images  --->                    │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> Memory Technology Device (MTD) support ---> Self-contained MTD device drivers submenu and enable:

  • Support most SPI Flash chips (AT26DF, M25P, W25X, ...)
  ┌───────────────────── Self-contained MTD device drivers ─────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │  
  │ │       < > Support for AT45xxx DataFlash                                 │ │
  │ │       <*> Support most SPI Flash chips (AT26DF, M25P, W25X, ...)        │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

UART support

In the kernel configuration menu choose Device Drivers ---> Character devices ---> Serial drivers submenu and enable:

  • 8250/16550 and compatible serial support
  • OMAP serial port support
  • Console on OMAP serial port
  ┌────────────────────────────── Serial drivers ───────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │  
  │ │       <*> 8250/16550 and compatible serial support                      │ │
  │ │       [*]   Support 8250_core.* kernel options (DEPRECATED)             │ │
  │ │       [*]   Console on 8250/16550 and compatible serial port            │ │
  │ │       [*]   DMA support for 16550 compatible UART controllers           │ │
  │ │       <*>   8250/16550 PCI device support                               │ │
  │ │       (32)  Maximum number of 8250/16550 serial ports                   │ │
  │ │       (4)   Number of 8250/16550 serial ports to register at runtime    │ │
  │ │       [*]   Extended 8250/16550 serial driver options                   │ │
  │ │       [*]     Support more than 4 legacy serial ports                   │ │
  │ │       [*]     Support for sharing serial interrupts                     │ │
  │ │       [*]     Autodetect IRQ on standard ports (unsafe)                 │ │
  │ │       [*]     Support RSA serial ports                                  │ │
  │ │       ...                                                               │ │
  │ │       <*> OMAP serial port support                                      │ │
  │ │       [*]   Console on OMAP serial port                                 │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Ethernet support

CL-SOM-AM57x features an ethernet controller that can operate as a Layer-2 3-port ethernet switch. Alternatively, the ethernet controller can be setup in dualEMAC mode, which is the default on CL-SOM-AM57x. The mode of operation can be changed to ethernet switch by editing the device tree.

In the kernel configuration menu choose Device Drivers ---> Network device support ---> Ethernet driver support submenu and enable:

  • Texas Instruments (TI) devices
  • TI CPSW Switch Support
  ┌────────────────────────── Ethernet driver support ──────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       [*]   Texas Instruments (TI) devices                              │ │
  │ │       <*>     TI DaVinci EMAC Support                                   │ │
  │ │       -*-     TI DaVinci MDIO Support                                   │ │
  │ │       -*-     TI DaVinci CPDMA Support                                  │ │
  │ │       -*-     TI CPSW Switch Phy sel Support                            │ │
  │ │       -*-     TI CPSW ALE Support                                       │ │
  │ │       <*>     TI CPSW Switch Support                                    │ │
  │ │       [*]       TI Common Platform Time Sync (CPTS) Support             │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> Network device support ---> PHY Device support and infrastructure submenu and enable:

  • Drivers for Atheros AT803X PHYs
  ┌─────────────────── PHY Device support and infrastructure ───────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <*>   Drivers for Atheros AT803X PHYs                             │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Display support

CL-SOM-AM57 has 3 parallel RGB display interface and a single DHMI interface. Display interfaces usage:

  • RGB interface 1 is used for LCD and DVI display.
  • RGB interface 3 is used for LVDS display.
  • The HDMI interface is used for HDMI display.

In the kernel configuration menu choose Device Drivers ---> Graphics support submenu and set/enable:

  • MAP DRM
  • Number of CRTCs = 2
  ┌───────────────────────────── Graphics support ──────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       [*]   OMAP DRM                                                    │ │
  │ │       (2)     Number of CRTCs                                           │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> Graphics support ---> Frame buffer Devices ---> OMAP2+ Display Subsystem support submenu and enable:

  • DPI support
  • HDMI support for OMAP5
  ┌───────────────────── OMAP2+ Display Subsystem support ──────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       [*]   DPI support                                                 │ │
  │ │       ...                                                               │ │
  │ │       [*]   HDMI support for OMAP5                                      │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> Graphics support ---> Frame buffer Devices ---> OMAP2+ Display Subsystem support --- OMAP Display Device Driver submenu and enable:

  • TFP410 DPI to DVI Encoder
  • DVI Connector
  • HDMI Connector
  • Generic DPI panel
  ┌────────────── OMAP Display Device Drivers (new device model) ───────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       < > OPA362 external analog amplifier                              │ │
  │ │       <*> TFP410 DPI to DVI Encoder                                     │ │
  │ │       < > TPD12S015 HDMI ESD protection and level shifter               │ │
  │ │       <*> DVI Connector                                                 │ │
  │ │       <*> HDMI Connector                                                │ │
  │ │       < > Analog TV Connector                                           │ │
  │ │       <*> Generic DPI panel                                             │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Wifi support

The WiFi chip is connected to the SoC via SDIO interface, so make sure you have MMC support turned on. Also, make sure wireless support is turned on under Network support.

In the kernel configuration menu choose Device Drivers ---> Network device support ---> Wireless LAN submenu and enable:

  • TI Wireless LAN support
  ┌──────────────────────────────── Wireless LAN ───────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       [*]   TI Wireless LAN support  --->                               │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Device Drivers ---> Network device support ---> Wireless LAN ---> TI Wireless LAN support submenu and enable:

  • TI wl18xx support
  • TI wlcore support
  ┌────────────────────────── TI Wireless LAN support ──────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M>   TI wl18xx support                                           │ │
  │ │       -M-   TI wlcore support                                           │ │
  │ │       < >     TI wlcore SPI support                                     │ │
  │ │       <M>     TI wlcore SDIO support                                    │ │
  │ │       [ ]   TI WiLink platform data                                     │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Bluetooth support

The Bluetooth chip is connected to the SoC via UART interface, so make sure you have UART support turned on. Also, make sure bluetooth support is turned on under Network support ---> Bluetooth subsystem support.

In the kernel configuration menu choose Networking support ---> Bluetooth subsystem support ---> Bluetooth device drivers submenu and enable:

  • HCI UART driver
  • UART (H4) protocol support
  • HCILL protocol support
  ┌───────────────────────── Bluetooth device drivers ──────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M> HCI UART driver                                               │ │
  │ │       [*]   UART (H4) protocol support                                  │ │
  │ │       [ ]   BCSP protocol support                                       │ │
  │ │       [ ]   Atheros AR300x serial support                               │ │
  │ │       [*]   HCILL protocol support                                      │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Audio support

In the kernel configuration menu choose Device Drivers ---> Sound card support ---> Advanced Linux Sound Architecture ---> ALSA for SoC audio support submenu and enable:

  • SoC Audio for Texas Instruments chips using eDMA
  • Multichannel Audio Serial Port (McASP) support
  • SoC Audio for the Texas Instruments OMAP chips
  • HDMI audio support for OMAP4+ based SoCs
  • ASoC Simple sound card support
  ┌──────────────────────── ALSA for SoC audio support ─────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       --- ALSA for SoC audio support                                    │ │
  │ │       < >   SoC Audio for the Atmel System-on-Chip                      │ │
  │ │       <*>   SoC Audio for Texas Instruments chips using eDMA            │ │
  │ │       <*>   Multichannel Audio Serial Port (McASP) support              │ │
  │ │       < >   SoC Audio for the AM33XX chip based boards                  │ │
  │ │       < >   Synopsys I2S Device Driver                                  │ │
  │ │             SoC Audio for Freescale CPUs  --->                          │ │
  │ │       <M>   SoC Audio for the Texas Instruments OMAP chips              │ │
  │ │       <M>   HDMI audio support for OMAP4+ based SoCs                    │ │
  │ │       ...                                                               │ │
  │ │       <M>   ASoC Simple sound card support                              │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

Under the CODEC drivers submenu of the same section enable:

  • HDMI stub CODEC
  • Wolfson Microelectronics WM8731 CODEC
  ┌──────────────────────── ALSA for SoC audio support ─────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M> HDMI stub CODEC                                               │ │
  │ │       ...                                                               │ │
  │ │       <M> Wolfson Microelectronics WM8731 CODEC                         │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

CAN bus support

In the kernel configuration menu choose Networking support ---> CAN bus subsystem support ---> CAN Device Drivers submenu and enable:

  • Platform CAN drivers with Netlink support
  • Bosch C_CAN/D_CAN devices
  ┌───────────────────────────── CAN Device Drivers ────────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M> Platform CAN drivers with Netlink support                     │ │
  │ │       ...                                                               │ │
  │ │       <M>   Bosch C_CAN/D_CAN devices  --->                             │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

In the kernel configuration menu choose Networking support ---> CAN bus subsystem support ---> CAN Device Drivers ---> Bosch C_CAN/D_CAN devices submenu and enable:

  • Generic Platform Bus based C_CAN/D_CAN driver
  ┌───────────────────────── Bosch C_CAN/D_CAN devices ─────────────────────────┐
  │ ┌─────────────────────────────────────────────────────────────────────────┐ │
  │ │       ...                                                               │ │
  │ │       <M>   Generic Platform Bus based C_CAN/D_CAN driver               │ │
  │ │       ...                                                               │ │
  │ └─────────────────────────────────────────────────────────────────────────┘ │
  ├─────────────────────────────────────────────────────────────────────────────┤
  │         <Select>    < Exit >    < Help >    < Save >    < Load >            │
  └─────────────────────────────────────────────────────────────────────────────┘

See also