I'm learning to add system calls to the kernel. Ubuntu 20.04 LTS is my system.
So far, I understood how to print "Hello", but I'd also like to print my IP address. How is this done? Do I have to do this in C? If so, how? Do I have to use a Bash command like hostname -I? If so, how?
So far, this is the C file I'm working with.
#include<linux/kernel.h>asmlinkage long sys_identity(void){printk("Hello. My name is Mind Y. Business.\m");return 0;}