It makes a certain amount of sense to use write. You hold the device
file descriptor anyway for the read (wait for interrupt) operation,
so using the same file descriptor is not a too bad idea:
while (!stop) {
/* wait for interrupt */
read(fd);
do_stuff();
/*reenable interrupt */
write(fd);
}
I thought about using a sysfs entry for a while, but looking at the
actual use case made the write() solution a more natural choice.
Thanks,
tglx
--