# Linux Kernel Module Cheat
The perfect emulation setup to study and develop the <<linux-kernel>> v5.9.2, kernel modules, <<qemu-buildroot-setup,QEMU>>, <<gem5-buildroot-setup,gem5>> and x86_64, ARMv7 and ARMv8 <<userland-assembly,userland>> and <<baremetal-setup,baremetal>> assembly, <<c,ANSI C>>, <<cpp,C++>> and <<posix,POSIX>>. <<gdb>> and <<kgdb>> just work. Powered by <<about-the-qemu-buildroot-setup,Buildroot>> and <<about-the-baremetal-setup,crosstool-NG>>. Highly automated. Thoroughly documented. Automated <<test-this-repo,tests>>.

#### 14.3.1. Graphic mode gem5 aarch64

For `aarch64` we also need to configure the kernel with linux_config/display:

    git -C "$(./getvar linux_source_dir)" fetch https://gem5.googlesource.com/arm/linux gem5/v4.15:gem5/v4.15
    git -C "$(./getvar linux_source_dir)" checkout gem5/v4.15
    ./build-linux \
      --arch aarch64 \
      --config-fragment linux_config/display \
      --custom-config-file-gem5 \
      --linux-build-id gem5-v4.15 \
    ;
    git -C "$(./getvar linux_source_dir)" checkout -
    ./run --arch aarch64 --emulator gem5 --linux-build-id gem5-v4.15

This is because the gem5 `aarch64` defconfig does not enable HDLCD like the 32 bit one `arm` one for some reason.