Skip to content
Snippets Groups Projects
Select Git revision
  • pred_err_handling default protected
  • pred_err_handling_more_prints
  • pbm_no_preemption_fix_test_input
  • pbm_no_preemption_fix_test
  • libpbm_kernel_fix
  • libpbm_kernel
  • bugfix/setup
  • libpbm_kernel_fix_bak
  • pbm_no_preemption
  • pbm
  • testing
  • sose22results
  • sose22
  • master protected
  • err_detect
  • kelvin
16 results

pb_utils

  • Clone with SSH
  • Clone with HTTPS
  • user avatar
    Ollrogge authored
    160f4c52
    History
    Code owners
    Assign users and groups as approvers for specific file changes. Learn more.

    dependencies

    • build is tested on a ubuntu
    • for qemu minimum needed: sudo apt install qemu qemu-system-x86

    build

    create an image file with a debian rootfs (only needed first time)

    run ./create_image.sh, this downloads dbootstrap and installs a debian into a image file

    chroot into debian rootfs to build the kernel

    (build on your system is possible, but for example ubuntu 20.04 libs throw exceptions)

    run ./chroot_image.sh, this drops you in a shell on the created debian

    to build:

    apt update
    apt-get install -y fakeroot build-essential ncurses-dev xz-utils libssl-dev bc flex libelf-dev bison
    cd /mnt
    ./build

    run the build kernel with the created rootfs

    run ./run_qemu.sh

    debug using gdb

    run ./run_qemu.sh gdb

    run in a seperate shell:

    cd .. # to workspace root
    
    gdb vmlinux \
        -ex 'lx-symbols' \
        -ex 'target remote :1234' \
        -ex 'hb init_pb_rq'

    look for gdb add-auto-load-safe-path warning and follow instruction to enable loading of kernel gdb scripts

    use hardware breakpoints instead of software breaks