 Hi, I'm Denshi, and in today's video I'm going to be talking about the Linux kernel. I'll be mainly talking about what kernels are, how they work, and what makes the Linux kernel any special. But anyway, let's begin this video with a rhetorical question. Have you ever used an Android smartphone or used an ADM machine, accessed the modern internet, or used a GNU Linux operating system like Ubuntu or Fedora? Now, you've probably answered yes to at least one, if not all of those questions. Well, that means that you've already interacted at some point with the Linux kernel. But what does that even mean? What is a kernel? Well, to understand what a kernel is, you must first understand that a computer needs both software and hardware to do anything. So to make it easier for a piece of software, like for example a web browser, to interact with the physical components of the computer, it makes sense to have a layer of software that acts as an abstraction between the hardware and the software that needs to use it. So, for example, if software on your computer needs to do something with the hardware, like open the CD tray, then instead of giving the motherboard the direct signal to open the CD tray, which might be a different signal depending on what motherboard you bought and what CD tray you use, the software can instead just tell the kernel to do that. In this sense, the kernel acts as an abstraction layer between the hardware and the software. Okay, so that's all well and good, but how does a kernel actually work? Well, most kernels work by responding to system calls. These are called by different parts of the operating system to get the actual physical hardware to do things. An example of this is your C Library. If you run software that was written in C on your computer, then it's up to your C Library to give the appropriate kernel system calls to make the computer actually run it. Now, that is a gross oversimplification of the process, and if you want to learn more, I have a page linked in the description that explains the process in far more detail. But moving on to the topic at hand, what is the Linux kernel? Linux is a kernel created in 1991 by Linus Torvalds. It's been in constant development since then, and is now at version 5.11.12, although that's probably changed since the making of this video. It's used in desktops, laptops, smartphones, servers, and many more devices. Okay, but what makes Linux any special? What makes it different from the other kernels out there? Well, first of all, it's open source, so anyone can see the code to Linux, download the code to Linux, and compile the code to Linux. Second of all, it's free software, so anyone can share the code to Linux and the finished kernel, and they can do anything they want with it. And third of all, it's very fast. Linux is consistently more efficient and faster than most other kernels in mainstream operating systems. The reason it is so fast is because it's free and open source. You see, Linux has become the de facto standard for any specialized OS that requires efficiency, and this is all because anyone can download the source code to Linux and compile it the way they want it. This means that any unnecessary features can be removed, which makes the system more efficient. So, for example, over here in the corner, there's a smart toaster, and that's quite obviously running Linux. The reason Linux is used rather than Windows or macOS is because the Linux kernel is open source and can be modified to be perfect for this toaster. And that's truly the greatest thing about Linux. It can run on everything from an integrated system to a supercomputer because it's so customizable. Alright, so now we're getting a little bit more practical, but how does Linux actually work? Well, just like any other kernel, Linux accepts system calls to perform functions. And like some other kernels, Linux utilizes kernel modules to handle which parts of the kernel to activate or deactivate. These can either be disabled, enabled, or rendered toggleable at compile time. An example of a Linux kernel module is PCSpeaker. This can be enabled or disabled with the modpro command. If disabled, your PCSpeaker will no longer make annoying bleeping noises. So I have a practical example for this kernel module. I have a software over here called FileZilla. And every time you try to press backspace in any FileZilla entry like the host, as you can hear, it makes a PCSpeaker noise. Now that's built into my actual computer. It's emulated, but if you were on older computers, that would actually be a physical speaker that would make that bleep. Not part of your regular speakers, but a dedicated speaker for that. And because Linux is so customizable and so controllable, we can just completely turn that off. So if we open up our terminal and run sudo modprobe-r PCSpeaker, and then we go over here and try to do it again, as you can see, no more bleep. So with that modprobe command, we've essentially disabled an entire part of the kernel, which is support for PCSpeaker. Now when we reboot our system, it will come back, and we can't re-enable the PCSpeaker support with the modprobe command. But that's just to prove how controllable Linux is. Now it's not all sunshine and rainbows. There are some negatives to Linux. For example, the fact that Linux is very monolithic, even more than Windows NT and macOS' Darwin kernel. What that means is there is a lot more built into Linux than there is on other kernels. This includes GPU drivers and drivers for peripherals like pen tablets. Essentially, what this means is if you were to plug in something like a pen tablet, or use a different graphics card on Linux, then you wouldn't really need to install any drivers. It would just work as long as it was supported by the kernel. However, it also means that you don't really get the option to change or remove any features from the kernel, even if you're not using them, unless you're willing to compile the kernel yourself. And this is why compiling the kernel is so popular. It's a very large project with support for lots of hardware. Lots of hardware that you're probably not using, and that's why it's convenient to go through there and delete things that you don't need. Another negative of Linux is that it's developed very rapidly, which means that if you choose to always use the latest kernel, you might encounter stability or security issues. Now this is essentially a non-issue, and most people don't use bleeding edge kernels. However, some features are deprecreated from Linux from time to time. Well, that's pretty much all I have to say. If you enjoyed this video on the Linux kernel, you might enjoy my upcoming kernel compilation guide. That'll all be coming soon. But for now, I hope you enjoyed this video, and goodbye.