# 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>>.

### 11.3. User mode Buildroot executables

If you followed QEMU Buildroot setup, you can now run the executables created by Buildroot directly as:

    ./run \
      --userland "$(./getvar buildroot_target_dir)/bin/echo" \
      --cli-args='asdf' \
    ;

To easily explore the userland executable environment interactively, you can do:

    ./run \
      --arch aarch64 \
      --userland "$(./getvar --arch aarch64 buildroot_target_dir)/bin/sh" \
      --terminal \
    ;

or:

    ./run \
      --arch aarch64 \
      --userland "$(./getvar --arch aarch64 buildroot_target_dir)/bin/sh" \
      --cli-args='-c "uname -a && pwd"' \
    ;

Here is an interesting examples of this: Section 17.19.1, “Linux Test Project”