George Hilios
George Hilios

Reputation: 199

How to iterate effectively in Linux kernel development

I'm fairly new to Linux kernel development. It is certainly quite a bit different than the Windows kernel (I am a recovering Microsoft engineer). Can you provide advice on how to iterate effectively on updating modules that come with the Linux kernel?

Specifically, I am updating hid and bcm5974 to support the latest Macbook Pro (early 2015), and am using Ubuntu 15.04 (kernel 3.19). Would you recommend I test it out in a Virtual Machine? Are there ways to incrementally build instead of clean + build the whole tree? I'd love to be able to build just the affected modules but I can't find a good way to do that. The Makefiles are rather complicated.

Upvotes: 0

Views: 318

Answers (1)

George Hilios
George Hilios

Reputation: 199

Time to answer my own question. After doing a full build, incrementals are pretty straightforward given you're not editing headers that are consumed by other modules.

make modules SUBDIRS=drivers/input/mouse

Once I've installed the kernel from the full build, iterating on new module compilations is a breeze. sudo rmmod bcm5974. scp file from build desktop to Macbook Pro. sudo insmod bcm5974.

Upvotes: 1

Related Questions