Thread (36 messages) 36 messages, 7 authors, 2011-11-17

Re: [v2 3/4] platform: (TS-5500) add LED support

From: Mark Brown <hidden>
Date: 2011-08-30 21:15:36

On Tue, Aug 30, 2011 at 05:14:24PM -0400, Vivien Didelot wrote:
"H. Peter Anvin" [off-list ref] wrote:
quoted
On 08/29/2011 03:16 PM, Mark Brown wrote:
quoted
quoted
Can you not do outb() from atomic context?  The reason lots of LED
drivers update the hardware in a workqueue is that they communicate
with the hardware over buses that can't be used in atomic context
like I2C or SPI but if that's not an issue then the workqueue is
not required and the code can be simplified.
quoted
outb() can definitely be executed from atomic context.
Good to know, thanks. I removed the work_struct and instead lock a mutex
before setting led->new_brightness and calling outb().
You can't take a mutex in atomic context...
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help