I've been reading an interesting article by Liguo Yu et. al., "Maintainability of the kernels of open-source operating systems: A comparison of Linux with FreeBSD, NetBSD, and OpenBSD" (DOI: 10.1016/j.jss.2005.08.014). Keep in mind, the article is from 2005 (published in 2006), so it would be interesting to know how things have changed since then. We are talking here about 2,4,20, 5.1, 1.6 and 3.3.
The article basically explores maintainability of said OSes judging mainly by usage of global variables.
Here's some interesting takeouts.
"Unsafe definition" is in their terms a usage of global variables between kernel modules and non-kernel modules.

Two graphs showing number of global variables and unsafe definitions in Linux and three BSDs. Linux has significantly more of both.
0

If you have a fediverse account, you can quote this note from your own instance. Search https://mastodon.bsd.cafe/users/chesheer/statuses/114450076337536309 on your instance and quote it. (Note that quoting is not supported in Mastodon.)