Location of files for a new driver

Jacko Dirks jdirks.linuxdev at gmail.com
Tue May 5 10:38:06 EDT 2020

On Tue, May 05, 2020 at 04:20:32PM +0200, Greg KH wrote:
> drivers/staging/ is only for code that needs lots and lots of work to
> get into the "real" part of the kernel.  It also requires a TODO file
> that lists what is left to do to get it out of that location.

Oh, I did not know that staging was optional. Well, I will attempt to
skip staging in that case

> It all depends on what you are writing.  What exactly does this code do?
> That will determine where it goes in the kernel tree.

The code is a driver for the Broadcom BSC, which lives on the Raspberry
Pi 3 & 4 (at least, maybe also on 1 & 2). This device can act as an I2C
slave. To "announce" the device (tell the device tree which pins need to
be configured how, etcetera) I need to change existing dts/dtsi files,
to actually be able to enable the device I need to create a new overlay. 
Finally, the actual driver needs to be created in drivers/i2c/busses. And 
then there is also some makefile, documentation and kconfig.

Does that sound right?

> thanks,

No, thank you!

Jacko Dirks

More information about the Kernelnewbies mailing list