Colibri Evaluation Board V3.2
Colibri iMX6ULL 1GB IT
I tried the guide above, but custom defconfig does not apply.
I would like to add the mcp3422 driver to the kernel.
-
tree
└── linux
├── linux-toradex
│ ├── asurada-devicetree-file.dts
│ ├── asurada-devicetree-file.dtsi
│ └── defconfig
└── linux-toradex%.bbappend
-
linux-toradex%.bbappend
FILESEXTRAPATHS:prepend := "${THISDIR}/linux-toradex:"
# Prevent the use of in-tree defconfig
unset KBUILD_DEFCONFIG
CUSTOM_DEVICETREE = "asurada-devicetree-file.dts"
CUSTOM_DEVICETREE_INCLUDE = "asurada-devicetree-file.dtsi"
CUSTOM_DEFCONFIG = "defconfig"
SRC_URI += "\
file://${CUSTOM_DEVICETREE} \
file://${CUSTOM_DEVICETREE_INCLUDE} \
"
SRC_URI += "\
file://${CUSTOM_DEFCONFIG} \
"
do_configure:append() {
cp ${WORKDIR}/${CUSTOM_DEVICETREE} ${S}/arch/arm/boot/dts
cp ${WORKDIR}/${CUSTOM_DEVICETREE_INCLUDE} ${S}/arch/arm/boot/dts
}
- defconfig
CONFIG_MCP3422=y
Hello, did you see the comments made by ToradexAI?
by adding
do_configure_append() {
echo “CONFIG_MCP3422=y” >> ${B}/.config
oe_runmake oldconfig
}
in linux-toradex%.bbappend, you can force CONFIG_MCP3422 configuration
Is building image working for you currently?
Thank you
Regards,
Jung Hyun Jeong
I modified the linux-toradex%.bbappend as below and built it, but it doesn’t work.
In defconfig file of the imx_yocto\build\tmp\work-shared\colibri-imx6ull-emmc\kernel-source.kernel-meta\configs folder, CONFIG_MCP3422=y is not added.
FILESEXTRAPATHS:prepend := "${THISDIR}/linux-toradex:"
# Prevent the use of in-tree defconfig
unset KBUILD_DEFCONFIG
CUSTOM_DEVICETREE = "asurada-devicetree-file.dts"
CUSTOM_DEVICETREE_INCLUDE = "asurada-devicetree-file.dtsi"
SRC_URI += "\
file://${CUSTOM_DEVICETREE} \
file://${CUSTOM_DEVICETREE_INCLUDE} \
"
do_configure:append() {
# For arm32 bit devices
# cp ${WORKDIR}/${CUSTOM_DEVICETREE} ${S}/arch/arm/boot/dts
# For arm64 bit freescale/NXP devices
cp ${WORKDIR}/${CUSTOM_DEVICETREE} ${S}/arch/arm/boot/dts
cp ${WORKDIR}/${CUSTOM_DEVICETREE_INCLUDE} ${S}/arch/arm/boot/dts
echo "CONFIG_MCP3422=y" >> ${B}/.config
oe_runmake oldconfig
}
Easiest way to change kernel config is to create a config fragment. In your case create a file like “enable-MCP3422.cfg” containing just the one line you like to change and add “enable-MCP3422.cfg” to SRC_URI in your recipe.
This should change the kernel defconfig as required (at least it did it for me on Colibri iMX6ULL 512MB WB) .
For more complex config changes you can use “bitbake virtual/kernel -c menuconfig”, apply your changes there, save them and call “bitbake virtual/kernel -c diffconfig”. This will create the file “fragment.cfg” containing only the changes you made to the original kernel config. Copy that to your layer and rename it as you like.
Adding a custom tree might be a bit more complex for NAND-based Colibris, as it has to be added to the kernel device tree, to the u-boot environment and to “image.json” in your Tezi image.
1 Like
these commands will show actual running kernel config.
Please use these commands to check on the evaluation board that kernel config is running or not
cat /proc/config.gz | gunzip > running.config
or,
zcat /proc/config.gz > running.config