Linux Kernel - 6.6


Linux 6.6 for MPU source code

The Linux kernel for Microchip ARM-Based MPUs (aka AT91) is distributed as a GIT tree hosted on GitHub as a fork of the official Linus Torvalds' git tree. The objective of the Microchip Linux team is to integrate all the AT91-related material in the official Linux Kernel.
Before completing this inclusion process, which can take time, this website provides the Linux4SAM Linux Kernel git tree for AT91 devices at:

https://github.com/linux4microchip/linux/tree/linux-6.6-mchp

Tags

linux4microchip-2024.10 tag

Enhancements are added on top of the official v6.6 Linux kernel tag where most of the Microchip SoC features are already supported. Note as well that we re-integrate each and every stable kernel release on top of this Long Term Support (LTS) kernel revision. This means that each v6.6.x version is merged in our branch.

Here is a little summary of the new Linux4Microchip release:

  • Integration of stable Long Term Support (LTS) kernel updates up to v6.6.51
  • Added suspend/resume support to the KSZ DSA driver.
  • Added preliminary support for unified WILC S02 V3 and WILC V16.3 WiFi / BLE driver.
  • Added support for SCMI clock, secure calls, secure suspend for SAMA7G5 to support OP-TEE.
  • Added the number of channels for the DMA controller in the device tree for SAMA7G5, documented dma-channels property.
  • Added PMC PLL Analog Control Register (ACR) in all PLL settings.
  • Enabled DRM_PANEL_LVDS in the at91_dt_defconfig.
  • Enabled WM8731 codec as a module for sama7, sama5 and at91 defconfigs
  • Enhancements for Microchip LVDS:
  • Fixed realbits value for SAMA7G5 in the at91-sama5d2_adc driver.
  • Configured MMC_SPI as a loadable module for sama5_defconfig
  • Added RMII Ethernet support for SAM9x75
  • Add no-1-8-v property to sdmmc0 dts node to fix USB VBUS voltage on SAMA5D29 Curiosity and SAMA5D27 WLSoM1-EK.
  • Configure Backup Unit Power Switch to automatic mode for SAMA7G5 (used when entering Backup Self-Refresh).
  • Skip ALSA restoration if sub-stream runtime is uninitialized for PDMC on SAMA7G5.
  • Add all Flexcom nodes in SAMA7G5 dtsi.
  • QSPI: switch to generic flags in the driver caps.
  • Add initial support for the upcoming SAMA7G5 Curiosity board.

linux4microchip+sama7d65-2024.10 tag

Enhancements are added on top of the official v6.6 Linux kernel tag where most of the Microchip SoC features are already supported. Note as well that we re-integrate each and every stable kernel release on top of this Long Term Support (LTS) kernel revision. This means that each v6.6.x version is merged in our branch.

