On Monday 30 March 2009, Johannes Berg wrote: > On Mon, 2009-03-30 at 19:54 +0200, Ivo van Doorn wrote: > > > > wimax_report_rfkill_hw() -- device driver report to stack > > > > > > > > device reports a change in the hw rfkill key; switch the radio to > > > > whichever state AND report a key event through the input layer > > > > > > But reporting the key through the input layer is wrong, afaict. > > > > Why because it combines it with switching the radio? > > In rt2x00 all key events are going through the input layer as well, > > because it has no influence on the radio state of the device. > > (In other words, you can still happily send and receive all > > the data you want regardless of the key state). > > Yes, but my understanding is (and I've just rewritten the code, heh) > that if the button switches the hardware kill directly then we don't > report an input event. > > Except in very limited circumstances (like the thinkpad-acpi platform > driver Henrique explained) I think doing _both_ > rfkill_force_state(hard-blocked) [in new API terms: > rfkill_set_hw_block(true)] _and_ input_report() is incorrect. I guess there is both history to both; Johannes, you are right, in this case the hw rfkill kills the radio in HW and *we* send the input event. Reason it sends the input event is because I used the rt2x00 code as reference... So, if you guys all agree that passing this to the input layer is not needed,feel free to yank it. -- Inaky -- To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html