On Thu, Oct 3, 2013 at 2:54 PM, Dmitry Torokhov <dmitry.torokhov@xxxxxxxxx> wrote: > On Thursday, October 03, 2013 01:53:10 PM Ping Cheng wrote: >> This series of models added a hardware switch to turn touch >> data on/off. To report the state of the switch, SW_TOUCH_ENABLED >> is added in include/uapi/linux/input.h. > > > Hmm, should we just postpone creating of input device until touch is enabled > instead? > > -- > Dmitry > -- The idea of SW_TOUCH_ENABLED is to allow userspace to be a bit more helpful and display a "disabled" message rather than disappearing the device entirely when the switch is 'off'. In theory this could also be achieved through the libwacom support library (by scanning the list of event devices to see if any of the expected interfaces are missing), but the approach is somewhat fragile and I'm not convinced that linking the switch to device creation/removal is correct. Jason --- Now instead of four in the eights place / you’ve got three, ‘Cause you added one / (That is to say, eight) to the two, / But you can’t take seven from three, / So you look at the sixty-fours.... -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html