I'm planning to write a kernel module.

I will explain the scenario. I have a program in the userspace which takes a value (lets say a variable 'a') from

the user. There is a module in kernel which uses this value in an infinite loop (lets say prints the value of

'a'). When ever the user enters a new value, the kernel should be informed (Something like an event). I need to do

it with least overhead (so preferably all the fileoperations should be avoided).

Any ideas?