Enable RTDM SPI on BeagleBone Black
PATCH 1/1 Enable RTDM SPI on BeagleBone Black
From dbc3add6bb3130d40602d3144d152acc0e0e3bd9 Mon Sep 17 00:00:00 2001
From: Deniz Ugur <[email protected]>
Date: Wed, 11 Nov 2020 22:23:03 +0300
Subject: [xenomai-images][PATCH 1/1][REV 2] Enable RTDM SPI on BeagleBone Black
To: [email protected]
Cc: [email protected]
Indentation was messed up on previous post. This one fixes it.
--- recipes-core/customizations/customizations.bb | 9 +- recipes-core/customizations/files/post-bbb | 5 + ...01-BeagleBone-Black-RTDM-SPI-enabled.patch | 110 ++++++++++++++++++ recipes-kernel/linux/files/bbb.cfg | 28 +++++ recipes-kernel/linux/linux-xenomai.inc | 9 +- 5 files changed, 159 insertions(+), 2 deletions(-) create mode 100644 recipes-core/customizations/files/post-bbb create mode 100644 recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch create mode 100644 recipes-kernel/linux/files/bbb.cfg
recipes-core/customizations/customizations.bb +8 -1
@@ -13,10 +13,17 @@ inherit dpkg-raw DESCRIPTION = "demo image customizations" +def is_bbb(d): + bbb = d.getVar('MACHINE') or '' + if bbb == 'beagle-bone-black': + return "file://post-bbb" + return "" + SRC_URI = " \ file://postinst \ file://ethernet \ - file://99-silent-printk.conf" + file://99-silent-printk.conf \ + ${@is_bbb(d)}" DEBIAN_DEPENDS = "passwd"
recipes-core/customizations/files/post-bbb new file +5 -0
@@ -0,0 +1,5 @@ +#!/bin/sh + +# Disable HDMI in order to enable SPI1 on BeagleBone Black +echo "enable_uboot_overlays=1" >> /boot/uEnv.txt +echo "disable_uboot_overlay_video=1" >> /boot/uEnv.txt
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +110 -0
111 lines not on this page · raw message
recipes-kernel/linux/files/bbb.cfg new file +28 -0
@@ -0,0 +1,28 @@ +# Disable conflicting drivers +CONFIG_XENO_DRIVERS_SPI_BCM2835=n +CONFIG_XENO_DRIVERS_SPI_SUN6I=n +CONFIG_SPI_ATMEL=n +CONFIG_SPI_BCM2835=n +CONFIG_SPI_BCM2835AUX=n +CONFIG_SPI_BCM_QSPI=n +CONFIG_SPI_BITBANG=n +CONFIG_SPI_CADENCE=n +CONFIG_SPI_DAVINCI=n +CONFIG_SPI_GPIO=n +CONFIG_SPI_FSL_DSPI=n +CONFIG_SPI_OMAP24XX=n +CONFIG_SPI_ORION=n +CONFIG_SPI_PL022=n +CONFIG_SPI_ROCKCHIP=n +CONFIG_SPI_RSPI=n +CONFIG_SPI_S3C64XX=n +CONFIG_SPI_SH_MSIOF=n +CONFIG_SPI_SH_HSPI=n +CONFIG_SPI_SIRF=n +CONFIG_SPI_SUN4I=n +CONFIG_SPI_SUN6I=n +CONFIG_SPI_TEGRA114=n +CONFIG_SPI_TEGRA20_SFLASH=n +CONFIG_SPI_TEGRA20_SLINK=n +CONFIG_SPI_XILINX=n +CONFIG_SPI_SPIDEV=n
recipes-kernel/linux/linux-xenomai.inc +8 -1
@@ -13,7 +13,14 @@ require recipes-kernel/linux/linux-custom.inc KERNEL_DEFCONFIG ?= "${DISTRO_ARCH}_defconfig" -SRC_URI += "file://${KERNEL_DEFCONFIG}" +def is_bbb(d): + bbb = d.getVar('MACHINE') or '' + if bbb == 'beagle-bone-black': + return "file://0001-BeagleBone-Black-RTDM-SPI-enabled.patch file://bbb.cfg" + return "" + +SRC_URI += "file://${KERNEL_DEFCONFIG} \ + ${@is_bbb(d)}" DEPENDS += "xenomai-kernel-source" KBUILD_DEPENDS += "xenomai-kernel-source"
Signature · 1 line
2.17.1
Quoted 9 lines · Deniz Uğur via Xenomai
From
dbc3add6bb3130d40602d3144d152acc0e0e3bd9Mon Sep 17 00:00:00 2001
From: Deniz Ugur <[email protected]>
Date: Wed, 11 Nov 2020 22:23:03 +0300
Subject: [xenomai-images][PATCH 1/1][REV 2] Enable RTDM SPI on BeagleBone Black
To: [email protected]
Cc: [email protected]Indentation was messed up on previous post. This one fixes it.
This is not place to put some kind or "versioning" info. It's rather the place to put your commit message, explaining *why* we want this change.
Also missing: signed-off-by (DCO, https://developercertificate.org/).
Quoted 21 lines
--- recipes-core/customizations/customizations.bb | 9 +- recipes-core/customizations/files/post-bbb | 5 + ...01-BeagleBone-Black-RTDM-SPI-enabled.patch | 110 ++++++++++++++++++ recipes-kernel/linux/files/bbb.cfg | 28 +++++ recipes-kernel/linux/linux-xenomai.inc | 9 +- 5 files changed, 159 insertions(+), 2 deletions(-) create mode 100644 recipes-core/customizations/files/post-bbb create mode 100644 recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch create mode 100644 recipes-kernel/linux/files/bbb.cfgrecipes-core/customizations/customizations.bb +2
-0@@ -13,10 +13,17 @@ inherit dpkg-raw DESCRIPTION = "demo image customizations" +def is_bbb(d): + bbb = d.getVar('MACHINE') or ''
recipes-core/customizations/customizations.bb inherit dpkg-raw · line 26
Quoted 10 lines
recipes-core/customizations/customizations.bb +6
-1+ if bbb == 'beagle-bone-black': + return "file://post-bbb" + return "" + SRC_URI = " \ file://postinst \ file://ethernet \ - file://99-silent-printk.conf" + file://99-silent-printk.conf \ + ${@is_bbb(d)}"
bitbake override magic can be used here:
SRC_URI_append_beagle-bone-black = ...
recipes-core/customizations/files/post-bbb line 4
Quoted 13 lines
recipes-core/customizations/customizations.bb +0
-0DEBIAN_DEPENDS = "passwd"recipes-core/customizations/files/post-bbb new file +4
-0@@ -0,0 +1,5 @@ +#!/bin/sh + +# Disable HDMI in order to enable SPI1 on BeagleBone Black +echo "enable_uboot_overlays=1" >> /boot/uEnv.txt
Why do we need to *enable* overlays first...
recipes-core/customizations/files/post-bbb line 5
Quoted 1 line
recipes-core/customizations/files/post-bbb new file +1
-0+echo "disable_uboot_overlay_video=1" >> /boot/uEnv.txt
...in order to disable a specific one?
Quoted 18 lines
\ No newline at end of file
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +11
-0@@ -0,0 +1,110 @@ +From 1badee8e16340d063f8bff04c39c9fd3d6749a8f Mon Sep 17 00:00:00 2001 +From: Deniz Ugur <[email protected]> +Date: Mon, 9 Nov 2020 20:19:49 +0300 +Subject: [PATCH] BeagleBone Black RTDM SPI enabled + +--- + arch/arm/boot/dts/am335x-bone-common.dtsi | 2 + + arch/arm/boot/dts/am335x-boneblack-spi.dtsi | 77 +++++++++++++++++++++ + 2 files changed, 79 insertions(+) + create mode 100644 arch/arm/boot/dts/am335x-boneblack-spi.dtsi +
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch line 21
Quoted 10 lines
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +10
-0+diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi b/arch/arm/boot/dts/am335x-bone-common.dtsi +index 73b514ddd..91ccc0f4b 100644 +--- a/arch/arm/boot/dts/am335x-bone-common.dtsi ++++ b/arch/arm/boot/dts/am335x-bone-common.dtsi +@@ -6,6 +6,8 @@ + * published by the Free Software Foundation. + */ + ++#include "am335x-boneblack-spi.dtsi" ++
I think we should rather patch that into am335x-boneblack.dts.
Quoted 96 lines
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +89
-0+ / { + cpus { + cpu@0 { +diff --git a/arch/arm/boot/dts/am335x-boneblack-spi.dtsi b/arch/arm/boot/dts/am335x-boneblack-spi.dtsi +new file mode 100644 +index 000000000..47485af64 +--- /dev/null ++++ b/arch/arm/boot/dts/am335x-boneblack-spi.dtsi +@@ -0,0 +1,77 @@ ++&am33xx_pinmux { ++ spi0_pins: pinmux_spi0_pins { ++ pinctrl-single,pins = < ++ /* This output signal is also used as a re-timing input. */ ++ 0x150 0x30 /* P9_22 spi0_sclk, INPUT_PULLUP | MODE0 */ ++ 0x154 0x30 /* P9_21 spi0_d0, INPUT_PULLUP | MODE0 */ ++ 0x158 0x10 /* P9_18 spi0_d1, OUTPUT_PULLUP | MODE0 */ ++ 0x15c 0x10 /* P9_17 spi0_cs0, OUTPUT_PULLUP | MODE0 */ ++ >; ++ }; ++ ++ spi1_pins: pinmux_spi1_pins { ++ pinctrl-single,pins = < ++ /* This output signal is also used as a re-timing input. */ ++ 0x190 0x33 /* P9_31 spi1_sclk, INPUT_PULLUP | MODE3 */ ++ 0x194 0x33 /* P9_29 spi1_d0, INPUT_PULLUP | MODE3 */ ++ 0x198 0x13 /* P9_30 spi1_d1, OUTPUT_PULLUP | MODE3 */ ++ 0x19c 0x13 /* P9_28 spi1_cs0, OUTPUT_PULLUP | MODE3 */ ++ 0x164 0x12 /* P9_42 spi1_cs1 OUTPUT_PULLUP | MODE2 */ ++ >; ++ }; ++}; ++ ++&spi0 { ++ compatible = "ti,omap4-mcspi"; ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ reg = <0x48030000 0x400>; ++ interrupts = <0x41>; ++ ti,spi-num-cs = <0x2>; ++ ti,hwmods = "spi0"; ++ dmas = <0x27 0x10 0x0 0x27 0x11 0x0 0x27 0x12 0x0 0x27 0x13 0x0>; ++ dma-names = "tx0", "rx0", "tx1", "rx1"; ++ status = "okay"; ++ pinctrl-names = "default"; ++ pinctrl-0 = <&spi0_pins>; ++ ++ channel0@0 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x0>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++}; ++ ++&spi1 { ++ compatible = "ti,omap4-mcspi"; ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ reg = <0x481a0000 0x400>; ++ interrupts = <0x7d>; ++ ti,spi-num-cs = <0x2>; ++ ti,hwmods = "spi1"; ++ dmas = <0x27 0x2a 0x0 0x27 0x2b 0x0 0x27 0x2c 0x0 0x27 0x2d 0x0>; ++ dma-names = "tx0", "rx0", "tx1", "rx1"; ++ status = "okay"; ++ pinctrl-names = "default"; ++ pinctrl-0 = <&spi1_pins>; ++ ++ channel1@0 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x0>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++ ++ channel1@1 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x1>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++ ++}; +\ No newline at end of file +-- +2.17.1recipes-kernel/linux/files/bbb.cfg new file +0
-0
recipes-kernel/linux/files/bbb.cfg line 1
Quoted 1 line
recipes-kernel/linux/files/bbb.cfg new file +1
-0@@ -0,0 +1,28 @@ +# Disable conflicting drivers
How can non-matching drivers be in conflict? Most of those below do not match on any of the DT entries on the BBB.
Quoted 36 lines
recipes-kernel/linux/files/bbb.cfg new file +27
-0+CONFIG_XENO_DRIVERS_SPI_BCM2835=n +CONFIG_XENO_DRIVERS_SPI_SUN6I=n +CONFIG_SPI_ATMEL=n +CONFIG_SPI_BCM2835=n +CONFIG_SPI_BCM2835AUX=n +CONFIG_SPI_BCM_QSPI=n +CONFIG_SPI_BITBANG=n +CONFIG_SPI_CADENCE=n +CONFIG_SPI_DAVINCI=n +CONFIG_SPI_GPIO=n +CONFIG_SPI_FSL_DSPI=n +CONFIG_SPI_OMAP24XX=n +CONFIG_SPI_ORION=n +CONFIG_SPI_PL022=n +CONFIG_SPI_ROCKCHIP=n +CONFIG_SPI_RSPI=n +CONFIG_SPI_S3C64XX=n +CONFIG_SPI_SH_MSIOF=n +CONFIG_SPI_SH_HSPI=n +CONFIG_SPI_SIRF=n +CONFIG_SPI_SUN4I=n +CONFIG_SPI_SUN6I=n +CONFIG_SPI_TEGRA114=n +CONFIG_SPI_TEGRA20_SFLASH=n +CONFIG_SPI_TEGRA20_SLINK=n +CONFIG_SPI_XILINX=n +CONFIG_SPI_SPIDEV=nrecipes-kernel/linux/linux-xenomai.inc +0
-0@@ -13,7 +13,14 @@ require recipes-kernel/linux/linux-custom.inc KERNEL_DEFCONFIG ?= "${DISTRO_ARCH}_defconfig"
recipes-kernel/linux/linux-xenomai.inc require recipes-kernel/linux/linux-custom.inc · line 24
Quoted 10 lines
recipes-kernel/linux/linux-xenomai.inc +8
-1-SRC_URI += "file://${KERNEL_DEFCONFIG}" +def is_bbb(d): + bbb = d.getVar('MACHINE') or '' + if bbb == 'beagle-bone-black': + return "file://0001-BeagleBone-Black-RTDM-SPI-enabled.patch file://bbb.cfg" + return "" + +SRC_URI += "file://${KERNEL_DEFCONFIG} \ + ${@is_bbb(d)}"
Same as above.
recipes-kernel/linux/linux-xenomai.inc require recipes-kernel/linux/linux-custom.inc · line 26
Quoted 3 lines
recipes-kernel/linux/linux-xenomai.inc +0
-0DEPENDS += "xenomai-kernel-source" KBUILD_DEPENDS += "xenomai-kernel-source"
Looks good otherwise. The smaller your patch becomes, the better it is already ;).
Thanks,
Jan
Signature · 2 lines
Siemens AG, T RDA IOT Corporate Competence Center Embedded Linux
Quoted 2 lines
This is not place to put some kind or "versioning" info. It's rather the place to put your commit message, explaining *why* we want this change.
I wish it was possible to delete the previous mail, otherwise I wouldn’t write that.
Quoted 5 lines
Why do we need to *enable* overlays first...
Quoted 1 line
+echo "disable_uboot_overlay_video=1" >>
/boot/uEnv.txt...in order to disable a specific one?
I’ve tried every combination but without these, BBB doesn’t seem to be booting.
Quoted 2 lines
How can non-matching drivers be in conflict? Most of those below do not match on any of the DT entries on the BBB.
I took the liberty of trying every combination again but just disabling CONFIG_SPI_SPIDEV wasn’t enough. In every other case, driver wasn’t loading and dumping stack trace to kernel logs.
Quoted 2 lines
Looks good otherwise. The smaller your patch becomes, the better it is already ;).
Thank you. I agree with you, most of my changes are cumbersome.
Quoted 267 lines · Jan Kiszka
Quoted 9 lines · Deniz Uğur via Xenomai
From
dbc3add6bb3130d40602d3144d152acc0e0e3bd9Mon Sep 17 00:00:00 2001
From: Deniz Ugur <[email protected] <mailto:[email protected]>>
Date: Wed, 11 Nov 2020 22:23:03 +0300
Subject: [xenomai-images][PATCH 1/1][REV 2] Enable RTDM SPI on BeagleBone Black
To: [email protected] <mailto:[email protected]>
Cc: [email protected] <mailto:[email protected]>Indentation was messed up on previous post. This one fixes it.
This is not place to put some kind or "versioning" info. It's rather the place to put your commit message, explaining *why* we want this change.
Also missing: signed-off-by (DCO, https://developercertificate.org/ <https://developercertificate.org/>).
Quoted 28 lines
---
recipes-core/customizations/customizations.bb | 9 +- recipes-core/customizations/files/post-bbb | 5 + ...01-BeagleBone-Black-RTDM-SPI-enabled.patch | 110 ++++++++++++++++++ recipes-kernel/linux/files/bbb.cfg | 28 +++++ recipes-kernel/linux/linux-xenomai.inc | 9 +- 5 files changed, 159 insertions(+), 2 deletions(-)create mode 100644 recipes-core/customizations/files/post-bbb
create mode 100644recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patchcreate mode 100644 recipes-kernel/linux/files/bbb.cfgrecipes-core/customizations/customizations.bb +0
-0@@ -13,10 +13,17 @@ inherit dpkg-rawDESCRIPTION = "demo image customizations"
recipes-core/customizations/customizations.bb +6
-0+def is_bbb(d): + bbb = d.getVar('MACHINE') or '' + if bbb == 'beagle-bone-black': + return "file://post-bbb" + return "" +SRC_URI = " \ file://postinst \ file://ethernet \recipes-core/customizations/customizations.bb inherit dpkg-raw · line 26
Quoted 3 lines
recipes-core/customizations/customizations.bb +2
-1- file://99-silent-printk.conf" + file://99-silent-printk.conf \ + ${@is_bbb(d)}"bitbake override magic can be used here:
SRC_URI_append_beagle-bone-black = ...
recipes-core/customizations/files/post-bbb line 4
Quoted 13 lines
DEBIAN_DEPENDS= "passwd"recipes-core/customizations/files/post-bbb new file +4
-0@@ -0,0 +1,5 @@ +#!/bin/sh + +# Disable HDMI in order to enable SPI1 on BeagleBone Black +echo "enable_uboot_overlays=1" >> /boot/uEnv.txtWhy do we need to *enable* overlays first...
recipes-core/customizations/files/post-bbb line 5
Quoted 1 line
recipes-core/customizations/files/post-bbb new file +1
-0+echo "disable_uboot_overlay_video=1" >> /boot/uEnv.txt...in order to disable a specific one?
Quoted 18 lines
\ No newline at end of file
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +11
-0@@ -0,0 +1,110 @@ +From 1badee8e16340d063f8bff04c39c9fd3d6749a8f Mon Sep 17 00:00:00 2001 +From: Deniz Ugur <[email protected]> +Date: Mon, 9 Nov 2020 20:19:49 +0300 +Subject: [PATCH] BeagleBone Black RTDM SPI enabled + +--- + arch/arm/boot/dts/am335x-bone-common.dtsi | 2 + + arch/arm/boot/dts/am335x-boneblack-spi.dtsi | 77 +++++++++++++++++++++ + 2 files changed, 79 insertions(+) + create mode 100644 arch/arm/boot/dts/am335x-boneblack-spi.dtsi +recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch line 21
Quoted 10 lines
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +10
-0+diff --git a/arch/arm/boot/dts/am335x-bone-common.dtsi b/arch/arm/boot/dts/am335x-bone-common.dtsi +index 73b514ddd..91ccc0f4b 100644 +--- a/arch/arm/boot/dts/am335x-bone-common.dtsi ++++ b/arch/arm/boot/dts/am335x-bone-common.dtsi +@@ -6,6 +6,8 @@ + * published by the Free Software Foundation. + */ + ++#include "am335x-boneblack-spi.dtsi" ++I think we should rather patch that into
am335x-boneblack.dts.Quoted 96 lines
recipes-kernel/linux/files/0001-BeagleBone-Black-RTDM-SPI-enabled.patch new file +89
-0+ / { + cpus { + cpu@0 { +diff --git a/arch/arm/boot/dts/am335x-boneblack-spi.dtsi b/arch/arm/boot/dts/am335x-boneblack-spi.dtsi +new file mode 100644 +index 000000000..47485af64 +--- /dev/null ++++ b/arch/arm/boot/dts/am335x-boneblack-spi.dtsi +@@ -0,0 +1,77 @@ ++&am33xx_pinmux { ++ spi0_pins: pinmux_spi0_pins { ++ pinctrl-single,pins = < ++ /* This output signal is also used as a re-timing input. */ ++ 0x150 0x30 /* P9_22 spi0_sclk, INPUT_PULLUP | MODE0 */ ++ 0x154 0x30 /* P9_21 spi0_d0, INPUT_PULLUP | MODE0 */ ++ 0x158 0x10 /* P9_18 spi0_d1, OUTPUT_PULLUP | MODE0 */ ++ 0x15c 0x10 /* P9_17 spi0_cs0, OUTPUT_PULLUP | MODE0 */ ++ >; ++ }; ++ ++ spi1_pins: pinmux_spi1_pins { ++ pinctrl-single,pins = < ++ /* This output signal is also used as a re-timing input. */ ++ 0x190 0x33 /* P9_31 spi1_sclk, INPUT_PULLUP | MODE3 */ ++ 0x194 0x33 /* P9_29 spi1_d0, INPUT_PULLUP | MODE3 */ ++ 0x198 0x13 /* P9_30 spi1_d1, OUTPUT_PULLUP | MODE3 */ ++ 0x19c 0x13 /* P9_28 spi1_cs0, OUTPUT_PULLUP | MODE3 */ ++ 0x164 0x12 /* P9_42 spi1_cs1 OUTPUT_PULLUP | MODE2 */ ++ >; ++ }; ++}; ++ ++&spi0 { ++ compatible = "ti,omap4-mcspi"; ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ reg = <0x48030000 0x400>; ++ interrupts = <0x41>; ++ ti,spi-num-cs = <0x2>; ++ ti,hwmods = "spi0"; ++ dmas = <0x27 0x10 0x0 0x27 0x11 0x0 0x27 0x12 0x0 0x27 0x13 0x0>; ++ dma-names = "tx0", "rx0", "tx1", "rx1"; ++ status = "okay"; ++ pinctrl-names = "default"; ++ pinctrl-0 = <&spi0_pins>; ++ ++ channel0@0 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x0>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++}; ++ ++&spi1 { ++ compatible = "ti,omap4-mcspi"; ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ reg = <0x481a0000 0x400>; ++ interrupts = <0x7d>; ++ ti,spi-num-cs = <0x2>; ++ ti,hwmods = "spi1"; ++ dmas = <0x27 0x2a 0x0 0x27 0x2b 0x0 0x27 0x2c 0x0 0x27 0x2d 0x0>; ++ dma-names = "tx0", "rx0", "tx1", "rx1"; ++ status = "okay"; ++ pinctrl-names = "default"; ++ pinctrl-0 = <&spi1_pins>; ++ ++ channel1@0 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x0>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++ ++ channel1@1 { ++ #address-cells = <0x1>; ++ #size-cells = <0x0>; ++ compatible = "rtdm-spidev"; ++ reg = <0x1>; ++ spi-max-frequency = <0x1312d00>; ++ }; ++ ++}; +\ No newline at end of file +-- +2.17.1recipes-kernel/linux/files/bbb.cfg new file +0
-0recipes-kernel/linux/files/bbb.cfg line 1
Quoted 1 line
recipes-kernel/linux/files/bbb.cfg new file +1
-0@@ -0,0 +1,28 @@ +# Disable conflicting driversHow can non-matching drivers be in conflict? Most of those below do not match on any of the DT entries on the BBB.
Quoted 37 lines
recipes-kernel/linux/files/bbb.cfg new file +27
-0+CONFIG_XENO_DRIVERS_SPI_BCM2835=n +CONFIG_XENO_DRIVERS_SPI_SUN6I=n +CONFIG_SPI_ATMEL=n +CONFIG_SPI_BCM2835=n +CONFIG_SPI_BCM2835AUX=n +CONFIG_SPI_BCM_QSPI=n +CONFIG_SPI_BITBANG=n +CONFIG_SPI_CADENCE=n +CONFIG_SPI_DAVINCI=n +CONFIG_SPI_GPIO=n +CONFIG_SPI_FSL_DSPI=n +CONFIG_SPI_OMAP24XX=n +CONFIG_SPI_ORION=n +CONFIG_SPI_PL022=n +CONFIG_SPI_ROCKCHIP=n +CONFIG_SPI_RSPI=n +CONFIG_SPI_S3C64XX=n +CONFIG_SPI_SH_MSIOF=n +CONFIG_SPI_SH_HSPI=n +CONFIG_SPI_SIRF=n +CONFIG_SPI_SUN4I=n +CONFIG_SPI_SUN6I=n +CONFIG_SPI_TEGRA114=n +CONFIG_SPI_TEGRA20_SFLASH=n +CONFIG_SPI_TEGRA20_SLINK=n +CONFIG_SPI_XILINX=n +CONFIG_SPI_SPIDEV=nrecipes-kernel/linux/linux-xenomai.inc +0
-0@@ -13,7 +13,14 @@ require recipes-kernel/linux/linux-custom.inc
KERNEL_DEFCONFIG?= "${DISTRO_ARCH}_defconfig"recipes-kernel/linux/linux-xenomai.inc require recipes-kernel/linux/linux-custom.inc · line 23
Quoted 9 lines
recipes-kernel/linux/linux-xenomai.inc +8
-1-SRC_URI += "file://${KERNEL_DEFCONFIG}" +def is_bbb(d): + bbb = d.getVar('MACHINE') or '' + if bbb == 'beagle-bone-black': + return "file://0001-BeagleBone-Black-RTDM-SPI-enabled.patch file://bbb.cfg" + return "" + +SRC_URI += "file://${KERNEL_DEFCONFIG} \ + ${@is_bbb(d)}"Same as above.
Quoted 3 lines
DEPENDS += "xenomai-kernel-source"
KBUILD_DEPENDS+= "xenomai-kernel-source"Looks good otherwise. The smaller your patch becomes, the better it is already ;).
Thanks,
JanSignature · 2 lines
Siemens AG, T RDA IOT Corporate Competence Center Embedded Linux
Quoted 6 lines · Deniz Uğur
Quoted 2 lines
This is not place to put some kind or "versioning" info. It's rather the place to put your commit message, explaining *why* we want this change.
I wish it was possible to delete the previous mail, otherwise I wouldn’t write that.
Quoted 9 lines
Quoted 5 lines
Why do we need to *enable* overlays first...
Quoted 1 line
+echo "disable_uboot_overlay_video=1" >>
/boot/uEnv.txt...in order to disable a specific one?
I’ve tried every combination but without these, BBB doesn’t seem to be booting.
I don't have the code around, but this is possibly *selecting* an overlay (rather than excluding one) that disables the otherwise enabled video function.
Quoted 6 lines
Quoted 2 lines
How can non-matching drivers be in conflict? Most of those below do not match on any of the DT entries on the BBB.
I took the liberty of trying every combination again but just disabling
CONFIG_SPI_SPIDEVwasn’t enough. In every other case, driver wasn’t loading and dumping stack trace to kernel logs.
I would have suspected that CONFIG_SPI_OMAP24XX=n and CONFIG_SPI_SPIDEV=n is enough. Would likely be worth to look at the back traces eventually.
Jan
Signature · 2 lines
Siemens AG, T RDA IOT Corporate Competence Center Embedded Linux