Here is a little summary of the main additional enhancements:

  • Integration of stable Long Term Support (LTS) kernel updates up to v6.6.23
  • Add support for SAMA7D65 Curiosity board
  • Basic Support
    • Timers:
      • TCB and PIT64
      • PWM and TC PWM supported
    • DMA: for peripherals and memory to memory usage
    • PMC:
      • Marked MCK3 as critical for proper low power mode operation.
      • Adjusted max frequencies and allowed MCK3 and MCK5 to be referenced in DT.
    • PIO:
      • Added support for GPIO wakeup in low power modes.
    • Serial:
      • Support for USART and console.
      • Added debug UART for DEBUG_LL.
    • I2C / SPI / USART (Flexcom):
      • Added support for I2C, SPI, and USART on flexcoms.
      • Add recovery GPIOs for I2C for SAMA7D65 Curiosity board.
    • Button and LED:
      • Added user button support on GPIOs.
      • Added multi-color LED.
  • ADC: Cover All Linux-Related Features + Triggers
    • Adapted the ADC driver for SAMA7D65, including support for temperature calibration data and triggers.
  • Thermal Supervision Functions
    • Added thermal zones and temperature sensor ADC features.
    • Thermal Support with OTP Data Retrieval: thermal zones, temperature sensor, and calibration support.
  • Power Management
    • ULP0 / ULP1 / Backup with Self-Refresh (BSR) Modes.
    • DVFS Support with Maximum CPU Clock (1 GHz) and added configuration for CPU frequency operating points.
  • Crypto Engines: TDES, SHA, AES
  • SD-Card Support:
    • Added support for SD-Card and MMC / eMMC in basic modes.
    • SDIO Mode Tested with WILC1000 / WILC3000.
  • Ethernet Support:
    • Added support for Ethernet GMAC0 and GMAC1.
  • Display Sub-System
    • Added support for XLCDC on SAMA7D65.
    • Added support for LCD backlight.
    • Added support for SAMA7D65 XLCDC's PWM used for backlight.
    • MIPI-DSI Controller:
      • Added support for the Microchip DSI controller on SAMA7D65.
      • Microchip MIPI Screen Portrait Mode: support for Microchip AC40T08A MIPI Display.
    • LVDS Controller:
      • Enabled LVDS serializer support for display pipeline.
      • Microchip LVDS Screen Landscape Mode: support for AC69T88A LVDS Display WVGA Rev 1.
    • MaXTouch Touchscreen Controller: Enabled touchscreen using the atmel_mxt_ts driver on I2C.
    • Screen Identification from U-Boot: support for identifying the screen to be used and loading the right Device Tree Overlay.
  • CAN / CAN-FD
    • Added support for CAN interfaces on SAMA7D65 Curiosity board.
  • USB Host on All Ports (USBA (J3), USBB (J23) and USBC (J24))
    • Added OHCI, and EHCI support to SAMA7D65 curiosity board.
    • Added support for USB serial devices.
  • USB Gadget (No USB-C Features)
    • Added support for USB gadget on port USBA (J3).

linux4microchip-2024.04 tag

Enhancements are added on top of the official v6.6 Linux kernel tag where most of the Microchip SoC features are already supported. Note as well that we re-integrate each and every stable kernel release on top of this Long Term Support (LTS) kernel revision. This means that each v6.6.x version is merged in our branch.

Here is a little summary of the main additional enhancements:

  • Integration of stable kernel updates up to v6.6.23
  • Add support for SAM9x75 Curiosity board
  • Add support for LAN8840 EDS2 Daughter Card
  • Fix suspend / resume for LAN8840 Gigabit Ethernet PHY
  • Add support for AC69T88A LVDS Display WVGA Rev 1
  • Fix DDR self-refresh impedance calibration for SAMA7G5
  • Add ADC hardware trigger support for SAM9x75
  • Fix ASOC: CLASSD platform driver initialization
  • Add support for MIPI DSI controller for SAM9x75
  • Add support for Microchip AC40T08A MIPI Display
  • Update WILC firmware and driver for Linux 6.6
  • Fix VDEC driver for Linux 6.6

Required packages

You must install essential host packages on your build host. These requirements are listed in the Linux kernel documentation with the chapter Install build requirements. You must follow this process which includes, but not limited to, the following packages:

  • build-essential
  • flex
  • bison
  • git
  • perl-base
  • libssl-dev
  • libncurses5-dev
  • libncursesw5-dev
  • ncurses-dev

Getting Kernel sources

To get the source code, you have to clone the repository:

$ git clone https://github.com/linux4microchip/linux.git
Cloning into 'linux'...
remote: Enumerating objects: 8587836, done.
remote: Total 8587836 (delta 0), reused 0 (delta 0), pack-reused 8587836
Receiving objects: 100% (8587836/8587836), 3.49 GiB | 13.44 MiB/s, done.
Resolving deltas: 100% (7117887/7117887), done.
Updating files: 100% (70687/70687), done.
$ cd linux

The source code has been taken from the master branch which is pointing on the latest branch we use.

Pointing hand Note that you can also add this Linux4SAM repository as a remote GIT repository to your usual Linux git tree. It will save you a lot of bandwidth and download time:

$ git remote add linux4microchip https://github.com/linux4microchip/linux.git
$ git remote update linux4microchip
Fetching linux4microchip
From https://github.com/linux4microchip/linux
 * [new branch]                linux-6.1-mchp -> linux4microchip/linux-6.1-mchp
 * [new branch]                linux-6.6-mchp -> linux4microchip/linux-6.6-mchp
 * [new branch]                master     -> linux4microchip/master

