Skip to content

Instantly share code, notes, and snippets.

@bodokaiser
Last active February 8, 2022 19:44
Show Gist options
  • Star 8 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save bodokaiser/6854708 to your computer and use it in GitHub Desktop.
Save bodokaiser/6854708 to your computer and use it in GitHub Desktop.
Guide How-To use Device Tree Overlays on Archlinux.

Device Tree Overlays on Archlinux

Dependencies

base-devel

You require a working archlinuxarm operarting system and the development tools:

$ pacman -S base-devel

Confirm with Y.

dtc-git-patched

Now we require a patched build of the Device Tree Compiler (dtc):

$ curl -O https://aur.archlinux.org/packages/dt/dtc-git-patched/dtc-git-patched.tar.gz
$ tar xzf dtc-git-patched.tar.gz && cd dtc-git-patched
$ makepkg
$ pacman -U dtc*

Usage

Write Device Tree Source File

Define your dts file. As a start you could use the following am335x-boneblack-ehrpwm.dts which muxes pins to be used as PWM:

/**
 * Copyright (C) 2013 Bodo Kaiser
 *
 * PWM Test Device Tree Overlay for BeagleBone Black
 *
 * This program is free software; you can redistribute it and/or modify it 
 * under the terms of the GNU General Public License version 2 as published by 
 * the Free Software Foundation.
 */

 /dts-v1/;
 /plugin/;

 / {

    compatible = "ti,beaglebone", "ti,beaglebone-black";

    part-number = "am335x-boneblack-ehrpwm";

    exclusive-use = "P8.13"; 

    fragment@0 {
        target = <&am33xx_pinmux>;

        __overlay__ {
            pwm_P8_13: pinmux_pwm_P8_13_pins {
                pinctrl-single,pins = <0x024 0x04>;
            };
        };
    };

    fragment@1 {
        target = <&epwmss2>;

        __overlay__ {
            status = "okay";
        };
    };
    
    fragment@2 {
        target = <&ehrpwm2>;

        __overlay__ {
            status = "okay";
        };
    };

};

Compiling

Now we can compile the device tree source to a device tree blob:

$ dtc -I dts -O dtb -o /lib/firmware/am335x-boneblack-ehrpwm-00A0.dtbo -b 0 -@ am335x-boneblack-ehrpwm.dts

Main Device Tree Blob

For the next step the Bone's Capemgr requires the kernel's main device tree blob. We find this in /boot/dtbs but need to copy and rename it to be used by the capemgr.

$ cp /boot/dtbs/am335x-boneblack.dtb /lib/firmware/am335x-boneblack-00A0.dtbo

Enable Device Tree Overlay

To enable our new device tree we have to use the capemgr file system api:

$ echo am335x-boneblack-ehrpwm > /sys/devices/bone_capemgr.*/slots

This should actually work. However I get write error: Invalid argument. We can debug this with:

$ dmesg | tail

which prints:

[ 4655.145371] bone-capemgr bone_capemgr.4: part_number 'am335x-boneblack', version 'N/A'
[ 4655.159077] bone-capemgr bone_capemgr.4: slot #29: generic override
[ 4655.166042] bone-capemgr bone_capemgr.4: bone: Using override eeprom data at slot 29
[ 4655.174298] bone-capemgr bone_capemgr.4: slot #29: 'Override Board Name,00A0,Override Manuf,am335x-boneblack'
[ 4655.189816] bone-capemgr bone_capemgr.4: slot #29: Requesting part number/version based 'am335x-boneblack-00A0.dtbo
[ 4655.203557] bone-capemgr bone_capemgr.4: slot #29: Requesting firmware 'am335x-boneblack-00A0.dtbo' for board-name 'Override Board Name', version '00A0'
[ 4655.222201] bone-capemgr bone_capemgr.4: slot #29: dtbo 'am335x-boneblack-00A0.dtbo' loaded; converting to live tree
[ 4655.237755] of_resolve: Could not find symbol 'emmc_pins'
[ 4655.243583] bone-capemgr bone_capemgr.4: slot #29: Failed to resolve tree

Additionally we could compile the distribution's dtbo back to source:

$ dtc -I dtb -O dts -o ./am335x-boneblack.dts /lib/firmware/am335x-boneblack-00A0.dtbo

The source file on this gist...

