The default kernel cofiguration has support for all the hardware components available on the ConnectCore 93 system-on-module and on the ConnectCore 93 Development Kit. It also has support for common file systems, cryptography, network, and multimedia.

The configuration is tailor-made for the kernel to be as small as possible so it also boots faster.

Your custom carrier board may include new hardware and peripherals that you likely need to enable on the Linux kernel. This topic explains how to modify the kernel configuration to meet your needs.

Generate a custom kernel configuration file

  1. Go to your Digi Embedded Yocto project and source the environment:

    $ cd <your-project>
    $ source dey-setup-environment
  2. Run task menuconfig for the Linux kernel recipe:

    $ bitbake -c menuconfig linux-dey

    This opens the configuration menu for the Linux kernel.

  3. Make your configuration changes, save, and quit the configuration tool.

  4. Generate a defconfig file with your changes by running:

    $ bitbake -c savedefconfig linux-dey

    This generates a defconfig file in the working directory of your project’s kernel source tree.

  5. Check the Linux kernel recipe WORKDIR path with:

    $ bitbake -e linux-dey | grep ^WORKDIR=
    This command takes several seconds to complete. In this path you can find the generated defconfig file.

Use a custom kernel configuration file

To make Digi Embedded Yocto use your custom configuration file:

  1. Change to your layer directory, for instance:

    $ cd /<yourpath>/<meta-custom>/
  2. Create a path that replicates the path where the original recipe resides in its original layer. For instance, for the kernel recipe linux-dey in meta-digi layer the path is recipes-kernel/linux/:

    $ mkdir -p recipes-kernel/linux/
  3. Create a subfolder with the name of the recipe to hold the defconfig file:

    $ mkdir -p recipes-kernel/linux/linux-dey/
  4. Copy the defconfig file generated in Generate a custom kernel configuration file to this folder.

  5. Set the Yocto variable KERNEL_DEFCONFIG in your project’s conf/local.conf to an empty string:

    conf/local.conf
    # Define to empty string to use defconfig file in layer
    # instead of the one in the kernel source tree
    KERNEL_DEFCONFIG = ""

    The file must be called defconfig. If you want to rename it, then set KERNEL_DEFCONFIG with the full path to the file.

    conf/local.conf
    # Use custom defconfig file
    KERNEL_DEFCONFIG = "/<yourpath>/your-defconfig"
  6. Build the recipe so that it takes the new configuration:

    $ bitbake linux-dey
    This builds the kernel recipe only. Build an image recipe to have the new kernel included in your image.

Test the new kernel

See Deploy kernel and/or device tree for instructions on how to quickly transfer and test the modified kernel on your target platform.