If you want to use another branch, you can list them and use one of them by doing this:

$ git branch -r
  linux4microchip/linux-5.10-mchp
  linux4microchip/linux-5.15-mchp
  linux4microchip/linux-5.15-mchp+fpga
  linux4microchip/linux-6.1-mchp
  linux4microchip/linux-6.1-mchp+fpga
  linux4microchip/linux-6.6-mchp
  linux4microchip/linux-6.6-mchp+fpga
  linux4microchip/master
$ git checkout -b linux-6.6-mchp --track remotes/linux4microchip/linux-6.6-mchp
Branch linux-6.6-mchp set up to track remote branch linux-6.6-mchp from linux4microchip.
Switched to a new branch 'linux-6.6-mchp'

Setup ARM Cross Compiler

  • First step is to dowload the ARM GNU Toolchain:
    wget -c https://developer.arm.com/-/media/Files/downloads/gnu/13.2.rel1/binrel/arm-gnu-toolchain-13.2.rel1-x86_64-arm-none-linux-gnueabihf.tar.xz
       

  • Next step is to add the ARM GNU Toolchain into your system:
    tar -xf arm-gnu-toolchain-13.2.rel1-x86_64-arm-none-linux-gnueabihf.tar.xz
    export CROSS_COMPILE=`pwd`/arm-gnu-toolchain-13.2.rel1-x86_64-arm-none-linux-gnueabihf/bin/arm-none-linux-gnueabihf-
        
    or
    tar -xf arm-gnu-toolchain-13.2.rel1-x86_64-arm-none-linux-gnueabihf.tar.xz
    export CROSS_COMPILE=arm-none-linux-gnueabihf-
    export PATH=$PATH:/YOUR/PATH/TO/arm-gnu-toolchain-13.2.Rel1-x86_64-arm-none-linux-gnueabihf/bin/
       

  • !Note: If you already have an old ARM GNU Toolchain need to clean up the PATH with:
    export PATH=${PATH/':/YOUR/PATH/TO/arm-gnu-toolchain-VERSION-x86_64-arm-none-linux-gnueabihf/bin/'/}
        

Configure and Build the Linux kernel

Now you have to configure the Linux kernel according to your hardware. We have two default configuration at91 SoC in arch/arm/configs
arch/arm/configs/at91_dt_defconfig
arch/arm/configs/sama5_defconfig
arch/arm/configs/sama7_defconfig

  • at91_dt_defconfig: for SAM9 (ARM926) series chips
  • sama5_defconfig: for SAMA5 series chips
  • sama7_defconfig: for SAMA7 series chips

Now we Configure and Build kernel for board:

$ make ARCH=arm sama5_defconfig
  HOSTCC  scripts/basic/fixdep
  HOSTCC  scripts/kconfig/conf.o
  SHIPPED scripts/kconfig/zconf.tab.c
  SHIPPED scripts/kconfig/zconf.lex.c
  SHIPPED scripts/kconfig/zconf.hash.c
  HOSTCC  scripts/kconfig/zconf.tab.o
  HOSTLD  scripts/kconfig/conf
#
# configuration written to .config
#

At this step, you can modify default configuration using the menuconfig

$ make ARCH=arm menuconfig
Now, in the menuconfig dialog, you can easily add or remove some features. Once done, Move to <Exit> with arrows and press this button hitting the Enter key to exit from this screen.

Build the Linux kernel image, before you build you need set up the cross compile toolchain, check this section.

$ make ARCH=arm

[..]

  Kernel: arch/arm/boot/Image is ready
  Kernel: arch/arm/boot/zImage is ready

Now you have an usable compressed kernel image zImage.

If you need an uImage you can run this additional step:

make ARCH=arm uImage LOADADDR=0x20008000

[..]

  Kernel: arch/arm/boot/zImage is ready
  UIMAGE  arch/arm/boot/uImage
  Image Name:   Linux-6.6.23-linux4microchip-202
  Created:      Thu May 16 14:36:06 2024
  Image Type:   ARM Linux Kernel Image (uncompressed)
  Data Size:    5221704 Bytes = 5099.32 KiB = 4.98 MiB
  Load Address: 20008000
  Entry Point:  20008000
  Kernel: arch/arm/boot/uImage is ready