/dts-v1/;
/ {
#address-cells = <0x1>;
#size-cells = <0x1>;
compatible = "ti,am335x-bone", "ti,am33xx";
interrupt-parent = <0x1>;
model = "TI AM335x BeagleBone";
chosen {
};
aliases {
serial0 = "/ocp/serial@44e09000";
serial1 = "/ocp/serial@48022000";
serial2 = "/ocp/serial@48024000";
serial3 = "/ocp/serial@481a6000";
serial4 = "/ocp/serial@481a8000";
serial5 = "/ocp/serial@481aa000";
d_can0 = "/ocp/d_can@481cc000";
d_can1 = "/ocp/d_can@481d0000";
usb0 = "/ocp/usb@47400000/usb@47401000";
usb1 = "/ocp/usb@47400000/usb@47401800";
phy0 = "/ocp/usb@47400000/usb-phy@47401300";
phy1 = "/ocp/usb@47400000/usb-phy@47401b00";
};
memory {
device_type = "memory";
reg = <0x80000000 0x10000000>;
};
cpus {
#address-cells = <0x1>;
#size-cells = <0x0>;
cpu@0 {
compatible = "arm,cortex-a8";
device_type = "cpu";
reg = <0x0>;
operating-points = <0xafc80 0x139b88 0x927c0 0x12b128 0x7a120 0x112a88 0x43238 0x112a88>;
voltage-tolerance = <0x2>;
clock-latency = <0x493e0>;
cpu0-supply = <0x2>;
};
};
soc {
compatible = "ti,omap-infra";
mpu {
compatible = "ti,omap3-mpu";
ti,hwmods = "mpu";
};
};
pinmux@44e10800 {
compatible = "pinctrl-single";
reg = <0x44e10800 0x238>;
#address-cells = <0x1>;
#size-cells = <0x0>;
pinctrl-single,register-width = <0x20>;
pinctrl-single,function-mask = <0x7f>;
pinctrl-names = "default";
pinctrl-0 = <0x3>;
linux,phandle = <0x1e>;
phandle = <0x1e>;
user_leds_s0 {
pinctrl-single,pins = <0x54 0x7 0x58 0x17 0x5c 0x7 0x60 0x17>;
linux,phandle = <0x16>;
phandle = <0x16>;
};
pinmux_i2c0_pins {
pinctrl-single,pins = <0x188 0x70 0x18c 0x70>;
linux,phandle = <0x5>;
phandle = <0x5>;
};
pinmux_uart0_pins {
pinctrl-single,pins = <0x170 0x30 0x174 0x0>;
linux,phandle = <0x4>;
phandle = <0x4>;
};
pinmux_clkout2_pin {
pinctrl-single,pins = <0x1b4 0x3>;
linux,phandle = <0x3>;
phandle = <0x3>;
};
cpsw_default {
pinctrl-single,pins = <0x110 0x30 0x114 0x0 0x118 0x30 0x11c 0x0 0x120 0x0 0x124 0x0 0x128 0x0 0x12c 0x30 0x130 0x30 0x134 0x30 0x138 0x30 0x13c 0x30 0x140 0x30>;
linux,phandle = <0x11>;
phandle = <0x11>;
};
cpsw_sleep {
pinctrl-single,pins = <0x110 0x27 0x114 0x27 0x118 0x27 0x11c 0x27 0x120 0x27 0x124 0x27 0x128 0x27 0x12c 0x27 0x130 0x27 0x134 0x27 0x138 0x27 0x13c 0x27 0x140 0x27>;
linux,phandle = <0x12>;
phandle = <0x12>;
};
davinci_mdio_default {
pinctrl-single,pins = <0x148 0x70 0x14c 0x10>;
linux,phandle = <0x13>;
phandle = <0x13>;
};
davinci_mdio_sleep {
pinctrl-single,pins = <0x148 0x27 0x14c 0x27>;
linux,phandle = <0x14>;
phandle = <0x14>;
};
pinmux_i2c2_pins {
pinctrl-single,pins = <0x178 0x73 0x17c 0x73>;
linux,phandle = <0x6>;
phandle = <0x6>;
};
pinmux_mmc1_pins {
pinctrl-single,pins = <0x160 0x2f>;
linux,phandle = <0x9>;
phandle = <0x9>;
};
nxp_hdmi_bonelt_pins {
pinctrl-single,pins = <0x1b0 0x3 0xa0 0x8 0xa4 0x8 0xa8 0x8 0xac 0x8 0xb0 0x8 0xb4 0x8 0xb8 0x8 0xbc 0x8 0xc0 0x8 0xc4 0x8 0xc8 0x8 0xcc 0x8 0xd0 0x8 0xd4 0x8 0xd8 0x8 0xdc 0x8 0xe0 0x0 0xe4 0x0 0xe8 0x0 0xec 0x0>;
linux,phandle = <0x1d>;
phandle = <0x1d>;
};
};
ocp {
compatible = "simple-bus";
#address-cells = <0x1>;
#size-cells = <0x1>;
ranges;
ti,hwmods = "l3_main";
interrupt-controller@48200000 {
compatible = "ti,omap2-intc";
interrupt-controller;
#interrupt-cells = <0x1>;
ti,intc-size = <0x80>;
reg = <0x48200000 0x1000>;
linux,phandle = <0x1>;
phandle = <0x1>;
};
edma@49000000 {
compatible = "ti,edma3";
ti,hwmods = "tpcc", "tptc0", "tptc1", "tptc2";
reg = <0x49000000 0x10000 0x44e10f90 0x10>;
interrupts = <0xc 0xd 0xe>;
#dma-cells = <0x1>;
dma-channels = <0x40>;
ti,edma-regions = <0x4>;
ti,edma-slots = <0x100>;
linux,phandle = <0x7>;
phandle = <0x7>;
};
gpio@44e07000 {
compatible = "ti,omap4-gpio";
ti,hwmods = "gpio1";
gpio-controller;
#gpio-cells = <0x2>;
interrupt-controller;
#interrupt-cells = <0x1>;
reg = <0x44e07000 0x1000>;
interrupts = <0x60>;
linux,phandle = <0xa>;
phandle = <0xa>;
};
gpio@4804c000 {
compatible = "ti,omap4-gpio";
ti,hwmods = "gpio2";
gpio-controller;
#gpio-cells = <0x2>;
interrupt-controller;
#interrupt-cells = <0x1>;
reg = <0x4804c000 0x1000>;
interrupts = <0x62>;
linux,phandle = <0xc>;
phandle = <0xc>;
};
gpio@481ac000 {
compatible = "ti,omap4-gpio";
ti,hwmods = "gpio3";
gpio-controller;
#gpio-cells = <0x2>;
interrupt-controller;
#interrupt-cells = <0x1>;
reg = <0x481ac000 0x1000>;
interrupts = <0x20>;
linux,phandle = <0x1f>;
phandle = <0x1f>;
};
gpio@481ae000 {
compatible = "ti,omap4-gpio";
ti,hwmods = "gpio4";
gpio-controller;
#gpio-cells = <0x2>;
interrupt-controller;
#interrupt-cells = <0x1>;
reg = <0x481ae000 0x1000>;
interrupts = <0x3e>;
linux,phandle = <0x20>;
phandle = <0x20>;
};
serial@44e09000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart1";
clock-frequency = <0x2dc6c00>;
reg = <0x44e09000 0x2000>;
interrupts = <0x48>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <0x4>;
linux,phandle = <0x21>;
phandle = <0x21>;
};
serial@48022000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart2";
clock-frequency = <0x2dc6c00>;
reg = <0x48022000 0x2000>;
interrupts = <0x49>;
status = "disabled";
linux,phandle = <0x22>;
phandle = <0x22>;
};
serial@48024000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart3";
clock-frequency = <0x2dc6c00>;
reg = <0x48024000 0x2000>;
interrupts = <0x4a>;
status = "disabled";
linux,phandle = <0x23>;
phandle = <0x23>;
};
serial@481a6000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart4";
clock-frequency = <0x2dc6c00>;
reg = <0x481a6000 0x2000>;
interrupts = <0x2c>;
status = "disabled";
linux,phandle = <0x24>;
phandle = <0x24>;
};
serial@481a8000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart5";
clock-frequency = <0x2dc6c00>;
reg = <0x481a8000 0x2000>;
interrupts = <0x2d>;
status = "disabled";
linux,phandle = <0x25>;
phandle = <0x25>;
};
serial@481aa000 {
compatible = "ti,omap3-uart";
ti,hwmods = "uart6";
clock-frequency = <0x2dc6c00>;
reg = <0x481aa000 0x2000>;
interrupts = <0x2e>;
status = "disabled";
linux,phandle = <0x26>;
phandle = <0x26>;
};
i2c@44e0b000 {
compatible = "ti,omap4-i2c";
#address-cells = <0x1>;
#size-cells = <0x0>;
ti,hwmods = "i2c1";
reg = <0x44e0b000 0x1000>;
interrupts = <0x46>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <0x5>;
clock-frequency = <0x61a80>;
linux,phandle = <0x1c>;
phandle = <0x1c>;
tps@24 {
reg = <0x24>;
compatible = "ti,tps65217";
linux,phandle = <0x27>;
phandle = <0x27>;
regulators {
#address-cells = <0x1>;
#size-cells = <0x0>;
regulator@0 {
reg = <0x0>;
regulator-compatible = "dcdc1";
regulator-always-on;
linux,phandle = <0x28>;
phandle = <0x28>;
};
regulator@1 {
reg = <0x1>;
regulator-compatible = "dcdc2";
regulator-name = "vdd_mpu";
regulator-min-microvolt = <0xe1d48>;
regulator-max-microvolt = <0x1437c8>;
regulator-boot-on;
regulator-always-on;
linux,phandle = <0x2>;
phandle = <0x2>;
};
regulator@2 {
reg = <0x2>;
regulator-compatible = "dcdc3";
regulator-name = "vdd_core";
regulator-min-microvolt = <0xe1d48>;
regulator-max-microvolt = <0x118c30>;
regulator-boot-on;
regulator-always-on;
linux,phandle = <0x29>;
phandle = <0x29>;
};
regulator@3 {
reg = <0x3>;
regulator-compatible = "ldo1";
regulator-always-on;
linux,phandle = <0x2a>;
phandle = <0x2a>;
};
regulator@4 {
reg = <0x4>;
regulator-compatible = "ldo2";
regulator-always-on;
linux,phandle = <0x2b>;
phandle = <0x2b>;
};
regulator@5 {
reg = <0x5>;
regulator-compatible = "ldo3";
regulator-always-on;
regulator-min-microvolt = <0x1b7740>;
regulator-max-microvolt = <0x1b7740>;
linux,phandle = <0xb>;
phandle = <0xb>;
};
regulator@6 {
reg = <0x6>;
regulator-compatible = "ldo4";
regulator-always-on;
linux,phandle = <0x2c>;
phandle = <0x2c>;
};
};
fixedregulator@0 {
compatible = "regulator-fixed";
regulator-name = "vmmcsd_fixed";
regulator-min-microvolt = <0x325aa0>;
regulator-max-microvolt = <0x325aa0>;
linux,phandle = <0x8>;
phandle = <0x8>;
};
};
baseboard_eeprom@50 {
compatible = "at,24c256";
reg = <0x50>;
linux,phandle = <0x17>;
phandle = <0x17>;
};
};
i2c@4802a000 {
compatible = "ti,omap4-i2c";
#address-cells = <0x1>;
#size-cells = <0x0>;
ti,hwmods = "i2c2";
reg = <0x4802a000 0x1000>;
interrupts = <0x47>;
status = "disabled";
linux,phandle = <0x2d>;
phandle = <0x2d>;
};
i2c@4819c000 {
compatible = "ti,omap4-i2c";
#address-cells = <0x1>;
#size-cells = <0x0>;
ti,hwmods = "i2c3";
reg = <0x4819c000 0x1000>;
interrupts = <0x1e>;
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <0x6>;
clock-frequency = <0x186a0>;
linux,phandle = <0x2e>;
phandle = <0x2e>;
cape_eeprom0@54 {
compatible = "at,24c256";
reg = <0x54>;
linux,phandle = <0x18>;
phandle = <0x18>;
};
cape_eeprom1@55 {
compatible = "at,24c256";
reg = <0x55>;
linux,phandle = <0x19>;
phandle = <0x19>;
};
cape_eeprom2@56 {
compatible = "at,24c256";
reg = <0x56>;
linux,phandle = <0x1a>;
phandle = <0x1a>;
};
cape_eeprom3@57 {
compatible = "at,24c256";
reg = <0x57>;
linux,phandle = <0x1b>;
phandle = <0x1b>;
};
};
mmc@48060000 {
compatible = "ti,omap4-hsmmc";
ti,hwmods = "mmc1";
ti,dual-volt;
ti,needs-special-reset;
ti,needs-special-hs-handling;
dmas = <0x7 0x18 0x7 0x19>;
dma-names = "tx", "rx";
interrupts = <0x40>;
interrupt-parent = <0x1>;
reg = <0x48060000 0x1000>;
status = "okay";
bus-width = <0x4>;
vmmc-supply = <0x8>;
pinctrl-names = "default";
pinctrl-0 = <0x9>;
cd-gpios = <0xa 0x6 0x0>;
cd-inverted;
linux,phandle = <0x2f>;
phandle = <0x2f>;
};
mmc@481d8000 {
compatible = "ti,omap4-hsmmc";
ti,hwmods = "mmc2";
ti,needs-special-reset;
dmas = <0x7 0x2 0x7 0x3>;
dma-names = "tx", "rx";
interrupts = <0x1c>;
interrupt-parent = <0x1>;
reg = <0x481d8000 0x1000>;
status = "okay";
vmmc-supply = <0xb>;
pinctrl-names = "default";
pinctrl-0 = <0xdeadbeef>;
bus-width = <0x8>;
ti,non-removable;
ti,vcc-aux-disable-is-sleep;
reset-gpio = <0xc 0x14 0x0>;
linux,phandle = <0x30>;
phandle = <0x30>;
};
mmc@47810000 {
compatible = "ti,omap4-hsmmc";
ti,hwmods = "mmc3";
ti,needs-special-reset;
interrupts = <0x1d>;
interrupt-parent = <0x1>;
reg = <0x47810000 0x1000>;
status = "disabled";
linux,phandle = <0x31>;
phandle = <0x31>;
};
wdt@44e35000 {
compatible = "ti,omap3-wdt";
ti,hwmods = "wd_timer2";
reg = <0x44e35000 0x1000>;
interrupts = <0x5b>;
linux,phandle = <0x32>;
phandle = <0x32>;
};
d_can@481cc000 {
compatible = "bosch,d_can";
ti,hwmods = "d_can0";
reg = <0x481cc000 0x2000 0x44e10644 0x4>;
interrupts = <0x34>;
status = "disabled";
linux,phandle = <0x33>;
phandle = <0x33>;
};
d_can@481d0000 {
compatible = "bosch,d_can";
ti,hwmods = "d_can1";
reg = <0x481d0000 0x2000 0x44e10644 0x4>;
interrupts = <0x37>;
status = "disabled";
linux,phandle = <0x34>;
phandle = <0x34>;
};
timer@44e31000 {
compatible = "ti,am335x-timer-1ms";
reg = <0x44e31000 0x400>;
interrupts = <0x43>;
ti,hwmods = "timer1";
ti,timer-alwon;
linux,phandle = <0x35>;
phandle = <0x35>;
};
timer@48040000 {
compatible = "ti,am335x-timer";
reg = <0x48040000 0x400>;
interrupts = <0x44>;
ti,hwmods = "timer2";
linux,phandle = <0x36>;
phandle = <0x36>;
};
timer@48042000 {
compatible = "ti,am335x-timer";
reg = <0x48042000 0x400>;
interrupts = <0x45>;
ti,hwmods = "timer3";
linux,phandle = <0x37>;
phandle = <0x37>;
};
timer@48044000 {
compatible = "ti,am335x-timer";
reg = <0x48044000 0x400>;
interrupts = <0x5c>;
ti,hwmods = "timer4";
ti,timer-pwm;
linux,phandle = <0x38>;
phandle = <0x38>;
};
timer@48046000 {
compatible = "ti,am335x-timer";
reg = <0x48046000 0x400>;
interrupts = <0x5d>;
ti,hwmods = "timer5";
ti,timer-pwm;
linux,phandle = <0x39>;
phandle = <0x39>;
};
timer@48048000 {
compatible = "ti,am335x-timer";
reg = <0x48048000 0x400>;
interrupts = <0x5e>;
ti,hwmods = "timer6";
ti,timer-pwm;
linux,phandle = <0x3a>;
phandle = <0x3a>;
};
timer@4804a000 {
compatible = "ti,am335x-timer";
reg = <0x4804a000 0x400>;
interrupts = <0x5f>;
ti,hwmods = "timer7";
ti,timer-pwm;
linux,phandle = <0x3b>;
phandle = <0x3b>;
};
rtc@44e3e000 {
compatible = "ti,da830-rtc";
reg = <0x44e3e000 0x1000>;
interrupts = <0x4b 0x4c>;
ti,hwmods = "rtc";
};
spi@48030000 {
compatible = "ti,omap4-mcspi";
#address-cells = <0x1>;
#size-cells = <0x0>;
reg = <0x48030000 0x400>;
interrupts = <0x41>;
ti,spi-num-cs = <0x2>;
ti,hwmods = "spi0";
dmas = <0x7 0x10 0x7 0x11 0x7 0x12 0x7 0x13>;
dma-names = "tx0", "rx0", "tx1", "rx1";
status = "disabled";
linux,phandle = <0x3c>;
phandle = <0x3c>;
};
spi@481a0000 {
compatible = "ti,omap4-mcspi";
#address-cells = <0x1>;
#size-cells = <0x0>;
reg = <0x481a0000 0x400>;
interrupts = <0x7d>;
ti,spi-num-cs = <0x2>;
ti,hwmods = "spi1";
dmas = <0x7 0x2a 0x7 0x2b 0x7 0x2c 0x7 0x2d>;
dma-names = "tx0", "rx0", "tx1", "rx1";
status = "disabled";
linux,phandle = <0x3d>;
phandle = <0x3d>;
};
usb@47400000 {
compatible = "ti,am33xx-usb";
reg = <0x47400000 0x1000>;
ranges;
#address-cells = <0x1>;
#size-cells = <0x1>;
ti,hwmods = "usb_otg_hs";
status = "okay";
linux,phandle = <0x3e>;
phandle = <0x3e>;
control@44e10000 {
compatible = "ti,am335x-usb-ctrl-module";
reg = <0x44e10620 0x10 0x44e10648 0x4>;
reg-names = "phy_ctrl", "wakeup";
status = "okay";
linux,phandle = <0xd>;
phandle = <0xd>;
};
usb-phy@47401300 {
compatible = "ti,am335x-usb-phy";
reg = <0x47401300 0x100>;
reg-names = "phy";
status = "okay";
ti,ctrl_mod = <0xd>;
linux,phandle = <0xe>;
phandle = <0xe>;
};
usb@47401000 {
compatible = "ti,musb-am33xx";
status = "okay";
reg = <0x47401400 0x400 0x47401000 0x200>;
reg-names = "mc", "control";
interrupts = <0x12>;
interrupt-names = "mc";
dr_mode = "otg";
mentor,multipoint = <0x1>;
mentor,num-eps = <0x10>;
mentor,ram-bits = <0xc>;
mentor,power = <0x1f4>;
phys = <0xe>;
dmas = <0xf 0x0 0x0 0xf 0x1 0x0 0xf 0x2 0x0 0xf 0x3 0x0 0xf 0x4 0x0 0xf 0x5 0x0 0xf 0x6 0x0 0xf 0x7 0x0 0xf 0x8 0x0 0xf 0x9 0x0 0xf 0xa 0x0 0xf 0xb 0x0 0xf 0xc 0x0 0xf 0xd 0x0 0xf 0xe 0x0 0xf 0x0 0x1 0xf 0x1 0x1 0xf 0x2 0x1 0xf 0x3 0x1 0xf 0x4 0x1 0xf 0x5 0x1 0xf 0x6 0x1 0xf 0x7 0x1 0xf 0x8 0x1 0xf 0x9 0x1 0xf 0xa 0x1 0xf 0xb 0x1 0xf 0xc 0x1 0xf 0xd 0x1 0xf 0xe 0x1>;
dma-names = "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7", "rx8", "rx9", "rx10", "rx11", "rx12", "rx13", "rx14", "rx15", "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7", "tx8", "tx9", "tx10", "tx11", "tx12", "tx13", "tx14", "tx15";
linux,phandle = <0x3f>;
phandle = <0x3f>;
};
usb-phy@47401b00 {
compatible = "ti,am335x-usb-phy";
reg = <0x47401b00 0x100>;
reg-names = "phy";
status = "okay";
ti,ctrl_mod = <0xd>;
linux,phandle = <0x10>;
phandle = <0x10>;
};
usb@47401800 {
compatible = "ti,musb-am33xx";
status = "okay";
reg = <0x47401c00 0x400 0x47401800 0x200>;
reg-names = "mc", "control";
interrupts = <0x13>;
interrupt-names = "mc";
dr_mode = "host";
mentor,multipoint = <0x1>;
mentor,num-eps = <0x10>;
mentor,ram-bits = <0xc>;
mentor,power = <0x1f4>;
phys = <0x10>;
dmas = <0xf 0xf 0x0 0xf 0x10 0x0 0xf 0x11 0x0 0xf 0x12 0x0 0xf 0x13 0x0 0xf 0x14 0x0 0xf 0x15 0x0 0xf 0x16 0x0 0xf 0x17 0x0 0xf 0x18 0x0 0xf 0x19 0x0 0xf 0x1a 0x0 0xf 0x1b 0x0 0xf 0x1c 0x0 0xf 0x1d 0x0 0xf 0xf 0x1 0xf 0x10 0x1 0xf 0x11 0x1 0xf 0x12 0x1 0xf 0x13 0x1 0xf 0x14 0x1 0xf 0x15 0x1 0xf 0x16 0x1 0xf 0x17 0x1 0xf 0x18 0x1 0xf 0x19 0x1 0xf 0x1a 0x1 0xf 0x1b 0x1 0xf 0x1c 0x1 0xf 0x1d 0x1>;
dma-names = "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7", "rx8", "rx9", "rx10", "rx11", "rx12", "rx13", "rx14", "rx15", "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7", "tx8", "tx9", "tx10", "tx11", "tx12", "tx13", "tx14", "tx15";
linux,phandle = <0x40>;
phandle = <0x40>;
};
dma-controller@07402000 {
compatible = "ti,am3359-cppi41";
reg = <0x47400000 0x1000 0x47402000 0x1000 0x47403000 0x1000 0x47404000 0x4000>;
reg-names = "glue", "controller", "scheduler", "queuemgr";
interrupts = <0x11>;
interrupt-names = "glue";
#dma-cells = <0x2>;
#dma-channels = <0x1e>;
#dma-requests = <0x100>;
status = "okay";
linux,phandle = <0xf>;
phandle = <0xf>;
};
};
epwmss@48300000 {
compatible = "ti,am33xx-pwmss";
reg = <0x48300000 0x10>;
ti,hwmods = "epwmss0";
#address-cells = <0x1>;
#size-cells = <0x1>;
status = "disabled";
ranges = <0x48300100 0x48300100 0x80 0x48300180 0x48300180 0x80 0x48300200 0x48300200 0x80>;
linux,phandle = <0x41>;
phandle = <0x41>;
ecap@48300100 {
compatible = "ti,am33xx-ecap";
#pwm-cells = <0x3>;
reg = <0x48300100 0x80>;
ti,hwmods = "ecap0";
status = "disabled";
linux,phandle = <0x42>;
phandle = <0x42>;
};
ehrpwm@48300200 {
compatible = "ti,am33xx-ehrpwm";
#pwm-cells = <0x3>;
reg = <0x48300200 0x80>;
ti,hwmods = "ehrpwm0";
status = "disabled";
linux,phandle = <0x43>;
phandle = <0x43>;
};
};
epwmss@48302000 {
compatible = "ti,am33xx-pwmss";
reg = <0x48302000 0x10>;
ti,hwmods = "epwmss1";
#address-cells = <0x1>;
#size-cells = <0x1>;
status = "disabled";
ranges = <0x48302100 0x48302100 0x80 0x48302180 0x48302180 0x80 0x48302200 0x48302200 0x80>;
linux,phandle = <0x44>;
phandle = <0x44>;
ecap@48302100 {
compatible = "ti,am33xx-ecap";
#pwm-cells = <0x3>;
reg = <0x48302100 0x80>;
ti,hwmods = "ecap1";
status = "disabled";
linux,phandle = <0x45>;
phandle = <0x45>;
};
ehrpwm@48302200 {
compatible = "ti,am33xx-ehrpwm";
#pwm-cells = <0x3>;
reg = <0x48302200 0x80>;
ti,hwmods = "ehrpwm1";
status = "disabled";
linux,phandle = <0x46>;
phandle = <0x46>;
};
};
epwmss@48304000 {
compatible = "ti,am33xx-pwmss";
reg = <0x48304000 0x10>;
ti,hwmods = "epwmss2";
#address-cells = <0x1>;
#size-cells = <0x1>;
status = "disabled";
ranges = <0x48304100 0x48304100 0x80 0x48304180 0x48304180 0x80 0x48304200 0x48304200 0x80>;
linux,phandle = <0x47>;
phandle = <0x47>;
ecap@48304100 {
compatible = "ti,am33xx-ecap";
#pwm-cells = <0x3>;
reg = <0x48304100 0x80>;
ti,hwmods = "ecap2";
status = "disabled";
linux,phandle = <0x48>;
phandle = <0x48>;
};
ehrpwm@48304200 {
compatible = "ti,am33xx-ehrpwm";
#pwm-cells = <0x3>;
reg = <0x48304200 0x80>;
ti,hwmods = "ehrpwm2";
status = "disabled";
linux,phandle = <0x49>;
phandle = <0x49>;
};
};
ethernet@4a100000 {
compatible = "ti,cpsw";
ti,hwmods = "cpgmac0";
cpdma_channels = <0x8>;
ale_entries = <0x400>;
bd_ram_size = <0x2000>;
no_bd_ram = <0x0>;
rx_descs = <0x40>;
mac_control = <0x20>;
slaves = <0x2>;
active_slave = <0x0>;
cpts_clock_mult = <0x80000000>;
cpts_clock_shift = <0x1d>;
reg = <0x4a100000 0x800 0x4a101200 0x100>;
#address-cells = <0x1>;
#size-cells = <0x1>;
interrupt-parent = <0x1>;
interrupts = <0x28 0x29 0x2a 0x2b>;
ranges;
pinctrl-names = "default", "sleep";
pinctrl-0 = <0x11>;
pinctrl-1 = <0x12>;
linux,phandle = <0x4a>;
phandle = <0x4a>;
mdio@4a101000 {
compatible = "ti,davinci_mdio";
#address-cells = <0x1>;
#size-cells = <0x0>;
ti,hwmods = "davinci_mdio";
bus_freq = <0xf4240>;
reg = <0x4a101000 0x100>;
pinctrl-names = "default", "sleep";
pinctrl-0 = <0x13>;
pinctrl-1 = <0x14>;
linux,phandle = <0x15>;
phandle = <0x15>;
};
slave@4a100200 {
mac-address = [00 00 00 00 00 00];
phy_id = <0x15 0x0>;
phy-mode = "mii";
linux,phandle = <0x4b>;
phandle = <0x4b>;
};
slave@4a100300 {
mac-address = [00 00 00 00 00 00];
phy_id = <0x15 0x1>;
phy-mode = "mii";
linux,phandle = <0x4c>;
phandle = <0x4c>;
};
};
ocmcram@40300000 {
compatible = "ti,am3352-ocmcram";
reg = <0x40300000 0x10000>;
ti,hwmods = "ocmcram";
linux,phandle = <0x4d>;
phandle = <0x4d>;
};
wkup_m3@44d00000 {
compatible = "ti,am3353-wkup-m3";
reg = <0x44d00000 0x4000 0x44d80000 0x2000>;
ti,hwmods = "wkup_m3";
linux,phandle = <0x4e>;
phandle = <0x4e>;
};
elm@48080000 {
compatible = "ti,am3352-elm";
reg = <0x48080000 0x2000>;
interrupts = <0x4>;
ti,hwmods = "elm";
status = "disabled";
linux,phandle = <0x4f>;
phandle = <0x4f>;
};
tscadc@44e0d000 {
compatible = "ti,am3359-tscadc";
reg = <0x44e0d000 0x1000>;
interrupt-parent = <0x1>;
interrupts = <0x10>;
ti,hwmods = "adc_tsc";
status = "disabled";
linux,phandle = <0x50>;
phandle = <0x50>;
tsc {
compatible = "ti,am3359-tsc";
};
adc {
#io-channel-cells = <0x1>;
compatible = "ti,am3359-adc";
linux,phandle = <0x51>;
phandle = <0x51>;
};
};
gpmc@50000000 {
compatible = "ti,am3352-gpmc";
ti,hwmods = "gpmc";
reg = <0x50000000 0x2000>;
interrupts = <0x64>;
gpmc,num-cs = <0x7>;
gpmc,num-waitpins = <0x2>;
#address-cells = <0x2>;
#size-cells = <0x1>;
status = "disabled";
linux,phandle = <0x52>;
phandle = <0x52>;
};
};
leds {
pinctrl-names = "default";
pinctrl-0 = <0x16>;
compatible = "gpio-leds";
led@2 {
label = "beaglebone:green:heartbeat";
gpios = <0xc 0x15 0x0>;
linux,default-trigger = "heartbeat";
default-state = "off";
};
led@3 {
label = "beaglebone:green:mmc0";
gpios = <0xc 0x16 0x0>;
linux,default-trigger = "mmc0";
default-state = "off";
};
led@4 {
label = "beaglebone:green:usr2";
gpios = <0xc 0x17 0x0>;
linux,default-trigger = "cpu0";
default-state = "off";
};
led@5 {
label = "beaglebone:green:usr3";
gpios = <0xc 0x18 0x0>;
linux,default-trigger = "mmc1";
default-state = "off";
};
};
bone_capemgr {
compatible = "ti,bone-capemgr";
status = "okay";
eeprom = <0x17>;
baseboardmaps {
board@0 {
board-name = "A335BONE";
compatible-name = "ti,beaglebone";
linux,phandle = <0x53>;
phandle = <0x53>;
};
board@1 {
board-name = "A335BNLT";
compatible-name = "ti,beaglebone-black";
linux,phandle = <0x54>;
phandle = <0x54>;
};
};
slots {
slot@0 {
eeprom = <0x18>;
};
slot@1 {
eeprom = <0x19>;
};
slot@2 {
eeprom = <0x1a>;
};
slot@3 {
eeprom = <0x1b>;
};
slot@100 {
ti,cape-override;
priority = <0x1>;
compatible = "ti,beaglebone-black";
board-name = "Bone-LT-eMMC-2G";
version = "00A0";
manufacturer = "Texas Instruments";
part-number = "BB-BONE-EMMC-2G";
};
slot@101 {
ti,cape-override;
priority = <0x1>;
compatible = "ti,beaglebone-black";
board-name = "Bone-Black-HDMI";
version = "00A0";
manufacturer = "Texas Instruments";
part-number = "BB-BONELT-HDMI";
};
slot@102 {
ti,cape-override;
priority = <0x2>;
compatible = "ti,beaglebone-black";
board-name = "Bone-Black-HDMIN";
version = "00A0";
manufacturer = "Texas Instruments";
part-number = "BB-BONELT-HDMIN";
};
};
capemaps {
};
};
fb@4830e000 {
compatible = "ti,am33xx-tilcdc";
reg = <0x4830e000 0x1000>;
interrupt-parent = <0x1>;
interrupts = <0x24>;
ti,hwmods = "lcdc";
linux,phandle = <0x55>;
phandle = <0x55>;
};
hdmi {
compatible = "ti,tilcdc,slave";
i2c = <0x1c>;
pinctrl-names = "default";
pinctrl-0 = <0x1d>;
status = "okay";
linux,phandle = <0x56>;
phandle = <0x56>;
panel-info {
bpp = <0x10>;
ac-bias = <0xff>;
ac-bias-intrpt = <0x0>;
dma-burst-sz = <0x10>;
fdd = <0x10>;
sync-edge = <0x1>;
sync-ctrl = <0x1>;
raster-order = <0x0>;
fifo-th = <0x0>;
invert-pxl-clk;
};
};
__symbols__ {
am33xx_pinmux = "/pinmux@44e10800";
user_leds_s0 = "/pinmux@44e10800/user_leds_s0";
i2c0_pins = "/pinmux@44e10800/pinmux_i2c0_pins";
uart0_pins = "/pinmux@44e10800/pinmux_uart0_pins";
clkout2_pin = "/pinmux@44e10800/pinmux_clkout2_pin";
cpsw_default = "/pinmux@44e10800/cpsw_default";
cpsw_sleep = "/pinmux@44e10800/cpsw_sleep";
davinci_mdio_default = "/pinmux@44e10800/davinci_mdio_default";
davinci_mdio_sleep = "/pinmux@44e10800/davinci_mdio_sleep";
i2c2_pins = "/pinmux@44e10800/pinmux_i2c2_pins";
mmc1_pins = "/pinmux@44e10800/pinmux_mmc1_pins";
nxp_hdmi_bonelt_pins = "/pinmux@44e10800/nxp_hdmi_bonelt_pins";
intc = "/ocp/interrupt-controller@48200000";
edma = "/ocp/edma@49000000";
gpio0 = "/ocp/gpio@44e07000";
gpio1 = "/ocp/gpio@4804c000";
gpio2 = "/ocp/gpio@481ac000";
gpio3 = "/ocp/gpio@481ae000";
uart0 = "/ocp/serial@44e09000";
uart1 = "/ocp/serial@48022000";
uart2 = "/ocp/serial@48024000";
uart3 = "/ocp/serial@481a6000";
uart4 = "/ocp/serial@481a8000";
uart5 = "/ocp/serial@481aa000";
i2c0 = "/ocp/i2c@44e0b000";
tps = "/ocp/i2c@44e0b000/tps@24";
dcdc1_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@0";
dcdc2_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@1";
dcdc3_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@2";
ldo1_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@3";
ldo2_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@4";
ldo3_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@5";
ldo4_reg = "/ocp/i2c@44e0b000/tps@24/regulators/regulator@6";
vmmcsd_fixed = "/ocp/i2c@44e0b000/tps@24/fixedregulator@0";
baseboard_eeprom = "/ocp/i2c@44e0b000/baseboard_eeprom@50";
i2c1 = "/ocp/i2c@4802a000";
i2c2 = "/ocp/i2c@4819c000";
cape_eeprom0 = "/ocp/i2c@4819c000/cape_eeprom0@54";
cape_eeprom1 = "/ocp/i2c@4819c000/cape_eeprom1@55";
cape_eeprom2 = "/ocp/i2c@4819c000/cape_eeprom2@56";
cape_eeprom3 = "/ocp/i2c@4819c000/cape_eeprom3@57";
mmc1 = "/ocp/mmc@48060000";
mmc2 = "/ocp/mmc@481d8000";
mmc3 = "/ocp/mmc@47810000";
wdt2 = "/ocp/wdt@44e35000";
dcan0 = "/ocp/d_can@481cc000";
dcan1 = "/ocp/d_can@481d0000";
timer1 = "/ocp/timer@44e31000";
timer2 = "/ocp/timer@48040000";
timer3 = "/ocp/timer@48042000";
timer4 = "/ocp/timer@48044000";
timer5 = "/ocp/timer@48046000";
timer6 = "/ocp/timer@48048000";
timer7 = "/ocp/timer@4804a000";
spi0 = "/ocp/spi@48030000";
spi1 = "/ocp/spi@481a0000";
musb = "/ocp/usb@47400000";
usb = "/ocp/usb@47400000";
ctrl_mod = "/ocp/usb@47400000/control@44e10000";
usb0_phy = "/ocp/usb@47400000/usb-phy@47401300";
usb0 = "/ocp/usb@47400000/usb@47401000";
usb1_phy = "/ocp/usb@47400000/usb-phy@47401b00";
usb1 = "/ocp/usb@47400000/usb@47401800";
cppi41dma = "/ocp/usb@47400000/dma-controller@07402000";
epwmss0 = "/ocp/epwmss@48300000";
ecap0 = "/ocp/epwmss@48300000/ecap@48300100";
ehrpwm0 = "/ocp/epwmss@48300000/ehrpwm@48300200";
epwmss1 = "/ocp/epwmss@48302000";
ecap1 = "/ocp/epwmss@48302000/ecap@48302100";
ehrpwm1 = "/ocp/epwmss@48302000/ehrpwm@48302200";
epwmss2 = "/ocp/epwmss@48304000";
ecap2 = "/ocp/epwmss@48304000/ecap@48304100";
ehrpwm2 = "/ocp/epwmss@48304000/ehrpwm@48304200";
mac = "/ocp/ethernet@4a100000";
davinci_mdio = "/ocp/ethernet@4a100000/mdio@4a101000";
cpsw_emac0 = "/ocp/ethernet@4a100000/slave@4a100200";
cpsw_emac1 = "/ocp/ethernet@4a100000/slave@4a100300";
ocmcram = "/ocp/ocmcram@40300000";
wkup_m3 = "/ocp/wkup_m3@44d00000";
elm = "/ocp/elm@48080000";
tscadc = "/ocp/tscadc@44e0d000";
am335x_adc = "/ocp/tscadc@44e0d000/adc";
gpmc = "/ocp/gpmc@50000000";
baseboard_beaglebone = "/bone_capemgr/baseboardmaps/board@0";
baseboard_beaglebone_black = "/bone_capemgr/baseboardmaps/board@1";
fb = "/fb@4830e000";
hdmi = "/hdmi";
};
__fixups__ {
emmc_pins = "/ocp/mmc@481d8000:pinctrl-0:0";
};
};
@arthurafarias
Copy link

Hello

I would like to know of I should compile dts on target hardware (beaglebone black) or it is possible to do it at the working PC.

Arthur

@krs013
Copy link

krs013 commented Feb 6, 2016

The link is no longer correct. I once found a good link, but I forgot how it worked. The closest I can come is the PKGBUILD "snapshot." https://aur.archlinux.org/cgit/aur.git/snapshot/dtc-git-patched.tar.gz

@dmr
Copy link

dmr commented Mar 29, 2016

dtc returns "dtc: invalid option -- '@'"

How did you guys solve it?

@hcorion
Copy link

hcorion commented Nov 9, 2016

Is compiling dtc-git-patched still neccesary? Last updated 2013, wouldn't they have merged that by now?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment