What is the most efficient and elegant way develop/debug linux kernel

后端 未结 3 1397
栀梦
栀梦 2020-12-18 18:02

Recently I start to develop the linux device driver,

I face a problem, when I want to debug with kernel code, and add some printk debug message in the k

3条回答
  •  北海茫月
    2020-12-18 18:35

    1. use ccache; this speeds up subsequent builds significantly

    2. boot over network; bootloader of embedded devices have usually some tftp download mechanism; for PC you can use PXE boot

    3. place the modules on an NFS root filesystem which gets filled by make modules-install INSTALL_MOD_PATH=$nfs-root

    4. when you work on a single driver only, you can build only this by make -C $kernelsources M=$driverpath

提交回复
热议问题