Does It mean that I can actually write drivers for linux in c++ as long as I don’t care about integrating my driver in official kernel sources ?
Well, technically there is nothing that stands in your way, although you have to take care of quite a few issues. To begin with, you have to implement your own versions of new() and delete() operators . Furthermore, making C++ work with Linux kernel headers does not really seem to be the easiest job in existence, so that you will probably have to provide your own wrappers for the kernel functions that you call. You must always keep in mind that there is no C++ runtime in the Linux kernel so that you have to avoid certain C++ language features( like , for example, exceptions),et,etc, etc…
When it comes to deciding upon the practical usefulness of this approach…well, this is already a different story that happens to be well beyond the scope of this discussion
Anton Bassov