make ARCH=arm dtbs

[..]

  DTC     arch/arm/boot/dts/microchip/at91-sam9x60_curiosity.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sam9x60ek.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sam9x75_curiosity.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sam9x75eb.dtb  
  DTC     arch/arm/boot/dts/microchip/at91-sama5d27_som1_ek.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama5d27_wlsom1_ek.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama5d29_curiosity.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama5d2_icp.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama5d2_ptc_ek.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama5d2_xplained.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama7d65_curiosity.dtb
  DTC     arch/arm/boot/dts/microchip/at91-sama7g5ek.dtb

[..]

If the building process is successful, the final images can be found under arch/arm/boot/ directory.

Recent FAQ

linux-6.6-mchp

Media Controller: What is Media controller and how to use it with SAM products.. (Sam9x75Curiosity, Sama7g5-ek, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2Xplained)
Using Atmel DRMDriver: Using Atmel KMS/DRM LCD driver. (Sama7d65Curiosity, Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained, Sama5d4Xplained, Sama5d4ek, Sama5d3Xplained, Sama5d3xek)
Using Systemd: Basic systemd user guide. (Sama7d65Curiosity, Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sama7g5-ek, Sama5d2-icp, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK)
Thermal Faq: Thermal management support on SAMA7G5. (Sama7d65Curiosity, Sama7g5-ek)
Using SAMA 5 D 2 ADCDevice: Using the SAMA5D2-compatible ADC device. (Sama7d65Curiosity, Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sama7g5-ek, Sama5d2-icp, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained)
Using Max Touch: Introduction for how to use maxTouch. (Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity)
Crypto Config: How to configure Crypto driver. (Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sama5d2-icp, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained, Sama5d4Xplained, Sama5d4ek, Sama5d3Xplained, Sama5d3xek)
USBGadget Config: Configure AT91 USB Gadget on Linux and Endpoint order management (composite USB). (Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sama5d2-icp, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained, Sama5d4Xplained, Sama5d4ek, Sama5d3Xplained, Sama5d3xek, AT91sam9x5-ek, other AT91SAM9 boards)
Pwm Faq: PWM Driver. (Sama5d29Curiosity, Sam9x75Curiosity, Sam9x60Curiosity, Sam9x60EK, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained, Sama5d4Xplained, Sama5d3Xplained, Sama5d3xek)
Using I 2 SC: How to use I2SC. (Sam9x75Curiosity, Sama7g5-ek, Sam9x60EK, Sama5d2Xplained)
ISCWhite Balance Features: White balance features of the Image sensor controller.. (Sam9x75Curiosity, Sama7g5-ek, Sama5d27WLSom1EK, Sama5d27Som1EK, Sama5d2Xplained)
Sama 7 g 5 Xisc: Detailed explanation of the sama7g5 image acquisition pipeline. (Sam9x75Curiosity, Sama7g5-ek)
External Component On EBI: Connecting an external component on the External Bus Interface. (Sam9x75Curiosity, Sam9x60Curiosity, Sam9x60EK, Sama5d27Som1EK, Sama5d2PtcEK, Sama5d2Xplained, Sama5d4Xplained, Sama5d4ek, Sama5d3Xplained, Sama5d3xek, AT91sam9x5-ek)
Sama 7 g 5 Ov 7740: Interfacing sama7g5 with parallel omnivision ov7740 sensor.. (Sama7g5-ek)
Using ASRC: How to use ASRC. (Sama7g5-ek)
r11 - 05 Dec 2024 - 17:25:27 - CristianBirsan
 
Linux & Open Source for AT91 Microchip Microprocessors

Copyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.

Linux® is the registered trademark of Linus Torvalds in the U.S. and other countries.

Microchip and others, are registered trademarks or trademarks of Microchip Technology Inc. and its subsidiaries. This site is powered by the TWiki collaboration platform

Arm® and others are registered trademarks or trademarks of Arm Limited (or its affiliates). Other terms and product names may be trademarks of others.

Ideas, requests, contributions ? Connect to LinksToCommunities page.

Syndicate this siteRSS ATOM