Blink LED from user or kernel space?
Hello:
I have an LED hanging off a GPIO device (via I2C) that is capable of turning ON/OFF an LED. I use ioctl() commands from user space to kernel space to control the LED state, using the kernel's SMBUS APIs to communicate over I2C to program the GPIO device.
Now I want to blink the LED. Is it better/less intrusive to control the LED blink state (ON/OFF) from user space or kernel space? If I have a high blink rate, do I want to be repeatedly be sending LED change state commands from user kernel via ioctl, or can I somehow use kernel work queues to invoke the desired blink rate behavior (send a single ioctl from user space to kernel that contains blink rate information, then let the kernel handle the rest... with the ioctl() returning and not blocking)?
Note I'm somewhat of a embedded Linux newbie, be gentle... ;-)
Thanks folks!
|