Digamos que eu tenha um módulo do kernel chamado "hello".
Por exemplo:
static struct file_operations hello_fops = {
.open = hello_open,
.read = hello_read,
.release = hello_release,
};
static ssize_t hello_read(struct file *f, char *buf, size_t len, loff_t *offset){
// some code here
}
Quando você lê o /dev/hello
arquivo de dispositivo de caracteres, a hello_read
função será chamada, mas de onde vêm os argumentos da função?